Polluxchain
  1. polluxweb.transactionBuilder
Polluxchain
  • Background
  • API key
    • Rate Limits
    • Security Settings
  • Full Node HTTP API
    • Address Utilities
      • ValidateAddress
    • Transactions
      • BroadcastTransaction
      • BroadcastHex
      • CreateTransaction
    • Accounts
      • CreateAccount
      • GetAccount
      • UpdateAccount
      • AccountPermissionUpdate
      • GetAccountBalance
    • Account Resources
      • GetAccountResource
      • GetAccountNet
      • FreezeBalance
      • UnfreezeBalanceV2
      • CancelAllUnfreezeV2
      • DelegateResource
      • UnDelegateResource
      • WithdrawExpireUnfreeze
      • GetAvailableUnfreezeCount
      • GetCanWithdrawUnfreezeAmount
      • GetCanDelegatedMaxSize
      • GetDelegatedResourceV2
      • GetDelegatedResourceAccountIndexV2
    • Query The Network
      • GetBlock
      • GetBlockByNum
      • GetBlockById
      • GetBlockByLatestNum
      • GetBlockByLimitNext
      • GetNowBlock
      • GetTransactionById
      • GetTransactionInfoById
      • GetTransactionInfoByBlockNum
      • ListNodes
      • GetNodeInfo
      • GetChainParameters
      • GetBlockBalance
      • GetEnergyPrices
      • GetBandwidthPrices
      • GetBurnTRX
      • GetApprovedList
    • Smart Contract
      • GetContract
      • GetContractInfo
      • TriggerSmartContract
      • TriggerConstantContract
      • DeployContract
      • UpdateSetting
      • UpdateEnergyLimit
      • ClearAbi
      • EstimateEnergy
    • Voting & SRs
      • ListWitnesses
      • CreateWitness
      • UpdateWitness
      • GetBrokerage
      • UpdateBrokerage
      • VoteWitnessAccount
      • GetReward
      • WithdrawBalance
      • GetNextMaintenanceTime
    • Proposals
      • ListProposals
      • GetProposalById
      • ProposalCreate
      • ProposalApprove
      • ProposalDelete
    • Pending pool
      • GetTransactionListFromPending
      • GetTransactionFromPending
      • GetPendingSize
  • Full Node Solidity HTTP API
    • Transactions
      • GetTransactionById
      • GetTransactionInfoById
      • GetTransactionInfoByBlockNum
      • GetTransactionCountByBlockNum
    • Blocks
      • GetBlock
      • GetNowBlock
      • GetBlockByNum
      • GetBlockById
      • GetBlockByLatestNum
      • GetBlockByLimitNext
    • Account Resources
      • GetAccount
      • GetDelegatedResource
      • GetDelegatedResourceAccountIndex
      • GetCanDelegatedMaxSize
      • GetCanWithdrawUnfreezeAmount
      • GetDelegatedResourceAccountIndexV2
      • GetAvailableUnfreezeCount
    • Node & Chain
      • GetNodeInfo
      • GetBurnPOX
    • Smart Contracts
      • TriggerConstantContract
      • EstimateEnergy
    • Voting & SRs
      • ListWitnesses
      • GetReward
      • GetBrokerage
  • Full Node JSON-RPC API
    • Overview
    • buildTransaction
    • eth
      • eth_accounts
      • eth_blockNumber
      • eth_call
      • eth_chainId
      • eth_coinbase
      • eth_estimateGas
      • eth_gasPrice
      • eth_getBalance
      • eth_getBlockByHash
      • eth_getBlockByNumber
      • eth_getBlockTransactionCountByHash
      • eth_getBlockTransactionCountByNumber
      • eth_getCode
      • eth_getStorageAt
      • eth_getTransactionByBlockHashAndIndex
      • eth_getTransactionByBlockNumberAndIndex
      • eth_getTransactionByHash
      • eth_getTransactionReceipt
      • eth_getWork
      • eth_protocolVersion
      • eth_syncing
      • eth_newFilter
      • eth_newBlockFilter
      • eth_getFilterChanges
      • eth_getFilterLogs
      • eth_uninstallFilter
      • eth_getLogs
    • net
      • net_listening
      • net_peerCount
      • net_version
    • web3
      • web3_clientVersion
      • web3_sha3
  • PolluxWeb
    • address
    • createAccount
    • createRandom
    • fromAscii
    • fromDecimal
    • fromMnemonic
    • fromUtf8
    • getEventByTransactionID
    • getEventResult
    • isAddress
    • isConnected
    • setHeader
    • setDefaultBlock
    • setPrivateKey
    • setAddress
    • sha3
    • toAscii
    • toBigNumber
    • toDecimal
    • toHex
    • toRAM
    • toUtf8
    • BigNumber
    • polluxweb.trx
      • getAccount
      • getAccountResources
      • getApprovedList
      • getAvailableUnfreezeCount
      • getBalance
      • getBandwidth
      • getBlock
      • getBlockByHash
      • getBlockByNumber
      • getBlockRange
      • getBlockTransactionCount
      • getBrokerage
      • getCanDelegatedMaxSize
      • getCanWithdrawUnfreezeAmount
      • getChainParameters
      • getConfirmedTransaction
      • getContract
      • getCurrentBlock
      • getDelegatedResourceV2
      • getDelegatedResourceAccountIndexV2
      • getExchangeByID
      • getNodeInfo
      • getReward
      • getTokenByID
      • getTokenFromID
      • getTokenListByName
      • getTokensIssuedByAddress
      • getTransaction
      • getTransactionFromBlock
      • getTransactionInfo
      • getUnconfirmedBalance
      • getUnconfirmedBrokerage
      • getUnconfirmedReward
      • listExchanges
      • listExchangesPaginated
      • listNodes
      • listProposals
      • listSuperRepresentatives
      • listTokens
      • sendRawTransaction
      • sendHexTransaction
      • sendToken
      • sendTransaction
      • sign
      • signMessageV1
      • signMessageV2
      • timeUntilNextVoteCycle
      • multiSign
      • verifyMessage
      • verifyMessageV2
      • _signTypedData
      • verifyTypedData
    • polluxweb.transactionBuilder
      • addUpdateData
      • applyForSR
      • cancelUnfreezeBalanceV2
      • createAccount
      • createAsset
      • createProposal
      • createSmartContract
      • createToken
      • delegateResource
      • deleteProposal
      • estimateEnergy
      • extendExpiration
      • freezeBalance
      • freezeBalanceV2
      • injectExchangeTokens
      • purchaseAsset
      • purchaseToken
      • sendAsset
      • sendToken
      • sendTrx
      • tradeExchangeTokens
      • triggerConfirmedConstantContract
      • triggerConstantContract
      • triggerSmartContract
      • undelegateResource
      • unfreezeBalance
      • unfreezeBalanceV2
      • updateSetting
      • updateAccountPermissions
      • updateAsset
      • updateBrokerage
      • updateEnergyLimit
      • updateToken
      • vote
      • voteProposal
      • withdrawBlockRewards
      • withdrawExchangeTokens
      • withdrawExpireUnfreeze
    • poxweb.contract
      • polluxweb.contract.new
      • polluxweb.contract()
      • method.call()
      • method.send()
    • polluxweb.utils
      • transaction.txJsonToPb
      • transaction.txPbToTxID
      • message.hashMessage
  • Pollux CLI
    • Pollux CLI
  1. polluxweb.transactionBuilder

