models

package
v1.0.4-alpha.2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 23, 2024 License: Apache-2.0 Imports: 15 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func MapRegisteredChainIDs

func MapRegisteredChainIDs(registered []isc.ChainID) []string

Types

type AccountFoundriesResponse

type AccountFoundriesResponse struct {
	FoundrySerialNumbers []uint32 `json:"foundrySerialNumbers" swagger:"required"`
}

type AccountListResponse

type AccountListResponse struct {
	Accounts []string `json:"accounts" swagger:"required"`
}

type AccountNFTsResponse

type AccountNFTsResponse struct {
	NFTIDs []string `json:"nftIds" swagger:"required"`
}

type AccountNonceResponse

type AccountNonceResponse struct {
	Nonce string `json:"nonce" swagger:"required,desc(The nonce (uint64 as string))"`
}

type AccountsResponse

type AccountsResponse struct {
	AccountIDs []string `json:"accountIds" swagger:"required"`
}

type AddUserRequest

type AddUserRequest struct {
	Username    string   `json:"username" swagger:"required"`
	Password    string   `json:"password" swagger:"required"`
	Permissions []string `json:"permissions" swagger:"required"`
}

type AliasOutputMetricItem

type AliasOutputMetricItem MetricItem[*Output]

ChainMetrics Echo Swagger does not support generics such as MetricItem[Foo] Creating separate types works instead. To not create a mapper for each type, the actual service remains using MetricItem[Foo] but this model here is presented to the docs. This can be removed if we change to swag/echo-swagger

type AssetsResponse

type AssetsResponse struct {
	BaseTokens   string                 `json:"baseTokens" swagger:"required,desc(The base tokens (uint64 as string))"`
	NativeTokens []*isc.NativeTokenJSON `json:"nativeTokens" swagger:"required"`
}

type BlockInfoResponse

type BlockInfoResponse struct {
	BlockIndex            uint32    `json:"blockIndex" swagger:"required,min(1)"`
	Timestamp             time.Time `json:"timestamp" swagger:"required"`
	TotalRequests         uint16    `json:"totalRequests" swagger:"required,min(1)"`
	NumSuccessfulRequests uint16    `json:"numSuccessfulRequests" swagger:"required,min(1)"`
	NumOffLedgerRequests  uint16    `json:"numOffLedgerRequests" swagger:"required,min(1)"`
	PreviousAliasOutput   string    `json:"previousAliasOutput" swagger:"required,min(1)"`
	GasBurned             string    `json:"gasBurned" swagger:"required,desc(The burned gas (uint64 as string))"`
	GasFeeCharged         string    `json:"gasFeeCharged" swagger:"required,desc(The charged gas fee (uint64 as string))"`
}

func MapBlockInfoResponse

func MapBlockInfoResponse(info *blocklog.BlockInfo) *BlockInfoResponse

type ChainInfoResponse

type ChainInfoResponse struct {
	IsActive     bool                `json:"isActive" swagger:"desc(Whether or not the chain is active),required"`
	ChainID      string              `json:"chainID" swagger:"desc(ChainID (Bech32-encoded)),required"`
	EVMChainID   uint16              `json:"evmChainId" swagger:"desc(The EVM chain ID),required,min(1)"`
	ChainOwnerID string              `json:"chainOwnerId" swagger:"desc(The chain owner address (Bech32-encoded)),required"`
	GasFeePolicy *gas.FeePolicy      `json:"gasFeePolicy" swagger:"desc(The gas fee policy),required"`
	GasLimits    *gas.Limits         `json:"gasLimits" swagger:"desc(The gas limits),required"`
	PublicURL    string              `json:"publicURL" swagger:"desc(The fully qualified public url leading to the chains metadata),required"`
	Metadata     PublicChainMetadata `json:"metadata" swagger:"desc(The metadata of the chain),required"`
}

ChainInfoResponse includes the metadata standard

func MapChainInfoResponse

func MapChainInfoResponse(chainInfo *dto.ChainInfo, evmChainID uint16) ChainInfoResponse

type ChainMessageMetrics

