common

package
v1.0.0 Latest Latest
Warning

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

Go to latest
Published: Sep 16, 2026 License: MIT Imports: 2 Imported by: 0

Documentation

Overview

Package common provides primitives to interact with the openapi HTTP API.

Code generated by github.com/oapi-codegen/oapi-codegen/v2 version v2.8.0 DO NOT EDIT.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ContractId

type ContractId = string

ContractId The unique identifier of a contract.

Example: 00929f6a675c128bb54bef77a8cad8d330badd4330cf71f6a19b596b01f4b66b2dca121220cd655ce27fae64bdf6a203fcd987727de81c3762e46b1882ce2c2fbf0a72c64f

type DisclosedContract

type DisclosedContract struct {
	// ContractId The unique identifier of a contract.
	//
	// Example: 00929f6a675c128bb54bef77a8cad8d330badd4330cf71f6a19b596b01f4b66b2dca121220cd655ce27fae64bdf6a203fcd987727de81c3762e46b1882ce2c2fbf0a72c64f
	ContractId       ContractId `json:"contractId"`
	CreatedEventBlob string     `json:"createdEventBlob"`

	// SynchronizerId The synchronizer to which the contract is currently assigned.
	//
	// Example: global-domain::1220b1431ef217342db44d516bb9befde802be7d8899637d290895fa58880f19accc
	SynchronizerId string `json:"synchronizerId"`

	// TemplateId Example: 7df46ed05b4ba4ab85f827623d5ab51180520060f2f44ccf7f373606e2b4228f:CCIP.FeeQuoter:FeeQuoter
	TemplateId string `json:"templateId"`
}

DisclosedContract A disclosed contract, to be used by the caller during submission.

type EDSBaseUrl

type EDSBaseUrl = string

EDSBaseUrl The base URL of the operators EDS API.

Example: https://canton-eds.chain.link

type ErrorResponse

type ErrorResponse struct {
	Details *string `json:"details,omitempty"`
	Error   string  `json:"error"`
}

ErrorResponse defines model for ErrorResponse.

type HashedInstrumentId

type HashedInstrumentId = string

HashedInstrumentId The hashed identifier of an instrument, the keccak256 hash of the concatenated InstrumentId in the form of `id@admin`.

Example: 0xd661ca168d25fea40edc85adb17786a5ecc7e547a3674e60359bac4fb0803aeb

type InstanceAddress

type InstanceAddress = string

InstanceAddress The InstanceAddress of a contract, the keccak256 hash of the RawInstanceAddress.

Example: 0x9d24274102a5d2f57506d48dee1394e33f7cef9a9c0920ee714d6f4a216a21a9

type InstrumentId

type InstrumentId struct {
	// Admin The unique identifier of a party.
	//
	// Example: some-party::1220131b86f50178e6f7aabe62ef79e79b4964a526a1c557776409f448cbcd2406ce
	Admin PartyId `json:"admin"`
	Id    string  `json:"id"`
}

InstrumentId A globally unique identifier for instruments.

Example: {"admin":"linkOwner::1220131b86f50178e6f7aabe62ef79e79b4964a526a1c557776409f448cbcd2406ce","id":"LINK"}

type Message

type Message struct {
	// DestinationChainSelector The chain selector of the destination chain.
	DestinationChainSelector string `json:"destinationChainSelector"`

	// Executor The executor of the message, which determines the executor the message will be forwarded to on the source chain.
	// If not specified, or if type is "", the message will be executed with the default executor on the remote chain.
	// If type is "noExecutor", the message will not be executed automatically on the remote chain.
	// If type is "withAddress", the message will be executed with an executor at the specified address.
	//
	//
	// Example: {"type":"noExecutor"}
	Executor struct {
		// Address An address which can be either a RawInstanceAddress or an InstanceAddress.
		Address *RawOrHashedAddress `json:"address,omitempty"`
		Type    MessageExecutorType `json:"type"`
	} `json:"executor"`

	// FeeToken A globally unique identifier for instruments.
	//
	// Example: {"admin":"linkOwner::1220131b86f50178e6f7aabe62ef79e79b4964a526a1c557776409f448cbcd2406ce","id":"LINK"}
	FeeToken InstrumentId `json:"feeToken"`

	// GasLimit Gas limit for the callback on the destination chain.
	//
	// Example: 150000
	GasLimit int `json:"gasLimit"`

	// Payload The payload of the message, encoded as a hex string.
	//
	// Example: 0xdeadbeef
	Payload string `json:"payload"`

	// Receiver The receiver of the message on the remote chain, encoded as a hex string.
	//
	// Example: 0x78914f092ba8ee6e76aeb3e6cfbb5d52dd101e36
	Receiver string `json:"receiver"`

	// Sender The unique identifier of a party.
	//
	// Example: some-party::1220131b86f50178e6f7aabe62ef79e79b4964a526a1c557776409f448cbcd2406ce
	Sender PartyId `json:"sender"`

	// TokenTransfer A token transfer to be included in the message, set to null if the message does not include a token transfer.
	TokenTransfer *TokenTransfer `json:"tokenTransfer,omitempty"`
}

Message A message to be sent from Canton.

type MessageExecutorType

type MessageExecutorType string

MessageExecutorType defines model for Message.Executor.Type.

const (
	Empty       MessageExecutorType = ""
	NoExecutor  MessageExecutorType = "noExecutor"
	WithAddress MessageExecutorType = "withAddress"
)

Defines values for MessageExecutorType.

func (MessageExecutorType) Valid

func (e MessageExecutorType) Valid() bool

Valid indicates whether the value is a known member of the MessageExecutorType enum.

type N400

type N400 = ErrorResponse

N400 defines model for 400.

