Documentation
¶
Index ¶
- Variables
- type ChannelsRequest
- type ChannelsResponse
- type CurrenciesRequest
- type CurrenciesResponse
- type InfoRequest
- type InfoResponse
- type LinesRequest
- type LinesResponse
- type NFTsRequest
- type NFTsResponse
- type NoRippleCheckRequest
- type NoRippleCheckResponse
- type ObjectType
- type ObjectsRequest
- type ObjectsResponse
- type OffersRequest
- type OffersResponse
- type Transaction
- type TransactionsRequest
- type TransactionsResponse
Constants ¶
This section is empty.
Variables ¶
var (
ErrNoAccountID = errors.New("no account ID specified")
)
Functions ¶
This section is empty.
Types ¶
type ChannelsRequest ¶
type ChannelsRequest struct { common.BaseRequest Account types.Address `json:"account"` DestinationAccount types.Address `json:"destination_account,omitempty"` LedgerIndex common.LedgerSpecifier `json:"ledger_index,omitempty"` LedgerHash common.LedgerHash `json:"ledger_hash,omitempty"` Limit int `json:"limit,omitempty"` Marker any `json:"marker,omitempty"` }
- The account_channels method returns information about an account's Payment
Channels. This includes only channels where the specified account is the channel's source, not the destination. (A channel's "source" and "owner" are the same.) All information retrieved is relative to a particular version of the ledger.
func (*ChannelsRequest) APIVersion ¶ added in v0.1.3
func (*ChannelsRequest) APIVersion() int
func (*ChannelsRequest) Method ¶
func (*ChannelsRequest) Method() string
Method returns the method name for the ChannelsRequest.
func (*ChannelsRequest) Validate ¶
func (r *ChannelsRequest) Validate() error
Validate method to be added to each request struct
type ChannelsResponse ¶
type ChannelsResponse struct { Account types.Address `json:"account"` Channels []accounttypes.ChannelResult `json:"channels"` LedgerIndex common.LedgerIndex `json:"ledger_index,omitempty"` LedgerHash common.LedgerHash `json:"ledger_hash,omitempty"` Validated bool `json:"validated,omitempty"` Limit int `json:"limit,omitempty"` Marker any `json:"marker,omitempty"` }
The expected response from the account_channels method.
type CurrenciesRequest ¶
type CurrenciesRequest struct { common.BaseRequest Account types.Address `json:"account"` LedgerHash common.LedgerHash `json:"ledger_hash,omitempty"` LedgerIndex common.LedgerSpecifier `json:"ledger_index,omitempty"` Strict bool `json:"strict,omitempty"` }
The `account_currencies` command retrieves a list of currencies that an account can send or receive, based on its trust lines.
func (*CurrenciesRequest) APIVersion ¶ added in v0.1.3
func (*CurrenciesRequest) APIVersion() int
func (*CurrenciesRequest) Method ¶
func (*CurrenciesRequest) Method() string
func (*CurrenciesRequest) Validate ¶
func (*CurrenciesRequest) Validate() error
TODO: Implement (V2)
type CurrenciesResponse ¶
type CurrenciesResponse struct { LedgerHash common.LedgerHash `json:"ledger_hash,omitempty"` LedgerIndex common.LedgerIndex `json:"ledger_index"` ReceiveCurrencies []string `json:"receive_currencies"` SendCurrencies []string `json:"send_currencies"` Validated bool `json:"validated"` }
The expected response from the account_currencies method.
type InfoRequest ¶
type InfoRequest struct { common.BaseRequest Account types.Address `json:"account"` LedgerIndex common.LedgerSpecifier `json:"ledger_index,omitempty"` LedgerHash common.LedgerHash `json:"ledger_hash,omitempty"` Queue bool `json:"queue,omitempty"` SignerLists bool `json:"signer_lists,omitempty"` Strict bool `json:"strict,omitempty"` }
The `account_info` command retrieves information about an account, its activity, and its XRP balance. All information retrieved is relative to a particular version of the ledger.
func (*InfoRequest) APIVersion ¶ added in v0.1.3
func (*InfoRequest) APIVersion() int
func (*InfoRequest) Method ¶
func (*InfoRequest) Method() string
type InfoResponse ¶
type InfoResponse struct { AccountData ledger.AccountRoot `json:"account_data"` SignerLists []ledger.SignerList `json:"signer_lists,omitempty"` LedgerCurrentIndex common.LedgerIndex `json:"ledger_current_index,omitempty"` LedgerIndex common.LedgerIndex `json:"ledger_index,omitempty"` QueueData accounttypes.QueueData `json:"queue_data,omitempty"` Validated bool `json:"validated"` }
The expected response from the account_info method.
type LinesRequest ¶
type LinesRequest struct { common.BaseRequest Account types.Address `json:"account"` LedgerHash common.LedgerHash `json:"ledger_hash,omitempty"` LedgerIndex common.LedgerSpecifier `json:"ledger_index,omitempty"` Peer types.Address `json:"peer,omitempty"` Limit int `json:"limit,omitempty"` Marker any `json:"marker,omitempty"` }
The account_lines method returns information about an account's trust lines, including balances in all non-XRP currencies and assets. All information retrieved is relative to a particular version of the ledger.
func (*LinesRequest) APIVersion ¶ added in v0.1.3
func (*LinesRequest) APIVersion() int
func (*LinesRequest) Method ¶
func (*LinesRequest) Method() string
type LinesResponse ¶
type LinesResponse struct { Account types.Address `json:"account"` Lines []accounttypes.TrustLine `json:"lines"` LedgerCurrentIndex common.LedgerIndex `json:"ledger_current_index,omitempty"` LedgerIndex common.LedgerIndex `json:"ledger_index,omitempty"` LedgerHash common.LedgerHash `json:"ledger_hash,omitempty"` Marker any `json:"marker,omitempty"` }
The expected response from the account_lines method.
type NFTsRequest ¶
type NFTsRequest struct { common.BaseRequest Account types.Address `json:"account"` LedgerIndex common.LedgerSpecifier `json:"ledger_index,omitempty"` LedgerHash common.LedgerHash `json:"ledger_hash,omitempty"` Limit int `json:"limit,omitempty"` Marker any `json:"marker,omitempty"` }
The `account_nfts` method retrieves all of the NFTs currently owned by the specified account.
func (*NFTsRequest) APIVersion ¶ added in v0.1.3
func (*NFTsRequest) APIVersion() int
func (*NFTsRequest) Method ¶
func (*NFTsRequest) Method() string
type NFTsResponse ¶
type NFTsResponse struct { Account types.Address `json:"account"` AccountNFTs []accounttypes.NFT `json:"account_nfts"` LedgerIndex common.LedgerIndex `json:"ledger_index,omitempty"` LedgerHash common.LedgerHash `json:"ledger_hash,omitempty"` LedgerCurrentIndex common.LedgerIndex `json:"ledger_current_index,omitempty"` Validated bool `json:"validated"` Marker any `json:"marker,omitempty"` Limit int `json:"limit,omitempty"` }
The expected response from the account_nfts method.
type NoRippleCheckRequest ¶ added in v0.1.3
type NoRippleCheckRequest struct { common.BaseRequest Account types.Address `json:"account"` Role string `json:"role"` Transactions bool `json:"transactions,omitempty"` Limit int `json:"limit,omitempty"` LedgerHash common.LedgerHash `json:"ledger_hash,omitempty"` LedgerIndex common.LedgerSpecifier `json:"ledger_index,omitempty"` }
The `noripple_check` command provides a quick way to check the status of the default ripple field for an account and the No Ripple flag of its trust lines, compared with the recommended settings. Expects a response in the form of an NoRippleCheckResponse.
func (*NoRippleCheckRequest) APIVersion ¶ added in v0.1.3
func (*NoRippleCheckRequest) APIVersion() int
func (*NoRippleCheckRequest) Method ¶ added in v0.1.3
func (*NoRippleCheckRequest) Method() string
func (*NoRippleCheckRequest) Validate ¶ added in v0.1.3
func (*NoRippleCheckRequest) Validate() error
type NoRippleCheckResponse ¶ added in v0.1.3
type NoRippleCheckResponse struct { LedgerCurrentIndex common.LedgerIndex `json:"ledger_current_index"` Problems []string `json:"problems"` Transactions []transaction.FlatTransaction `json:"transactions"` }
Response expected by a NoRippleCheckRequest
type ObjectType ¶
type ObjectType string
const ( CheckObject ObjectType = "check" DepositPreauthObject ObjectType = "deposit_preauth" EscrowObject ObjectType = "escrow" NFTOfferObject ObjectType = "nft_offer" OfferObject ObjectType = "offer" PaymentChannelObject ObjectType = "payment_channel" SignerListObject ObjectType = "signer_list" StateObject ObjectType = "state" TicketObject ObjectType = "ticket" )
type ObjectsRequest ¶
type ObjectsRequest struct { common.BaseRequest Account types.Address `json:"account"` Type ObjectType `json:"type,omitempty"` DeletionBlockersOnly bool `json:"deletion_blockers_only,omitempty"` LedgerHash common.LedgerHash `json:"ledger_hash,omitempty"` LedgerIndex common.LedgerSpecifier `json:"ledger_index,omitempty"` Limit int `json:"limit,omitempty"` Marker any `json:"marker,omitempty"` }
The account_objects command returns the raw ledger format for all objects owned by an account. For a higher-level view of an account's trust lines and balances, see the account_lines method instead.
func (*ObjectsRequest) APIVersion ¶ added in v0.1.3
func (*ObjectsRequest) APIVersion() int
func (*ObjectsRequest) Method ¶
func (*ObjectsRequest) Method() string
type ObjectsResponse ¶
type ObjectsResponse struct { Account types.Address `json:"account"` AccountObjects []ledger.FlatLedgerObject `json:"account_objects"` LedgerHash common.LedgerHash `json:"ledger_hash,omitempty"` LedgerIndex common.LedgerIndex `json:"ledger_index,omitempty"` LedgerCurrentIndex common.LedgerIndex `json:"ledger_current_index,omitempty"` Limit int `json:"limit,omitempty"` Marker any `json:"marker,omitempty"` Validated bool `json:"validated,omitempty"` }
The expected response from the account_objects method.
type OffersRequest ¶
type OffersRequest struct { common.BaseRequest Account types.Address `json:"account"` LedgerHash common.LedgerHash `json:"ledger_hash,omitempty"` LedgerIndex common.LedgerSpecifier `json:"ledger_index,omitempty"` Limit int `json:"limit,omitempty"` Marker any `json:"marker,omitempty"` Strict bool `json:"strict,omitempty"` }
The account_offers method retrieves a list of offers made by a given account that are outstanding as of a particular ledger version.
func (*OffersRequest) APIVersion ¶ added in v0.1.3
func (*OffersRequest) APIVersion() int
func (*OffersRequest) Method ¶
func (*OffersRequest) Method() string
type OffersResponse ¶
type OffersResponse struct { Account types.Address `json:"account"` Offers []accounttypes.OfferResult `json:"offers"` LedgerCurrentIndex common.LedgerIndex `json:"ledger_current_index,omitempty"` LedgerIndex common.LedgerIndex `json:"ledger_index,omitempty"` LedgerHash common.LedgerHash `json:"ledger_hash,omitempty"` Marker any `json:"marker,omitempty"` }
type Transaction ¶
type Transaction struct { LedgerIndex uint64 `json:"ledger_index"` Meta transaction.TxObjMeta `json:"meta"` Tx transaction.FlatTransaction `json:"tx"` TxBlob string `json:"tx_blob"` Validated bool `json:"validated"` }
type TransactionsRequest ¶
type TransactionsRequest struct { common.BaseRequest Account types.Address `json:"account"` LedgerIndexMin int `json:"ledger_index_min,omitempty"` LedgerIndexMax int `json:"ledger_index_max,omitempty"` LedgerHash common.LedgerHash `json:"ledger_hash,omitempty"` LedgerIndex common.LedgerSpecifier `json:"ledger_index,omitempty"` Binary bool `json:"binary,omitempty"` Forward bool `json:"forward,omitempty"` Limit int `json:"limit,omitempty"` Marker any `json:"marker,omitempty"` }
The account_tx method retrieves a list of transactions that involved the specified account.
func (*TransactionsRequest) APIVersion ¶ added in v0.1.3
func (*TransactionsRequest) APIVersion() int
func (*TransactionsRequest) Method ¶
func (*TransactionsRequest) Method() string
func (*TransactionsRequest) Validate ¶
func (*TransactionsRequest) Validate() error
TODO: Implement (V2)
type TransactionsResponse ¶
type TransactionsResponse struct { Account types.Address `json:"account"` LedgerIndexMin common.LedgerIndex `json:"ledger_index_min"` LedgerIndexMax common.LedgerIndex `json:"ledger_index_max"` Limit int `json:"limit"` Marker any `json:"marker,omitempty"` Transactions []Transaction `json:"transactions"` Validated bool `json:"validated"` }
The expected response from the account_tx method.