type ChainMessageMetrics struct {
	InStateOutput      InStateOutputMetricItem       `json:"inStateOutput" swagger:"required"`
	InAliasOutput      AliasOutputMetricItem         `json:"inAliasOutput" swagger:"required"`
	InOutput           InOutputMetricItem            `json:"inOutput" swagger:"required"`
	InOnLedgerRequest  OnLedgerRequestMetricItem     `json:"inOnLedgerRequest" swagger:"required"`
	InTxInclusionState TxInclusionStateMsgMetricItem `json:"inTxInclusionState" swagger:"required"`

	OutPublishStateTransaction      PublisherStateTransactionItem `json:"outPublisherStateTransaction" swagger:"required"`
	OutPublishGovernanceTransaction TransactionMetricItem         `json:"outPublishGovernanceTransaction" swagger:"required"`
	OutPullLatestOutput             InterfaceMetricItem           `json:"outPullLatestOutput" swagger:"required"`
	OutPullTxInclusionState         TransactionIDMetricItem       `json:"outPullTxInclusionState" swagger:"required"`
	OutPullOutputByID               UTXOInputMetricItem           `json:"outPullOutputByID" swagger:"required"`
}

func MapChainMessageMetrics

func MapChainMessageMetrics(metrics *dto.ChainMessageMetrics) *ChainMessageMetrics

type ChainRecord

type ChainRecord struct {
	IsActive    bool     `json:"isActive" swagger:"required"`
	AccessNodes []string `json:"accessNodes" swagger:"required"`
}

type CommitteeInfoResponse

type CommitteeInfoResponse struct {
	AccessNodes    []CommitteeNode `json:"accessNodes" swagger:"desc(A list of all access nodes and their peering info.),required"`
	Active         bool            `json:"active" swagger:"desc(Whether or not the chain is active.),required"`
	CandidateNodes []CommitteeNode `json:"candidateNodes" swagger:"desc(A list of all candidate nodes and their peering info.),required"`
	ChainID        string          `json:"chainId" swagger:"desc(ChainID (Bech32-encoded).),required"`
	CommitteeNodes []CommitteeNode `json:"committeeNodes" swagger:"desc(A list of all committee nodes and their peering info.),required"`
	StateAddress   string          `json:"stateAddress" swagger:"desc(State address, if we are part of it.),required"`
}

type CommitteeNode

type CommitteeNode struct {
	AccessAPI string                    `json:"accessAPI" swagger:"required"`
	Node      PeeringNodeStatusResponse `json:"node" swagger:"required"`
}

func MapCommitteeNode

func MapCommitteeNode(status *dto.ChainNodeStatus) CommitteeNode

func MapCommitteeNodes

func MapCommitteeNodes(status []*dto.ChainNodeStatus) []CommitteeNode

type ConsensusPipeMetrics

type ConsensusPipeMetrics struct {
	EventStateTransitionMsgPipeSize int `json:"eventStateTransitionMsgPipeSize" swagger:"required"`
	EventPeerLogIndexMsgPipeSize    int `json:"eventPeerLogIndexMsgPipeSize" swagger:"required"`
	EventACSMsgPipeSize             int `json:"eventACSMsgPipeSize" swagger:"required"`
	EventVMResultMsgPipeSize        int `json:"eventVMResultMsgPipeSize" swagger:"required"`
	EventTimerMsgPipeSize           int `json:"eventTimerMsgPipeSize" swagger:"required"`
}

func MapConsensusPipeMetrics

func MapConsensusPipeMetrics(pipeMetrics chain.ConsensusPipeMetrics) *ConsensusPipeMetrics

type ConsensusWorkflowMetrics

