Cardano Module
Asset
Represents a custom asset in the Cardano blockchain.
Field | Type | Label | Description |
---|---|---|---|
name | bytes | Name of the custom asset. | |
quantity | uint64 | Quantity of the custom asset. |
AuxData
Auxiliary data not directly tied to the validation process
Field | Type | Label | Description |
---|---|---|---|
metadata | Metadata | repeated | List of auxiliary metadata elements. |
scripts | Script | repeated | List of auxiliary scripts. |
BigInt
Represents a big integer for Plutus data in Cardano.
Define the fields of BigInt based on your original Rust code
BoundedBytes
Represents a bounded bytes for Plutus data in Cardano.
Define the fields of BoundedBytes based on your original Rust code
Certificate
Represents a certificate in Cardano.
Field | Type | Label | Description |
---|---|---|---|
stake_registration | StakeCredential | Stake registration certificate. | |
stake_deregistration | StakeCredential | Stake deregistration certificate. | |
stake_delegation | StakeDelegationCert | Stake delegation certificate. | |
pool_registration | PoolRegistrationCert | Pool registration certificate. | |
pool_retirement | PoolRetirementCert | Pool retirement certificate. | |
genesis_key_delegation | GenesisKeyDelegationCert | Genesis key delegation certificate. | |
move_instantaneous_rewards_cert | MoveInstantaneousRewardCert | Move instantaneous rewards certificate. |
Collateral
Represents the collateral information for a transaction.
Field | Type | Label | Description |
---|---|---|---|
collateral | TxInput | repeated | Collateral inputs for the transaction. |
collateral_return | TxOutput | Collateral return in case of script failure. | |
total_collateral | uint64 | Total amount of collateral. |
Constr
Represents a constructor for Plutus data in Cardano.
Define the fields of Constr based on your original Rust code
GenesisKeyDelegationCert
Represents a genesis key delegation certificate in Cardano.
Field | Type | Label | Description |
---|---|---|---|
genesis_hash | bytes | Genesis hash. | |
genesis_delegate_hash | bytes | Genesis delegate hash. | |
vrf_keyhash | bytes | VRF key hash. |
Metadata
Field | Type | Label | Description |
---|---|---|---|
label | uint64 | ||
value | Metadatum |
Metadatum
Field | Type | Label | Description |
---|---|---|---|
int | int64 | ||
bytes | bytes | ||
text | string | ||
array | MetadatumArray | ||
map | MetadatumMap |
MetadatumArray
Field | Type | Label | Description |
---|---|---|---|
items | Metadatum | repeated |
MetadatumMap
Field | Type | Label | Description |
---|---|---|---|
pairs | MetadatumPair | repeated |
MetadatumPair
Field | Type | Label | Description |
---|---|---|---|
key | Metadatum | ||
value | Metadatum |
MoveInstantaneousRewardCert
Represents a move instantaneous reward certificate in Cardano.
Define the fields of MoveInstantaneousReward based on your original Rust code
Multiasset
Represents a multi-asset group in the Cardano blockchain.
Field | Type | Label | Description |
---|---|---|---|
policy_id | bytes | Policy ID governing the custom assets. | |
assets | Asset | repeated | List of custom assets. |
NativeScript
Represents a native script in Cardano.
Field | Type | Label | Description |
---|---|---|---|
script_pubkey | bytes | Script based on an address key hash. | |
script_all | NativeScriptList | Script that requires all nested scripts to be satisfied. | |
script_any | NativeScriptList | Script that requires any of the nested scripts to be satisfied. | |
script_n_of_k | ScriptNOfK | Script that requires k out of n nested scripts to be satisfied. | |
invalid_before | uint64 | Slot number before which the script is invalid. | |
invalid_hereafter | uint64 | Slot number after which the script is invalid. |
NativeScriptList
Represents a list of native scripts.
Field | Type | Label | Description |
---|---|---|---|
items | NativeScript | repeated | List of native scripts. |
PlutusData
Represents a Plutus data item in Cardano.
Field | Type | Label | Description |
---|---|---|---|
constr | Constr | Constructor. | |
map | PlutusDataMap | Map of Plutus data. | |
big_int | BigInt | Big integer. | |
bounded_bytes | BoundedBytes | Bounded bytes. | |
array | PlutusDataArray | Array of Plutus data. |
PlutusDataArray
Represents an array of Plutus data in Cardano.
Field | Type | Label | Description |
---|---|---|---|
items | PlutusData | repeated | List of Plutus data items. |
PlutusDataMap
Represents a map of Plutus data in Cardano.
Field | Type | Label | Description |
---|---|---|---|
pairs | PlutusDataPair | repeated | List of key-value pairs. |
PlutusDataPair
Represents a key-value pair for Plutus data in Cardano.
Field | Type | Label | Description |
---|---|---|---|
key | PlutusData | Key of the pair. | |
value | PlutusData | Value of the pair. |
PoolMetadata
Represents pool metadata in Cardano.
Define the fields of PoolMetadata based on your original Rust code
PoolRegistrationCert
Represents a pool registration certificate in Cardano.
Field | Type | Label | Description |
---|---|---|---|
operator | bytes | Operator key hash. | |
vrf_keyhash | bytes | VRF key hash. | |
pledge | uint64 | Pledge amount. | |
cost | uint64 | Pool cost. | |
margin | UnitInterval | Pool margin. | |
reward_account | bytes | Reward account. | |
pool_owners | bytes | repeated | List of pool owner key hashes. |
relays | Relay | repeated | List of relays. |
pool_metadata | PoolMetadata | Pool metadata. |
PoolRetirementCert
Represents a pool retirement certificate in Cardano.
Field | Type | Label | Description |
---|---|---|---|
pool_keyhash | bytes | Pool key hash. | |
epoch | uint64 | Retirement epoch. |
Redeemer
Redeemer information for a Plutus script.
Field | Type | Label | Description |
---|---|---|---|
purpose | Purpose | Purpose of the redeemer. | |
datum | PlutusData | Plutus data associated with the redeemer. |
Relay
Represents a relay in Cardano.
Define the fields of Relay based on your original Rust code
Script
Represents a script in Cardano.
Field | Type | Label | Description |
---|---|---|---|
native | NativeScript | Native script. | |
plutus_v1 | bytes | Plutus V1 script. | |
plutus_v2 | bytes | Plutus V2 script. |
ScriptNOfK
Represents a "k out of n" native script.
Field | Type | Label | Description |
---|---|---|---|
k | uint32 | The number of required satisfied scripts. | |
scripts | NativeScript | repeated | List of native scripts. |
StakeCredential
Represents a stake credential in Cardano.
Field | Type | Label | Description |
---|---|---|---|
addr_key_hash | bytes | Address key hash. | |
script_hash | bytes | Script hash. |
StakeDelegationCert
Represents a stake delegation certificate in Cardano.
Field | Type | Label | Description |
---|---|---|---|
stake_credential | StakeCredential | Stake credential. | |
pool_keyhash | bytes | Pool key hash. |
Tx
Represents a transaction in the Cardano blockchain.
Field | Type | Label | Description |
---|---|---|---|
inputs | TxInput | repeated | List of transaction inputs |
outputs | TxOutput | repeated | List of transaction outputs |
certificates | Certificate | repeated | List of certificates |
withdrawals | Withdrawal | repeated | List of withdrawals |
mint | Multiasset | repeated | List of minted custom assets |
reference_inputs | TxInput | repeated | List of reference inputs |
witnesses | WitnessSet | Witnesses that validte the transaction | |
collateral | Collateral | Collateral details in case of failed transaction | |
fee | uint64 | Transaction fee in ADA | |
validity | TxValidity | Validity interval of the transaction | |
successful | bool | Flag indicating whether the transaction was successful | |
auxiliary | AuxData | Auxiliary data not directly tied to the validation process |
TxInput
Represents a transaction input in the Cardano blockchain.
Field | Type | Label | Description |
---|---|---|---|
tx_hash | bytes | Hash of the previous transaction. | |
output_index | uint32 | Index of the output in the previous transaction. | |
as_output | TxOutput | Content of the input represented as output of the related transaction |
TxOutput
Represents a transaction output in the Cardano blockchain.
Field | Type | Label | Description |
---|---|---|---|
address | bytes | Address receiving the output. | |
coin | uint64 | Amount of ADA in the output. | |
assets | Multiasset | repeated | Additional native (non-ADA) assets in the output. |
datum | PlutusData | Plutus data associated with the output. | |
datum_hash | bytes | Hash of the Plutus data. | |
script | Script | Script associated with the output. | |
redeemer | Redeemer | Redeemer for the Plutus script. |
TxValidity
Represents the validity interval of a transaction.
Field | Type | Label | Description |
---|---|---|---|
start | uint64 | Start of the validity interval. | |
ttl | uint64 | End of the validity interval (TTL: Time to Live). |
UnitInterval
Represents a unit interval in Cardano.
Define the fields of UnitInterval based on your original Rust code
VKeyWitness
Represents a VKey witness used to sign a transaction.
Field | Type | Label | Description |
---|---|---|---|
vkey | bytes | Verification key. | |
signature | bytes | Signature generated using the associated private key. |
Withdrawal
Represents a withdrawal from a reward account.
Field | Type | Label | Description |
---|---|---|---|
reward_account | bytes | Address of the reward account. | |
coin | uint64 | Amount of ADA withdrawn. |
WitnessSet
Represents a set of witnesses that validate a transaction
Field | Type | Label | Description |
---|---|---|---|
vkeywitness | VKeyWitness | repeated | List of VKey witnesses. |
script | Script | repeated | List of scripts. |
plutus_datums | PlutusData | repeated | List of Plutus data elements associated with the transaction. |
Purpose
Purpose of the redeemer in a transaction.
Name | Number | Description |
---|---|---|
PURPOSE_UNSPECIFIED | 0 | |
PURPOSE_SPEND | 1 | |
PURPOSE_MINT | 2 | |
PURPOSE_CERT | 3 | |
PURPOSE_REWARD | 4 |