Home

Generate an Unsigned Transaction and Signing Payloads

POST
https://ada.nownodes.io/construction/payloads

Authorizations

ApiKeyAuthApiKeyAuth

api-key string

NOWNodes API key passed in the api-key header.

Payloads is called with an array of operations and the response from /construction/metadata. It returns an unsigned transaction blob and a collection of payloads that must be signed by particular AccountIdentifiers using a certain SignatureType. The array of operations provided in transaction construction often times can not specify all "effects" of a transaction (consider invoked transactions in Ethereum). However, they can deterministically specify the "intent" of the transaction, which is sufficient for construction. For this reason, parsing the corresponding transaction in the Data API (when it lands on chain) will contain a superset of whatever operations were provided during construction.

Body

application/json

Request value.

network_identifierNetworkIdentifierrequired

Rosetta network identifier object.

Show child attributes
blockchainstringrequired

Blockchain value.

networkstringrequired

If a blockchain has a specific chain-id or network identifier, it should go in this field. It is up to the client to determine which network-specific identifier is mainnet, preprod, or preview.

sub_network_identifierSubNetworkIdentifier

Sub Network Identifier value.

Show child attributes
networkstringrequired

Network value.

metadataobject

Additional metadata object.

operationsArray<Operation>required

Operations value.

Show child attributes
operation_identifierOperationIdentifierrequired

Operation Identifier value.

Show child attributes
indexinteger<int64>>= 0required

The operation index is used to ensure each operation has a unique identifier within a transaction. This index is only relative to the transaction and NOT GLOBAL. The operations in each transaction should start from index 0. To clarify, there may not be any notion of an operation index in the blockchain being described.

network_indexinteger<int64>>= 0

Some blockchains specify an operation index that is essential for client use. For example, Bitcoin uses a network_index to identify which UTXO was used in a transaction. network_index should not be populated if there is no notion of an operation index in a blockchain (typically most account-based blockchains).

related_operationsArray<OperationIdentifier>

Restrict referenced related_operations to identifier indices < the current operation_identifier.index. This ensures there exists a clear DAG-structure of relations. Since operations are one-sided, one could imagine relating operations in a single transfer or linking operations in a call tree.

Show child attributes
indexinteger<int64>>= 0required

The operation index is used to ensure each operation has a unique identifier within a transaction. This index is only relative to the transaction and NOT GLOBAL. The operations in each transaction should start from index 0. To clarify, there may not be any notion of an operation index in the blockchain being described.

network_indexinteger<int64>>= 0

Some blockchains specify an operation index that is essential for client use. For example, Bitcoin uses a network_index to identify which UTXO was used in a transaction. network_index should not be populated if there is no notion of an operation index in a blockchain (typically most account-based blockchains).

typestringrequired

Type is the network-specific type of the operation. Ensure that any type that can be returned here is also specified in the NetworkOptionsResponse. This can be very useful to downstream consumers that parse all block data.

statusstring

Status is the network-specific status of the operation. Status is not defined on the transaction object because blockchains with smart contracts may have transactions that partially apply (some operations are successful and some are not). Blockchains with atomic transactions (all operations succeed or all operations fail) will have the same status for each operation. On-chain operations (operations retrieved in the /block and /block/transaction endpoints) MUST have a populated status field (anything on-chain must have succeeded or failed). However, operations provided during transaction construction (often times called "intent" in the documentation) MUST NOT have a populated status field (operations yet to be included on-chain have not yet succeeded or failed).

accountAccountIdentifier

Rosetta account identifier object.

Show child attributes
addressstringrequired

The address may be a cryptographic public key (or some encoding of it) or a provided username.

sub_accountSubAccountIdentifier

Sub Account value.

Show child attributes
addressstringrequired

The SubAccount address may be a cryptographic value or some other identifier (ex: bonded) that uniquely specifies a SubAccount.

metadataobject

If the SubAccount address is not sufficient to uniquely specify a SubAccount, any other identifying information can be stored here. It is important to note that two SubAccounts with identical addresses but differing metadata will not be considered equal by clients.

metadataobject