type ConsensusWorkflowMetrics struct {
	FlagStateReceived        bool `json:"flagStateReceived" swagger:"desc(Shows if state output is received in current consensus iteration),required"`
	FlagBatchProposalSent    bool `json:"flagBatchProposalSent" swagger:"desc(Shows if batch proposal is sent out in current consensus iteration),required"`
	FlagConsensusBatchKnown  bool `` /* 135-byte string literal not displayed */
	FlagVMStarted            bool `json:"flagVMStarted" swagger:"desc(Shows if virtual machine is started in current consensus iteration),required"`
	FlagVMResultSigned       bool `` /* 131-byte string literal not displayed */
	FlagTransactionFinalized bool `` /* 132-byte string literal not displayed */
	FlagTransactionPosted    bool `json:"flagTransactionPosted" swagger:"desc(Shows if transaction is posted to L1 in current consensus iteration),required"`
	FlagTransactionSeen      bool `` /* 136-byte string literal not displayed */
	FlagInProgress           bool `` /* 129-byte string literal not displayed */

	TimeBatchProposalSent    time.Time `` /* 128-byte string literal not displayed */
	TimeConsensusBatchKnown  time.Time `` /* 149-byte string literal not displayed */
	TimeVMStarted            time.Time `json:"timeVMStarted" swagger:"desc(Shows when virtual machine was last started in current consensus iteration),required"`
	TimeVMResultSigned       time.Time `` /* 146-byte string literal not displayed */
	TimeTransactionFinalized time.Time `` /* 184-byte string literal not displayed */
	TimeTransactionPosted    time.Time `` /* 129-byte string literal not displayed */
	TimeTransactionSeen      time.Time `` /* 151-byte string literal not displayed */
	TimeCompleted            time.Time `json:"timeCompleted" swagger:"desc(Shows when algorithm was last completed in current consensus iteration),required"`

	CurrentStateIndex uint32 `json:"currentStateIndex" swagger:"desc(Shows current state index of the consensus),min(1)"`
}

type ContractCallViewRequest

type ContractCallViewRequest struct {
	ContractName  string        `json:"contractName" swagger:"desc(The contract name),required"`
	ContractHName string        `json:"contractHName" swagger:"desc(The contract name as HName (Hex)),required"`
	FunctionName  string        `json:"functionName" swagger:"desc(The function name),required"`
	FunctionHName string        `json:"functionHName" swagger:"desc(The function name as HName (Hex)),required"`
	Arguments     dict.JSONDict `json:"arguments" swagger:"desc(Encoded arguments to be passed to the function),required"`
	Block         string        `json:"block" swagger:"desc(block index or trie root to execute the view call in, latest block will be used if not specified)"`
}

type ContractInfoResponse

type ContractInfoResponse struct {
	HName       string `json:"hName" swagger:"desc(The id (HName as Hex)) of the contract.),required"`
	Name        string `json:"name" swagger:"desc(The name of the contract.),required"`
	ProgramHash string `json:"programHash" swagger:"desc(The hash of the contract. (Hex encoded)),required"`
}

type ControlAddressesResponse

type ControlAddressesResponse struct {
	GoverningAddress string `json:"governingAddress" swagger:"required,desc(The governing address (Bech32))"`
	SinceBlockIndex  uint32 `json:"sinceBlockIndex" swagger:"required,min(1),desc(The block index (uint32)"`
	StateAddress     string `json:"stateAddress" swagger:"required,desc(The state address (Bech32))"`
}

type DKSharesInfo

type DKSharesInfo struct {
	Address         string   `json:"address" swagger:"desc(New generated shared address.),required"`
	PeerIdentities  []string `json:"peerIdentities" swagger:"desc(Identities of the nodes sharing the key. (Hex)),required"`
	PeerIndex       *uint16  `` /* 127-byte string literal not displayed */
	PublicKey       string   `json:"publicKey" swagger:"desc(Used public key. (Hex)),required"`
	PublicKeyShares []string `json:"publicKeyShares" swagger:"desc(Public key shares for all the peers. (Hex)),required"`
	Threshold       uint16   `json:"threshold" swagger:"required,min(1)"`
}

DKSharesInfo stands for the DKShare representation, returned by the GET and POST methods.

type DKSharesPostRequest

type DKSharesPostRequest struct {
	PeerPubKeysOrNames []string `json:"peerIdentities" swagger:"desc(Names or hex encoded public keys of trusted peers to run DKG on.),required"`
	Threshold          uint16   `json:"threshold" swagger:"desc(Should be =< len(PeerPublicIdentities)),required,min(1)"`
	TimeoutMS          uint32   `json:"timeoutMS" swagger:"desc(Timeout in milliseconds.),required,min(1)"`
}