updateAccountPermissions

Create an unsigned transaction to update the consume_user_resource_percent parameter of a smart contract

Usage
JavaScript
Input Parameters
ParameterDescriptionType
owner_addressThe address of the owner who will update the permission. Defaults to the caller's default address in polluxWeb.String
ownerPermissionOwner permission object (type must be 0), including threshold and keys.Object
witnessPermissionWitness permission object (type must be 1). Only applicable to super representatives. Pass null for normal users.Object or Null
activePermissionsActive permission object array (type must be 2), including threshold, operations, and keys.Array
Return
Object

Example
Example Output Data
{
  "visible": false,
  "txID": "7f06b2e887dd9703ad481c6a7cafc1cd8857b354d0c45ebdf5eb82bfd0cf6d68",
  "raw_data": {
    "contract": [
      {
        "parameter": {
          "value": {
            "owner": {
              "keys": [
                {
                  "address": "3765776280f01cdc51d0bc2b5a952a552d1c62bc2f",
                  "weight": 1
                },
                {
                  "address": "375f4204dec09b1899444d851dd54fbfc21397e20ab",
                  "weight": 1
                }
              ],
              "threshold": 2,
              "permission_name": "owner"
            },
            "owner_address": "3765776280f01cdc51d0bc2b5a952a552d1c62bc2f",
            "actives": [
              {
                "operations": "7fff1fc0037e0000000000000000000000000000000000000000000000000000",
                "keys": [
                  {
                    "address": "3765776280f01cdc51d0bc2b5a952a552d1c62bc2f",
                    "weight": 1
                  },
                  {
                    "address": "375f4204dec09b1899444d851dd54fbfc21397e20ab",
                    "weight": 1
                  }
                ],
                "threshold": 3,
                "type": "Active",
                "permission_name": "active0"
              }
            ]
          },
          "type_url": "type.googleapis.com/protocol.AccountPermissionUpdateContract"
        },
        "type": "AccountPermissionUpdateContract"
      }
    ],
    "ref_block_bytes": "000b",
    "ref_block_hash": "07653cf4b79aa839",
    "expiration": 1565312682000,
    "timestamp": 1565312624396
  },
  "raw_data_hex": "..."
}
Previous
updateSetting
Next
updateAsset
Built with