Create Transaction

From ArdorDocs
Jump to: navigation, search

The following API calls create Ardor transactions using HTTP POST requests (Javadoc documentation). Follow the links for examples and HTTP POST request parameters specific to each call. Refer to the sections below for HTTP POST request parameters and JSON response fields common to all calls that create transactions. Calls in italics are phasing-safe (refer to Get Constants and Create Phasing Poll)


Create Transaction Request

The following HTTP POST parameters are common to all API calls that create transactions:

  • chain is the chain where the transaction will be generated (for instance: Ignis)
  • secretPhrase is the secret passphrase of the account (optional, but transaction neither signed nor broadcast if omitted)
  • publicKey is the public key of the account (optional if secretPhrase provided)
  • feeNQT is the fee (in NQT) for the transaction. For child chain transactions, assuming no other fee restrictions, specify feeNQT=-1 to let the server calculate the minimum fee in ARDR and specify in the feeRateNQTPerFXT parameter the conversion rate between 1 child chain NQT to 1 whole Ardor unit.
Transaction Fee (ARDR) Reasons
Default Ardor fee 1 permanent transaction
Default Child Chain fee 0.01 prunable transaction
New account fee 1 creates permanent global entity
Balance leasing 0.1 Ardor chain only, not frequently used
Ardor Coin Exchange 0.5 permanent transaction
Asset issuance 100 create permanent global entity, Ignis chain only, not frequently used, need to reduce scam assets
Singleton asset issuance 1 + 1 per 32b Ignis chain only, more frequently used, but still creates global permanent entity
Asset increase 10 Ignis chain only, rarely used
Dividend payment 0.1 needs processing, not frequently used
Set asset control 10 Ignis chain only, not frequently used, asset issuers only
Set account control 1 Ignis chain only, not frequently used
Cloud data upload 0.1 + 0.01 per 1kb prunable, but takes space
Poll creation 1 + 0.1 per option > 20 + 0.2 per 32b > 288b not frequently used, need to keep until poll is over, takes space
Phasing approval 0.01 per approved tx needs processing
Account info 1 + 1 per 32b permanent, Ignis only, rarely used
Set account property 0.1 + 0.1 per 32b permanent, Ignis only, not frequently used
Alias assignment 1 + 1 per 32b creates permanent unique entity, not frequently used
Shuffling (total) 0.12 takes space, but prunable, not frequently used
Shuffling penalty 10 IGNIS, 10 Bitswift must be affordable, but not negligible
Currency issuance 4 / 100 / 2500 creates permanent unique entity, not frequently used
Marketplace listing 0.2 + 0.2 per 32b takes space, need to keep until delisting, not frequently used
Marketplace delivery 0.1 + 0.2 per 32b takes space, need to keep
Permanent message 0.1 + 0.1 per 32b permanent
Prunable message 0.01 per 1k prunable
Phasing appendix 0.01 balance independent, 0.2 balance dependent + 0.01 per 32b size depends on size and complexity, needs processing
Composite phasing appendix 0.02 + 0.02 per 32b + per poll fees determined by phasing complexity
Referenced Tx deposit 10 refundable
  • feeRateNQTPerFXT is the conversion rate between 1 child chain NQT to 1 whole Ardor FXT.
  • minBundlerBalanceFXT is the limit on effective bundler account balance.
  • deadline is the deadline (in minutes) for the transaction to be confirmed, 32767 minutes maximum
  • referencedTransactionFullHash creates a chained transaction, meaning that the current transaction cannot be confirmed unless the referenced transaction is also confirmed (optional)
  • broadcast is set to false to prevent broadcasting the transaction to the network (optional)
  • voucher see Transaction vouchers (optional)

Note: An optional arbitrary message can be appended to any transaction by adding message-related parameters as in Send Message.

Note: Any phasing-safe transaction (refer to Create Transaction) can have its execution deferred either conditionally or unconditionally (refer to Create Phasing Poll).

Create Transaction Response

The following JSON response fields are common to all API calls that create transactions:

  • chain is the chain related with the transaction (for instance: Ignis)
  • signatureHash (S) is a SHA-256 hash of the transaction signature
  • unsignedTransactionBytes (S) are the unsigned transaction bytes
  • transactionJSON (O) is a transaction object (refer to Get Transaction for details)
  • broadcasted (B) is true if the transaction was broadcast, false otherwise
  • requestProcessingTime (N) is the API request processing time (in millisec)
  • transactionBytes (S) are the signed transaction bytes
  • fullHash (S) is the full hash of the signed transaction
  • transaction (S) is the ID of the newly created transaction