DKSharesPostRequest is a POST request for creating new DKShare.

type EstimateGasRequestOffledger

type EstimateGasRequestOffledger struct {
	Request     string `json:"requestBytes" swagger:"desc(Offledger Request (Hex)),required"`
	FromAddress string `json:"fromAddress" swagger:"desc(The address to estimate gas for(Hex)),required"`
}

type EstimateGasRequestOnledger

type EstimateGasRequestOnledger struct {
	Output string `json:"outputBytes" swagger:"desc(Serialized Output (Hex)),required"`
}

type EventsResponse

type EventsResponse struct {
	Events []*isc.EventJSON `json:"events" swagger:"required"`
}

type FoundryOutputResponse

type FoundryOutputResponse struct {
	FoundryID string         `json:"foundryId" swagger:"required"`
	Assets    AssetsResponse `json:"assets" swagger:"required"`
}

type GovAllowedStateControllerAddressesResponse

type GovAllowedStateControllerAddressesResponse struct {
	Addresses []string `json:"addresses" swagger:"desc(The allowed state controller addresses (Bech32-encoded))"`
}

type GovChainInfoResponse

type GovChainInfoResponse struct {
	ChainID      string                 `json:"chainID" swagger:"desc(ChainID (Bech32-encoded).),required"`
	ChainOwnerID string                 `json:"chainOwnerId" swagger:"desc(The chain owner address (Bech32-encoded).),required"`
	GasFeePolicy *gas.FeePolicy         `json:"gasFeePolicy" swagger:"desc(The gas fee policy),required"`
	GasLimits    *gas.Limits            `json:"gasLimits" swagger:"desc(The gas limits),required"`
	PublicURL    string                 `json:"publicURL" swagger:"desc(The fully qualified public url leading to the chains metadata),required"`
	Metadata     GovPublicChainMetadata `json:"metadata" swagger:"desc(The metadata of the chain),required"`
}

type GovChainOwnerResponse

type GovChainOwnerResponse struct {
	ChainOwner string `json:"chainOwner" swagger:"desc(The chain owner (Bech32-encoded))"`
}

type GovPublicChainMetadata

type GovPublicChainMetadata struct {
	EVMJsonRPCURL   string `json:"evmJsonRpcURL" swagger:"desc(The EVM json rpc url),required"`
	EVMWebSocketURL string `json:"evmWebSocketURL" swagger:"desc(The EVM websocket url)),required"`

	Name        string `json:"name" swagger:"desc(The name of the chain),required"`
	Description string `json:"description" swagger:"desc(The description of the chain.),required"`
	Website     string `json:"website" swagger:"desc(The official website of the chain.),required"`
}

Both Gov* structs should be removed at some point. The corecontract implementations should be moved outside the webapi, therefore using the webapi ChainInfo/Metadata structs should be avoided.

type InOutput

type InOutput struct {
	OutputID string  `json:"outputId" swagger:"desc(The output ID),required"`
	Output   *Output `json:"output" swagger:"desc(The parsed output),required"`
}

func InOutputFromISCInOutput

func InOutputFromISCInOutput(output *metrics.InOutput) *InOutput

type InOutputMetricItem

type InOutputMetricItem MetricItem[*InOutput]

ChainMetrics Echo Swagger does not support generics such as MetricItem[Foo] Creating separate types works instead. To not create a mapper for each type, the actual service remains using MetricItem[Foo] but this model here is presented to the docs. This can be removed if we change to swag/echo-swagger

type InStateOutput

type InStateOutput struct {
	OutputID string  `json:"outputId" swagger:"desc(The output ID),required"`
	Output   *Output `json:"output" swagger:"desc(The parsed output),required"`
}

func InStateOutputFromISCInStateOutput

func InStateOutputFromISCInStateOutput(output *metrics.InStateOutput) *InStateOutput

type InStateOutputMetricItem

type InStateOutputMetricItem MetricItem[*InStateOutput]