Blockchains that utilize a username model (where the address is not a derivative of a cryptographic public key) should specify the public key(s) owned by the address in metadata.

Show child attributes
chain_codestring

Hex string encoded extension of bip32 private and public keys with an extra 256 bits of entropy that consists of 32 bytes

amountAmount

Amount value.

Show child attributes
valuestringrequired

Value of the transaction in atomic units represented as an arbitrary-sized signed integer. For example, 1 BTC would be represented by a value of 100000000.

currencyCurrencyrequired

Rosetta currency object.

Show child attributes
symbolstringrequired

Canonical symbol associated with a currency.

decimalsinteger<int32>>= 0required

Number of decimal places in the standard unit representation of the amount. For example, BTC has 8 decimals. Note that it is not possible to represent the value of some currency in atomic units that is not base 10.

metadataany

Additional metadata object.

metadataobject

Additional metadata object.

coin_changeCoinChange

Coin Change value.

Show child attributes
coin_identifierCoinIdentifierrequired

Rosetta coin identifier object.

Show child attributes
identifierstringrequired

Identifier should be populated with a globally unique identifier of a Coin. In Bitcoin, this identifier would be transaction_hash:index.

coin_actionCoinActioncoin_createdcoin_spentrequired

Coin Action value.

metadataOperationMetadata

Additional metadata object.

Show child attributes
withdrawalAmountAmount

If it's a withdrawal operation, the amount will re returned here.

Show child attributes
valuestringrequired

Value of the transaction in atomic units represented as an arbitrary-sized signed integer. For example, 1 BTC would be represented by a value of 100000000.

currencyCurrencyrequired

Rosetta currency object.

Show child attributes
symbolstringrequired

Canonical symbol associated with a currency.

decimalsinteger<int32>>= 0required

Number of decimal places in the standard unit representation of the amount. For example, BTC has 8 decimals. Note that it is not possible to represent the value of some currency in atomic units that is not base 10.

metadataany

Additional metadata object.

metadataobject

Additional metadata object.

depositAmountAmount

If it's a registration operation, the amount will re returned here.

Show child attributes
valuestringrequired

Value of the transaction in atomic units represented as an arbitrary-sized signed integer. For example, 1 BTC would be represented by a value of 100000000.

currencyCurrencyrequired

Rosetta currency object.

Show child attributes
symbolstringrequired

Canonical symbol associated with a currency.

decimalsinteger<int32>>= 0required

Number of decimal places in the standard unit representation of the amount. For example, BTC has 8 decimals. Note that it is not possible to represent the value of some currency in atomic units that is not base 10.

metadataany

Additional metadata object.

metadataobject

Additional metadata object.

refundAmountAmount

If it's a deregistration operation, the amount will re returned here.

Show child attributes
valuestringrequired

Value of the transaction in atomic units represented as an arbitrary-sized signed integer. For example, 1 BTC would be represented by a value of 100000000.

currencyCurrencyrequired

Rosetta currency object.

Show child attributes
symbolstringrequired

Canonical symbol associated with a currency.

decimalsinteger<int32>>= 0required

Number of decimal places in the standard unit representation of the amount. For example, BTC has 8 decimals. Note that it is not possible to represent the value of some currency in atomic units that is not base 10.

metadataany

Additional metadata object.

metadataobject

Additional metadata object.

staking_credentialPublicKey

Staking Credential value.

Show child attributes
hex_bytesstringrequired

Hex-encoded public key bytes in the format specified by the CurveType.

curve_typeCurveTypesecp256k1secp256r1edwards25519tweedlerequired

Curve Type value.

pool_key_hashstring

Cardano transaction hash.

epochnumber

Cardano epoch number.

tokenBundleArray<TokenBundleItem>

A token bundle is a heterogeneous (‘mixed’) collection of tokens. Any tokens can be bundled together. Token bundles are the standard - and only - way to represent and store assets on the Cardano blockchain.

Show child attributes
policyIdstringrequired

Policy Id hex string

tokensArray<Amount>required

Tokens value.

Show child attributes
valuestringrequired