type N404

type N404 = ErrorResponse

N404 defines model for 404.

type N500

type N500 = ErrorResponse

N500 defines model for 500.

type PartyId

type PartyId = string

PartyId The unique identifier of a party.

Example: some-party::1220131b86f50178e6f7aabe62ef79e79b4964a526a1c557776409f448cbcd2406ce

type RawInstanceAddress

type RawInstanceAddress = string

RawInstanceAddress The raw InstanceAddress of a contract, in the form of "prefix@owner", where prefix is the InstanceId of the contract.

Example: some-contract-fgtlw@ccipOwner::1220131b86f50178e6f7aabe62ef79e79b4964a526a1c557776409f448cbcd2406ce

type RawOrHashedAddress

type RawOrHashedAddress struct {
	// contains filtered or unexported fields
}

RawOrHashedAddress An address which can be either a RawInstanceAddress or an InstanceAddress.

func (RawOrHashedAddress) AsInstanceAddress

func (t RawOrHashedAddress) AsInstanceAddress() (InstanceAddress, error)

AsInstanceAddress returns the union data inside the RawOrHashedAddress as a InstanceAddress

func (RawOrHashedAddress) AsRawInstanceAddress

func (t RawOrHashedAddress) AsRawInstanceAddress() (RawInstanceAddress, error)

AsRawInstanceAddress returns the union data inside the RawOrHashedAddress as a RawInstanceAddress

func (*RawOrHashedAddress) FromInstanceAddress

func (t *RawOrHashedAddress) FromInstanceAddress(v InstanceAddress) error

FromInstanceAddress overwrites any union data inside the RawOrHashedAddress as the provided InstanceAddress

func (*RawOrHashedAddress) FromRawInstanceAddress

func (t *RawOrHashedAddress) FromRawInstanceAddress(v RawInstanceAddress) error

FromRawInstanceAddress overwrites any union data inside the RawOrHashedAddress as the provided RawInstanceAddress

func (RawOrHashedAddress) MarshalJSON

func (t RawOrHashedAddress) MarshalJSON() ([]byte, error)

func (*RawOrHashedAddress) MergeInstanceAddress

func (t *RawOrHashedAddress) MergeInstanceAddress(v InstanceAddress) error

MergeInstanceAddress performs a merge with any union data inside the RawOrHashedAddress, using the provided InstanceAddress

func (*RawOrHashedAddress) MergeRawInstanceAddress

func (t *RawOrHashedAddress) MergeRawInstanceAddress(v RawInstanceAddress) error

MergeRawInstanceAddress performs a merge with any union data inside the RawOrHashedAddress, using the provided RawInstanceAddress

func (*RawOrHashedAddress) UnmarshalJSON

func (t *RawOrHashedAddress) UnmarshalJSON(b []byte) error

type RawOrHashedInstrumentId

type RawOrHashedInstrumentId struct {
	// contains filtered or unexported fields
}

RawOrHashedInstrumentId An instrument identifier which can be either a RawInstrumentId or a HashedInstrumentId.

func (RawOrHashedInstrumentId) AsHashedInstrumentId

func (t RawOrHashedInstrumentId) AsHashedInstrumentId() (HashedInstrumentId, error)

AsHashedInstrumentId returns the union data inside the RawOrHashedInstrumentId as a HashedInstrumentId

func (RawOrHashedInstrumentId) AsInstrumentId

func (t RawOrHashedInstrumentId) AsInstrumentId() (InstrumentId, error)

AsInstrumentId returns the union data inside the RawOrHashedInstrumentId as a InstrumentId

func (*RawOrHashedInstrumentId) FromHashedInstrumentId

func (t *RawOrHashedInstrumentId) FromHashedInstrumentId(v HashedInstrumentId) error

FromHashedInstrumentId overwrites any union data inside the RawOrHashedInstrumentId as the provided HashedInstrumentId

func (*RawOrHashedInstrumentId) FromInstrumentId

func (t *RawOrHashedInstrumentId) FromInstrumentId(v InstrumentId) error

FromInstrumentId overwrites any union data inside the RawOrHashedInstrumentId as the provided InstrumentId

func (RawOrHashedInstrumentId) MarshalJSON

func (t RawOrHashedInstrumentId) MarshalJSON() ([]byte, error)

func (*RawOrHashedInstrumentId) MergeHashedInstrumentId

func (t *RawOrHashedInstrumentId) MergeHashedInstrumentId(v HashedInstrumentId) error

MergeHashedInstrumentId performs a merge with any union data inside the RawOrHashedInstrumentId, using the provided HashedInstrumentId

func (*RawOrHashedInstrumentId) MergeInstrumentId

func (t *RawOrHashedInstrumentId) MergeInstrumentId(v InstrumentId) error

MergeInstrumentId performs a merge with any union data inside the RawOrHashedInstrumentId, using the provided InstrumentId

func (*RawOrHashedInstrumentId) UnmarshalJSON

func (t *RawOrHashedInstrumentId) UnmarshalJSON(b []byte) error

type TokenTransfer

type TokenTransfer struct {
	// Amount The decimal amount of the token to be transferred.
	//
	// Example: 77.77
	Amount             string        `json:"amount"`
	HoldingContractIds *[]ContractId `json:"holdingContractIds,omitempty"`

	// Token A globally unique identifier for instruments.
	//
	// Example: {"admin":"linkOwner::1220131b86f50178e6f7aabe62ef79e79b4964a526a1c557776409f448cbcd2406ce","id":"LINK"}
	Token InstrumentId `json:"token"`
}

TokenTransfer A token transfer to be included in the message, set to null if the message does not include a token transfer.

Jump to

Keyboard shortcuts

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