ChainMetrics Echo Swagger does not support generics such as MetricItem[Foo] Creating separate types works instead. To not create a mapper for each type, the actual service remains using MetricItem[Foo] but this model here is presented to the docs. This can be removed if we change to swag/echo-swagger

type InfoResponse

type InfoResponse struct {
	Version    string    `json:"version" swagger:"desc(The version of the node),required"`
	PublicKey  string    `json:"publicKey" swagger:"desc(The public key of the node (Hex)),required"`
	PeeringURL string    `json:"peeringURL" swagger:"desc(The net id of the node),required"`
	L1Params   *L1Params `json:"l1Params" swagger:"desc(The L1 parameters),required"`
}

type InterfaceMetricItem

type InterfaceMetricItem MetricItem[interface{}]

ChainMetrics Echo Swagger does not support generics such as MetricItem[Foo] Creating separate types works instead. To not create a mapper for each type, the actual service remains using MetricItem[Foo] but this model here is presented to the docs. This can be removed if we change to swag/echo-swagger

type L1Params

type L1Params struct {
	MaxPayloadSize int                  `json:"maxPayloadSize" swagger:"desc(The max payload size),required"`
	Protocol       ProtocolParameters   `json:"protocol" swagger:"desc(The protocol parameters),required"`
	BaseToken      parameters.BaseToken `json:"baseToken" swagger:"desc(The base token parameters),required"`
}

func MapL1Params

func MapL1Params(l1 *parameters.L1Params) *L1Params

type MetricItem

type MetricItem[T interface{}] struct {
	Messages    uint32    `json:"messages" swagger:"required,min(1)"`
	Timestamp   time.Time `json:"timestamp" swagger:"required"`
	LastMessage T         `json:"lastMessage" swagger:"required"`
}

func MapMetricItem

func MapMetricItem[T any, G any](metrics *dto.MetricItem[G], value T) MetricItem[T]

type MilestoneInfo

type MilestoneInfo struct {
	Index       uint32 `json:"index" swagger:"min(0)"`
	Timestamp   uint32 `json:"timestamp" swagger:"min(0)"`
	MilestoneID string `json:"milestoneId"`
}

func MilestoneFromIotaGoMilestone

func MilestoneFromIotaGoMilestone(milestone *nodeclient.MilestoneInfo) *MilestoneInfo

type MilestoneMetricItem

type MilestoneMetricItem MetricItem[*MilestoneInfo]

ChainMetrics Echo Swagger does not support generics such as MetricItem[Foo] Creating separate types works instead. To not create a mapper for each type, the actual service remains using MetricItem[Foo] but this model here is presented to the docs. This can be removed if we change to swag/echo-swagger

type NativeTokenIDRegistryResponse

type NativeTokenIDRegistryResponse struct {
	NativeTokenRegistryIDs []string `json:"nativeTokenRegistryIds" swagger:"required"`
}

type NodeMessageMetrics

type NodeMessageMetrics struct {
	RegisteredChainIDs RegisteredChainIDItems `json:"registeredChainIDs" swagger:"required"`

	InMilestone        MilestoneMetricItem           `json:"inMilestone" swagger:"required"`
	InStateOutput      InStateOutputMetricItem       `json:"inStateOutput" swagger:"required"`
	InAliasOutput      AliasOutputMetricItem         `json:"inAliasOutput" swagger:"required"`
	InOutput           InOutputMetricItem            `json:"inOutput" swagger:"required"`
	InOnLedgerRequest  OnLedgerRequestMetricItem     `json:"inOnLedgerRequest" swagger:"required"`
	InTxInclusionState TxInclusionStateMsgMetricItem `json:"inTxInclusionState" swagger:"required"`

	OutPublishStateTransaction      PublisherStateTransactionItem `json:"outPublisherStateTransaction" swagger:"required"`
	OutPublishGovernanceTransaction TransactionMetricItem         `json:"outPublishGovernanceTransaction" swagger:"required"`
	OutPullLatestOutput             InterfaceMetricItem           `json:"outPullLatestOutput" swagger:"required"`
	OutPullTxInclusionState         TransactionIDMetricItem       `json:"outPullTxInclusionState" swagger:"required"`
	OutPullOutputByID               UTXOInputMetricItem           `json:"outPullOutputByID" swagger:"required"`
}