Value of the transaction in atomic units represented as an arbitrary-sized signed integer. For example, 1 BTC would be represented by a value of 100000000.

currencyCurrencyrequired

Rosetta currency object.

Show child attributes
symbolstringrequired

Canonical symbol associated with a currency.

decimalsinteger<int32>>= 0required

Number of decimal places in the standard unit representation of the amount. For example, BTC has 8 decimals. Note that it is not possible to represent the value of some currency in atomic units that is not base 10.

metadataany

Additional metadata object.

metadataobject

Additional metadata object.

poolRegistrationCertstring

Certificate of a pool registration encoded as hex string

poolRegistrationParamsPoolRegistrationParams

Cardano stake pool identifier or key hash.

Show child attributes
vrfKeyHashstringrequired

Cardano transaction hash.

rewardAddressstringrequired

Cardano reward address.

pledgestringrequired

Lovelace amount to pledge

coststringrequired

Operational costs per epoch lovelace

poolOwnersArray<string>required

Cardano stake pool identifier or key hash.

relaysArray<Relay>required

Relays value.

Show child attributes
typestring

Type value.

ipv4string

Ipv4 value.

ipv6string

Ipv6 value.

dnsNamestring

Dns Name value.

portstring

Port value.

marginPoolMargin

Margin value.

Show child attributes
numeratorstringrequired

Numerator value.

denominatorstringrequired

Denominator value.

margin_percentagestring

Margin Percentage value.

poolMetadataPoolMetadata

Cardano stake pool identifier or key hash.

Show child attributes
urlstringrequired

Url value.

hashstringrequired

Cardano transaction hash.

voteRegistrationMetadataVoteRegistrationMetadata

A Catalyst registration transaction is a regular Cardano transaction with a specific transaction metadata associated with it.

Show child attributes
stakeKeyPublicKeyrequired

The staking key on the Cardano network

Show child attributes
hex_bytesstringrequired

Hex-encoded public key bytes in the format specified by the CurveType.

curve_typeCurveTypesecp256k1secp256r1edwards25519tweedlerequired

Curve Type value.

votingKeyPublicKeyrequired

Catalyst voting key

Show child attributes
hex_bytesstringrequired

Hex-encoded public key bytes in the format specified by the CurveType.

curve_typeCurveTypesecp256k1secp256r1edwards25519tweedlerequired

Curve Type value.

rewardAddressstringrequired

Shelley address to receive rewards

votingNoncenumberrequired

Unsigned integer (of CBOR major type 0). Current slot number

votingSignaturestringrequired

ED25119 signature CBOR byte array of blake2b-256 hash of the registration metadata signed using the staking key

metadataobjectrequired

Additional metadata object.

Show child attributes
ttlstringrequired

Ttl value.

protocol_parametersProtocolParametersrequired

Protocol Parameters value.

Show child attributes
coinsPerUtxoSizestringrequired

Coins Per Utxo Size value.

maxTxSizenumberrequired

Max Tx Size value.

maxValSizenumberrequired

Max Val Size value.

keyDepositstringrequired

key registration cost in Lovelace

maxCollateralInputsnumberrequired

Max Collateral Inputs value.

minFeeCoefficientnumberrequired

Min Fee Coefficient value.

minFeeConstantnumberrequired

Min Fee Constant value.

minPoolCoststringrequired

Cardano stake pool identifier or key hash.

poolDepositstringrequired

pool registration cost in Lovelace

protocolintegerrequired

Protocol value.

public_keysArray<PublicKey>

Public Keys value.

Show child attributes
hex_bytesstringrequired

Hex-encoded public key bytes in the format specified by the CurveType.

curve_typeCurveTypesecp256k1secp256r1edwards25519tweedlerequired

Curve Type value.

Response

200OK

HTTP 200 response for constructionPayloads.

400Bad Request

Bad Request. The request is malformed or contains invalid parameters.

401Unauthorized

Unauthorized: API key is present but rejected by the NOWNodes gateway.

422Unprocessable Entity

Missing API key. The NOWNodes gateway returns plain text for this error.

500Internal Server Error

Internal Server Error. The gateway or backend failed while processing the request.