func MapNodeMessageMetrics

func MapNodeMessageMetrics(metrics *dto.NodeMessageMetrics) *NodeMessageMetrics

type NodeOwnerCertificateResponse

type NodeOwnerCertificateResponse struct {
	Certificate string `json:"certificate" swagger:"desc(Certificate stating the ownership. (Hex)),required"`
}

type OffLedgerRequest

type OffLedgerRequest struct {
	ChainID string `json:"chainId" swagger:"desc(The chain id),required"`
	Request string `json:"request" swagger:"desc(Offledger Request (Hex)),required"`
}

type OnLedgerRequest

type OnLedgerRequest struct {
	ID       string  `json:"id" swagger:"desc(The request ID),required"`
	OutputID string  `json:"outputId" swagger:"desc(The output ID),required"`
	Output   *Output `json:"output" swagger:"desc(The parsed output),required"`
	Raw      string  `json:"raw" swagger:"desc(The raw data of the request (Hex)),required"`
}

func OnLedgerRequestFromISC

func OnLedgerRequestFromISC(request isc.OnLedgerRequest) *OnLedgerRequest

type OnLedgerRequestMetricItem

type OnLedgerRequestMetricItem MetricItem[*OnLedgerRequest]

ChainMetrics Echo Swagger does not support generics such as MetricItem[Foo] Creating separate types works instead. To not create a mapper for each type, the actual service remains using MetricItem[Foo] but this model here is presented to the docs. This can be removed if we change to swag/echo-swagger

type Output

type Output struct {
	OutputType iotago.OutputType `json:"outputType" swagger:"desc(The output type),required"`
	Raw        string            `json:"raw" swagger:"desc(The raw data of the output (Hex)),required"`
}

func OutputFromIotaGoOutput

func OutputFromIotaGoOutput(output iotago.Output) *Output

type OutputID

type OutputID struct {
	OutputID string `json:"outputId" swagger:"desc(The output ID),required"`
}

func OutputIDFromIotaGoOutputID

func OutputIDFromIotaGoOutputID(outputID iotago.OutputID) *OutputID

type PeeringNodeIdentityResponse

type PeeringNodeIdentityResponse struct {
	Name       string `json:"name" swagger:"unique peer name - easy identifier for humans,required"`
	PublicKey  string `json:"publicKey" swagger:"desc(The peers public key encoded in Hex),required"`
	PeeringURL string `json:"peeringURL" swagger:"desc(The peering URL of the peer),required"`
	IsTrusted  bool   `json:"isTrusted" swagger:"Desc(Whether or not the peer is trusted),required"`
}

type PeeringNodePublicKeyRequest

type PeeringNodePublicKeyRequest struct {
	PublicKey string `json:"publicKey" swagger:"desc(The peers public key encoded in Hex),required"`
}

type PeeringNodeStatusResponse

type PeeringNodeStatusResponse struct {
	Name       string `json:"name" swagger:"unique peer name - easy identifier for humans,required"`
	IsAlive    bool   `json:"isAlive" swagger:"desc(Whether or not the peer is activated),required"`
	PeeringURL string `json:"peeringURL" swagger:"desc(The peering URL of the peer),required"`
	NumUsers   int    `json:"numUsers" swagger:"desc(The amount of users attached to the peer),required"`
	PublicKey  string `json:"publicKey" swagger:"desc(The peers public key encoded in Hex),required"`
	IsTrusted  bool   `json:"isTrusted" swagger:"Desc(Whether or not the peer is trusted),required"`
}

type PeeringTrustRequest

type PeeringTrustRequest struct {
	Name       string `json:"name" swagger:"unique peer name - easy identifier for humans,required"`
	PublicKey  string `json:"publicKey" swagger:"desc(The peers public key encoded in Hex),required"`
	PeeringURL string `json:"peeringURL" swagger:"desc(The peering URL of the peer),required"`
}

type ProtocolParameters

type ProtocolParameters struct {
	// The version of the protocol running.
	Version byte `json:"version" swagger:"desc(The protocol version),required"`
	// The human friendly name of the network.
	NetworkName string `json:"networkName" swagger:"desc(The network name),required"`
	// The HRP prefix used for Bech32 addresses in the network.
	Bech32HRP iotago.NetworkPrefix `json:"bech32Hrp" swagger:"desc(The human readable network prefix),required"`
	// The minimum pow score of the network.
	MinPoWScore uint32 `json:"minPowScore" swagger:"desc(The minimal PoW score),required,min(1)"`
	// The below max depth parameter of the network.
	BelowMaxDepth uint8 `json:"belowMaxDepth" swagger:"desc(The networks max depth),required,min(1)"`
	// The rent structure used by given node/network.
	RentStructure RentStructure `json:"rentStructure" swagger:"desc(The rent structure of the protocol),required"`
	// TokenSupply defines the current token supply on the network.
	TokenSupply string `json:"tokenSupply" swagger:"desc(The token supply),required"`
}

type PublicChainMetadata

type PublicChainMetadata struct {
	EVMJsonRPCURL   string `json:"evmJsonRpcURL" swagger:"desc(The EVM json rpc url),required"`
	EVMWebSocketURL string `json:"evmWebSocketURL" swagger:"desc(The EVM websocket url)),required"`

	Name        string `json:"name" swagger:"desc(The name of the chain),required"`
	Description string `json:"description" swagger:"desc(The description of the chain.),required"`
	Website     string `json:"website" swagger:"desc(The official website of the chain.),required"`
}

type PublisherStateTransactionItem

type PublisherStateTransactionItem MetricItem[*StateTransaction]

ChainMetrics Echo Swagger does not support generics such as MetricItem[Foo] Creating separate types works instead. To not create a mapper for each type, the actual service remains using MetricItem[Foo] but this model here is presented to the docs. This can be removed if we change to swag/echo-swagger

type ReceiptResponse

type ReceiptResponse struct {
	Request       isc.RequestJSON            `json:"request" swagger:"required"`
	RawError      *isc.UnresolvedVMErrorJSON `json:"rawError,omitempty"`
	ErrorMessage  string                     `json:"errorMessage,omitempty"`
	GasBudget     string                     `json:"gasBudget" swagger:"required,desc(The gas budget (uint64 as string))"`
	GasBurned     string                     `json:"gasBurned" swagger:"required,desc(The burned gas (uint64 as string))"`
	GasFeeCharged string                     `json:"gasFeeCharged" swagger:"required,desc(The charged gas fee (uint64 as string))"`
	SDCharged     string                     `json:"storageDepositCharged" swagger:"required,desc(Storage deposit charged (uint64 as string))"`
	BlockIndex    uint32                     `json:"blockIndex" swagger:"required,min(1)"`
	RequestIndex  uint16                     `json:"requestIndex" swagger:"required,min(1)"`
	GasBurnLog    []gas.BurnRecord           `json:"gasBurnLog" swagger:"required"`
}

func MapReceiptResponse

func MapReceiptResponse(receipt *isc.Receipt) *ReceiptResponse

type RegisteredChainIDItems

type RegisteredChainIDItems []string

ChainMetrics Echo Swagger does not support generics such as MetricItem[Foo] Creating separate types works instead. To not create a mapper for each type, the actual service remains using MetricItem[Foo] but this model here is presented to the docs. This can be removed if we change to swag/echo-swagger

type RentStructure

type RentStructure struct {
	// Defines the rent of a single virtual byte denoted in IOTA tokens.
	VByteCost uint32 `json:"vByteCost" swagger:"desc(The virtual byte cost),required,min(1)"`
	// Defines the factor to be used for data only fields.
	VBFactorData iotago.VByteCostFactor `json:"vByteFactorData" swagger:"desc(The virtual byte factor for data fields),required"`
	// defines the factor to be used for key/lookup generating fields.
	VBFactorKey iotago.VByteCostFactor `json:"vByteFactorKey" swagger:"desc(The virtual byte factor for key/lookup generating fields),required"`
}

RentStructure defines the parameters of rent cost calculations on objects which take node resources.

type RequestIDResponse

type RequestIDResponse struct {
	RequestID string `json:"requestId" swagger:"desc(The request ID of the given transaction ID. (Hex)),required"`
}

type RequestIDsResponse

type RequestIDsResponse struct {
	RequestIDs []string `json:"requestIds" swagger:"required"`
}

type RequestProcessedResponse

type RequestProcessedResponse struct {
	ChainID     string `json:"chainId" swagger:"required"`
	RequestID   string `json:"requestId" swagger:"required"`
	IsProcessed bool   `json:"isProcessed" swagger:"required"`
}

type StateResponse

type StateResponse struct {
	State string `json:"state" swagger:"desc(The state of the requested key (Hex-encoded)),required"`
}

type StateTransaction

type StateTransaction struct {
	StateIndex    uint32 `json:"stateIndex" swagger:"desc(The state index),required,min(1)"`
	TransactionID string `json:"txId" swagger:"desc(The transaction ID),required"`
}

func StateTransactionFromISCStateTransaction

func StateTransactionFromISCStateTransaction(transaction *metrics.StateTransaction) *StateTransaction

type Transaction

type Transaction struct {
	TransactionID string `json:"txId" swagger:"desc(The transaction ID),required"`
}

func TransactionFromIotaGoTransaction

func TransactionFromIotaGoTransaction(transaction *iotago.Transaction) *Transaction

func TransactionFromIotaGoTransactionID

func TransactionFromIotaGoTransactionID(txID *iotago.TransactionID) *Transaction

type TransactionIDMetricItem

type TransactionIDMetricItem MetricItem[*Transaction]

ChainMetrics Echo Swagger does not support generics such as MetricItem[Foo] Creating separate types works instead. To not create a mapper for each type, the actual service remains using MetricItem[Foo] but this model here is presented to the docs. This can be removed if we change to swag/echo-swagger

type TransactionMetricItem

type TransactionMetricItem MetricItem[*Transaction]

ChainMetrics Echo Swagger does not support generics such as MetricItem[Foo] Creating separate types works instead. To not create a mapper for each type, the actual service remains using MetricItem[Foo] but this model here is presented to the docs. This can be removed if we change to swag/echo-swagger

type TxInclusionStateMsg

type TxInclusionStateMsg struct {
	TransactionID string `json:"txId" swagger:"desc(The transaction ID),required"`
	State         string `json:"state" swagger:"desc(The inclusion state),required"`
}

func TxInclusionStateMsgFromISCTxInclusionStateMsg

func TxInclusionStateMsgFromISCTxInclusionStateMsg(inclusionState *metrics.TxInclusionStateMsg) *TxInclusionStateMsg

type TxInclusionStateMsgMetricItem

type TxInclusionStateMsgMetricItem MetricItem[*TxInclusionStateMsg]

ChainMetrics Echo Swagger does not support generics such as MetricItem[Foo] Creating separate types works instead. To not create a mapper for each type, the actual service remains using MetricItem[Foo] but this model here is presented to the docs. This can be removed if we change to swag/echo-swagger

type UTXOInputMetricItem

type UTXOInputMetricItem MetricItem[*OutputID]

ChainMetrics Echo Swagger does not support generics such as MetricItem[Foo] Creating separate types works instead. To not create a mapper for each type, the actual service remains using MetricItem[Foo] but this model here is presented to the docs. This can be removed if we change to swag/echo-swagger

type UpdateUserPasswordRequest

type UpdateUserPasswordRequest struct {
	Password string `json:"password" swagger:"required"`
}

type UpdateUserPermissionsRequest

type UpdateUserPermissionsRequest struct {
	Permissions []string `json:"permissions" swagger:"required"`
}

type User

type User struct {
	Username    string   `json:"username" swagger:"required"`
	Permissions []string `json:"permissions" swagger:"required"`
}

type VersionResponse

type VersionResponse struct {
	Version string `json:"version" swagger:"desc(The version of the node),required"`
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL