account

package
v0.3.0 Latest Latest
Warning

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

Go to latest
Published: Dec 9, 2025 License: MIT Imports: 23 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	IsOcpAccountResponse_Result_name = map[int32]string{
		0: "OK",
		1: "NOT_FOUND",
		2: "UNLOCKED_TIMELOCK_ACCOUNT",
	}
	IsOcpAccountResponse_Result_value = map[string]int32{
		"OK":                        0,
		"NOT_FOUND":                 1,
		"UNLOCKED_TIMELOCK_ACCOUNT": 2,
	}
)

Enum value maps for IsOcpAccountResponse_Result.

View Source
var (
	GetTokenAccountInfosResponse_Result_name = map[int32]string{
		0: "OK",
		1: "NOT_FOUND",
	}
	GetTokenAccountInfosResponse_Result_value = map[string]int32{
		"OK":        0,
		"NOT_FOUND": 1,
	}
)

Enum value maps for GetTokenAccountInfosResponse_Result.

View Source
var (
	TokenAccountInfo_BalanceSource_name = map[int32]string{
		0: "BALANCE_SOURCE_UNKNOWN",
		1: "BALANCE_SOURCE_BLOCKCHAIN",
		2: "BALANCE_SOURCE_CACHE",
	}
	TokenAccountInfo_BalanceSource_value = map[string]int32{
		"BALANCE_SOURCE_UNKNOWN":    0,
		"BALANCE_SOURCE_BLOCKCHAIN": 1,
		"BALANCE_SOURCE_CACHE":      2,
	}
)

Enum value maps for TokenAccountInfo_BalanceSource.

View Source
var (
	TokenAccountInfo_ManagementState_name = map[int32]string{
		0: "MANAGEMENT_STATE_UNKNOWN",
		1: "MANAGEMENT_STATE_NONE",
		2: "MANAGEMENT_STATE_LOCKING",
		3: "MANAGEMENT_STATE_LOCKED",
		4: "MANAGEMENT_STATE_UNLOCKING",
		5: "MANAGEMENT_STATE_UNLOCKED",
		6: "MANAGEMENT_STATE_CLOSING",
		7: "MANAGEMENT_STATE_CLOSED",
	}
	TokenAccountInfo_ManagementState_value = map[string]int32{
		"MANAGEMENT_STATE_UNKNOWN":   0,
		"MANAGEMENT_STATE_NONE":      1,
		"MANAGEMENT_STATE_LOCKING":   2,
		"MANAGEMENT_STATE_LOCKED":    3,
		"MANAGEMENT_STATE_UNLOCKING": 4,
		"MANAGEMENT_STATE_UNLOCKED":  5,
		"MANAGEMENT_STATE_CLOSING":   6,
		"MANAGEMENT_STATE_CLOSED":    7,
	}
)

Enum value maps for TokenAccountInfo_ManagementState.

View Source
var (
	TokenAccountInfo_BlockchainState_name = map[int32]string{
		0: "BLOCKCHAIN_STATE_UNKNOWN",
		1: "BLOCKCHAIN_STATE_DOES_NOT_EXIST",
		2: "BLOCKCHAIN_STATE_EXISTS",
	}
	TokenAccountInfo_BlockchainState_value = map[string]int32{
		"BLOCKCHAIN_STATE_UNKNOWN":        0,
		"BLOCKCHAIN_STATE_DOES_NOT_EXIST": 1,
		"BLOCKCHAIN_STATE_EXISTS":         2,
	}
)

Enum value maps for TokenAccountInfo_BlockchainState.

View Source
var (
	TokenAccountInfo_ClaimState_name = map[int32]string{
		0: "CLAIM_STATE_UNKNOWN",
		1: "CLAIM_STATE_NOT_CLAIMED",
		2: "CLAIM_STATE_CLAIMED",
		3: "CLAIM_STATE_EXPIRED",
	}
	TokenAccountInfo_ClaimState_value = map[string]int32{
		"CLAIM_STATE_UNKNOWN":     0,
		"CLAIM_STATE_NOT_CLAIMED": 1,
		"CLAIM_STATE_CLAIMED":     2,
		"CLAIM_STATE_EXPIRED":     3,
	}
)

Enum value maps for TokenAccountInfo_ClaimState.

View Source
var Account_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "ocp.account.v1.Account",
	HandlerType: (*AccountServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "IsOcpAccount",
			Handler:    _Account_IsOcpAccount_Handler,
		},
		{
			MethodName: "GetTokenAccountInfos",
			Handler:    _Account_GetTokenAccountInfos_Handler,
		},
	},
	Streams:  []grpc.StreamDesc{},
	Metadata: "account/v1/account_service.proto",
}

Account_ServiceDesc is the grpc.ServiceDesc for Account service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)

View Source
var File_account_v1_account_service_proto protoreflect.FileDescriptor

Functions

func RegisterAccountServer

func RegisterAccountServer(s grpc.ServiceRegistrar, srv AccountServer)

Types

type AccountClient

type AccountClient interface {
	// IsOcpAccount returns whether an owner account is a OCP account. This hints
	// to the client whether the account can be logged in, used for making payments,
	// etc.
	IsOcpAccount(ctx context.Context, in *IsOcpAccountRequest, opts ...grpc.CallOption) (*IsOcpAccountResponse, error)
	// GetTokenAccountInfos returns token account metadata relevant to the OCP owner
	// account.
	GetTokenAccountInfos(ctx context.Context, in *GetTokenAccountInfosRequest, opts ...grpc.CallOption) (*GetTokenAccountInfosResponse, error)
}

AccountClient is the client API for Account service.

For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream.

func NewAccountClient

func NewAccountClient(cc grpc.ClientConnInterface) AccountClient

type AccountServer

type AccountServer interface {
	// IsOcpAccount returns whether an owner account is a OCP account. This hints
	// to the client whether the account can be logged in, used for making payments,
	// etc.
	IsOcpAccount(context.Context, *IsOcpAccountRequest) (*IsOcpAccountResponse, error)
	// GetTokenAccountInfos returns token account metadata relevant to the OCP owner
	// account.
	GetTokenAccountInfos(context.Context, *GetTokenAccountInfosRequest) (*GetTokenAccountInfosResponse, error)
	// contains filtered or unexported methods
}

AccountServer is the server API for Account service. All implementations must embed UnimplementedAccountServer for forward compatibility

type GetTokenAccountInfosRequest

type GetTokenAccountInfosRequest struct {

	// The owner account to fetch balances for, which can also be thought of as a
	// parent account for this RPC that links to one or more token accounts.
	Owner *v1.SolanaAccountId `protobuf:"bytes,1,opt,name=owner,proto3" json:"owner,omitempty"`
	// The signature is of serialize(GetTokenAccountInfosRequest) without signature
	// fields set using the private key of the owner account. This provides
	// an authentication mechanism to the RPC.
	Signature *v1.Signature `protobuf:"bytes,2,opt,name=signature,proto3" json:"signature,omitempty"`
	// A requesting owner account that is requesting the balance for owner. Additional
	// metadata that is considered private will be provided, if applicable. An example
	// use case includes a user owner account requesting account info for a gift card
	// owner account.
	RequestingOwner *v1.SolanaAccountId `protobuf:"bytes,3,opt,name=requesting_owner,json=requestingOwner,proto3" json:"requesting_owner,omitempty"`
	// The signature is of serialize(GetTokenAccountInfosRequest) without signature
	// fields set using the private key of the requesting_owner_signature account.
	// This provides an authentication mechanism to the RPC when requesting_owner is
	// present.
	//
	// This must be set when requesting_owner is present.
	RequestingOwnerSignature *v1.Signature `` /* 135-byte string literal not displayed */
	// Filter to apply to limit response sizes
	//
	// Types that are assignable to Filter:
	//
	//	*GetTokenAccountInfosRequest_FilterByTokenAddress
	//	*GetTokenAccountInfosRequest_FilterByAccountType
	//	*GetTokenAccountInfosRequest_FilterByMintAddress
	Filter isGetTokenAccountInfosRequest_Filter `protobuf_oneof:"Filter"`
	// contains filtered or unexported fields
}

func (*GetTokenAccountInfosRequest) Descriptor deprecated

func (*GetTokenAccountInfosRequest) Descriptor() ([]byte, []int)

Deprecated: Use GetTokenAccountInfosRequest.ProtoReflect.Descriptor instead.

func (*GetTokenAccountInfosRequest) GetFilter

func (m *GetTokenAccountInfosRequest) GetFilter() isGetTokenAccountInfosRequest_Filter

func (*GetTokenAccountInfosRequest) GetFilterByAccountType

func (x *GetTokenAccountInfosRequest) GetFilterByAccountType() v1.AccountType

func (*GetTokenAccountInfosRequest) GetFilterByMintAddress

func (x *GetTokenAccountInfosRequest) GetFilterByMintAddress() *v1.SolanaAccountId

func (*GetTokenAccountInfosRequest) GetFilterByTokenAddress

func (x *GetTokenAccountInfosRequest) GetFilterByTokenAddress() *v1.SolanaAccountId

func (*GetTokenAccountInfosRequest) GetOwner

func (*GetTokenAccountInfosRequest) GetRequestingOwner

func (x *GetTokenAccountInfosRequest) GetRequestingOwner() *v1.SolanaAccountId

func (*GetTokenAccountInfosRequest) GetRequestingOwnerSignature

func (x *GetTokenAccountInfosRequest) GetRequestingOwnerSignature() *v1.Signature

func (*GetTokenAccountInfosRequest) GetSignature

func (x *GetTokenAccountInfosRequest) GetSignature() *v1.Signature

func (*GetTokenAccountInfosRequest) ProtoMessage

func (*GetTokenAccountInfosRequest) ProtoMessage()

func (*GetTokenAccountInfosRequest) ProtoReflect

func (*GetTokenAccountInfosRequest) Reset

func (x *GetTokenAccountInfosRequest) Reset()

func (*GetTokenAccountInfosRequest) String

func (x *GetTokenAccountInfosRequest) String() string

func (*GetTokenAccountInfosRequest) Validate

func (m *GetTokenAccountInfosRequest) Validate() error

Validate checks the field values on GetTokenAccountInfosRequest with the rules defined in the proto definition for this message. If any rules are violated, an error is returned.

type GetTokenAccountInfosRequestValidationError

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

GetTokenAccountInfosRequestValidationError is the validation error returned by GetTokenAccountInfosRequest.Validate if the designated constraints aren't met.

func (GetTokenAccountInfosRequestValidationError) Cause

Cause function returns cause value.

func (GetTokenAccountInfosRequestValidationError) Error

Error satisfies the builtin error interface

func (GetTokenAccountInfosRequestValidationError) ErrorName

ErrorName returns error name.

func (GetTokenAccountInfosRequestValidationError) Field

Field function returns field value.

func (GetTokenAccountInfosRequestValidationError) Key

Key function returns key value.

func (GetTokenAccountInfosRequestValidationError) Reason

Reason function returns reason value.

type GetTokenAccountInfosRequest_FilterByAccountType

type GetTokenAccountInfosRequest_FilterByAccountType struct {
	FilterByAccountType v1.AccountType `protobuf:"varint,11,opt,name=filter_by_account_type,json=filterByAccountType,proto3,enum=ocp.common.v1.AccountType,oneof"`
}

type GetTokenAccountInfosRequest_FilterByMintAddress

type GetTokenAccountInfosRequest_FilterByMintAddress struct {
	FilterByMintAddress *v1.SolanaAccountId `protobuf:"bytes,12,opt,name=filter_by_mint_address,json=filterByMintAddress,proto3,oneof"`
}

type GetTokenAccountInfosRequest_FilterByTokenAddress

type GetTokenAccountInfosRequest_FilterByTokenAddress struct {
	FilterByTokenAddress *v1.SolanaAccountId `protobuf:"bytes,10,opt,name=filter_by_token_address,json=filterByTokenAddress,proto3,oneof"`
}

type GetTokenAccountInfosResponse

type GetTokenAccountInfosResponse struct {
	Result            GetTokenAccountInfosResponse_Result `protobuf:"varint,1,opt,name=result,proto3,enum=ocp.account.v1.GetTokenAccountInfosResponse_Result" json:"result,omitempty"`
	TokenAccountInfos map[string]*TokenAccountInfo        `` /* 202-byte string literal not displayed */
	// contains filtered or unexported fields
}

func (*GetTokenAccountInfosResponse) Descriptor deprecated

func (*GetTokenAccountInfosResponse) Descriptor() ([]byte, []int)

Deprecated: Use GetTokenAccountInfosResponse.ProtoReflect.Descriptor instead.

func (*GetTokenAccountInfosResponse) GetResult

func (*GetTokenAccountInfosResponse) GetTokenAccountInfos

func (x *GetTokenAccountInfosResponse) GetTokenAccountInfos() map[string]*TokenAccountInfo

func (*GetTokenAccountInfosResponse) ProtoMessage

func (*GetTokenAccountInfosResponse) ProtoMessage()

func (*GetTokenAccountInfosResponse) ProtoReflect

func (*GetTokenAccountInfosResponse) Reset

func (x *GetTokenAccountInfosResponse) Reset()

func (*GetTokenAccountInfosResponse) String

func (*GetTokenAccountInfosResponse) Validate

func (m *GetTokenAccountInfosResponse) Validate() error

Validate checks the field values on GetTokenAccountInfosResponse with the rules defined in the proto definition for this message. If any rules are violated, an error is returned.

type GetTokenAccountInfosResponseValidationError

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

GetTokenAccountInfosResponseValidationError is the validation error returned by GetTokenAccountInfosResponse.Validate if the designated constraints aren't met.

func (GetTokenAccountInfosResponseValidationError) Cause

Cause function returns cause value.

func (GetTokenAccountInfosResponseValidationError) Error

Error satisfies the builtin error interface

func (GetTokenAccountInfosResponseValidationError) ErrorName

ErrorName returns error name.

func (GetTokenAccountInfosResponseValidationError) Field

Field function returns field value.

func (GetTokenAccountInfosResponseValidationError) Key

Key function returns key value.

func (GetTokenAccountInfosResponseValidationError) Reason

Reason function returns reason value.

type GetTokenAccountInfosResponse_Result

type GetTokenAccountInfosResponse_Result int32
const (
	GetTokenAccountInfosResponse_OK        GetTokenAccountInfosResponse_Result = 0
	GetTokenAccountInfosResponse_NOT_FOUND GetTokenAccountInfosResponse_Result = 1
)

func (GetTokenAccountInfosResponse_Result) Descriptor

func (GetTokenAccountInfosResponse_Result) Enum

func (GetTokenAccountInfosResponse_Result) EnumDescriptor deprecated

func (GetTokenAccountInfosResponse_Result) EnumDescriptor() ([]byte, []int)

Deprecated: Use GetTokenAccountInfosResponse_Result.Descriptor instead.

func (GetTokenAccountInfosResponse_Result) Number

func (GetTokenAccountInfosResponse_Result) String

func (GetTokenAccountInfosResponse_Result) Type

type IsOcpAccountRequest added in v0.3.0

type IsOcpAccountRequest struct {

	// The owner account to check against.
	Owner *v1.SolanaAccountId `protobuf:"bytes,1,opt,name=owner,proto3" json:"owner,omitempty"`
	// The signature is of serialize(IsOcpAccountRequest) without this field set
	// using the private key of the owner account. This provides an authentication
	// mechanism to the RPC.
	Signature *v1.Signature `protobuf:"bytes,2,opt,name=signature,proto3" json:"signature,omitempty"`
	// contains filtered or unexported fields
}

func (*IsOcpAccountRequest) Descriptor deprecated added in v0.3.0

func (*IsOcpAccountRequest) Descriptor() ([]byte, []int)

Deprecated: Use IsOcpAccountRequest.ProtoReflect.Descriptor instead.

func (*IsOcpAccountRequest) GetOwner added in v0.3.0

func (x *IsOcpAccountRequest) GetOwner() *v1.SolanaAccountId

func (*IsOcpAccountRequest) GetSignature added in v0.3.0

func (x *IsOcpAccountRequest) GetSignature() *v1.Signature

func (*IsOcpAccountRequest) ProtoMessage added in v0.3.0

func (*IsOcpAccountRequest) ProtoMessage()

func (*IsOcpAccountRequest) ProtoReflect added in v0.3.0

func (x *IsOcpAccountRequest) ProtoReflect() protoreflect.Message

func (*IsOcpAccountRequest) Reset added in v0.3.0

func (x *IsOcpAccountRequest) Reset()

func (*IsOcpAccountRequest) String added in v0.3.0

func (x *IsOcpAccountRequest) String() string

func (*IsOcpAccountRequest) Validate added in v0.3.0

func (m *IsOcpAccountRequest) Validate() error

Validate checks the field values on IsOcpAccountRequest with the rules defined in the proto definition for this message. If any rules are violated, an error is returned.

type IsOcpAccountRequestValidationError added in v0.3.0

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

IsOcpAccountRequestValidationError is the validation error returned by IsOcpAccountRequest.Validate if the designated constraints aren't met.

func (IsOcpAccountRequestValidationError) Cause added in v0.3.0

Cause function returns cause value.

func (IsOcpAccountRequestValidationError) Error added in v0.3.0

Error satisfies the builtin error interface

func (IsOcpAccountRequestValidationError) ErrorName added in v0.3.0

ErrorName returns error name.

func (IsOcpAccountRequestValidationError) Field added in v0.3.0

Field function returns field value.

func (IsOcpAccountRequestValidationError) Key added in v0.3.0

Key function returns key value.

func (IsOcpAccountRequestValidationError) Reason added in v0.3.0

Reason function returns reason value.

type IsOcpAccountResponse added in v0.3.0

type IsOcpAccountResponse struct {
	Result IsOcpAccountResponse_Result `protobuf:"varint,1,opt,name=result,proto3,enum=ocp.account.v1.IsOcpAccountResponse_Result" json:"result,omitempty"`
	// contains filtered or unexported fields
}

func (*IsOcpAccountResponse) Descriptor deprecated added in v0.3.0

func (*IsOcpAccountResponse) Descriptor() ([]byte, []int)

Deprecated: Use IsOcpAccountResponse.ProtoReflect.Descriptor instead.

func (*IsOcpAccountResponse) GetResult added in v0.3.0

func (*IsOcpAccountResponse) ProtoMessage added in v0.3.0

func (*IsOcpAccountResponse) ProtoMessage()

func (*IsOcpAccountResponse) ProtoReflect added in v0.3.0

func (x *IsOcpAccountResponse) ProtoReflect() protoreflect.Message

func (*IsOcpAccountResponse) Reset added in v0.3.0

func (x *IsOcpAccountResponse) Reset()

func (*IsOcpAccountResponse) String added in v0.3.0

func (x *IsOcpAccountResponse) String() string

func (*IsOcpAccountResponse) Validate added in v0.3.0

func (m *IsOcpAccountResponse) Validate() error

Validate checks the field values on IsOcpAccountResponse with the rules defined in the proto definition for this message. If any rules are violated, an error is returned.

type IsOcpAccountResponseValidationError added in v0.3.0

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

IsOcpAccountResponseValidationError is the validation error returned by IsOcpAccountResponse.Validate if the designated constraints aren't met.

func (IsOcpAccountResponseValidationError) Cause added in v0.3.0

Cause function returns cause value.

func (IsOcpAccountResponseValidationError) Error added in v0.3.0

Error satisfies the builtin error interface

func (IsOcpAccountResponseValidationError) ErrorName added in v0.3.0

ErrorName returns error name.

func (IsOcpAccountResponseValidationError) Field added in v0.3.0

Field function returns field value.

func (IsOcpAccountResponseValidationError) Key added in v0.3.0

Key function returns key value.

func (IsOcpAccountResponseValidationError) Reason added in v0.3.0

Reason function returns reason value.

type IsOcpAccountResponse_Result added in v0.3.0

type IsOcpAccountResponse_Result int32
const (
	// The account is an OCP account.
	IsOcpAccountResponse_OK IsOcpAccountResponse_Result = 0
	// The account is not an OCP account.
	IsOcpAccountResponse_NOT_FOUND IsOcpAccountResponse_Result = 1
	// The account exists, but at least one timelock account is unlocked.
	IsOcpAccountResponse_UNLOCKED_TIMELOCK_ACCOUNT IsOcpAccountResponse_Result = 2
)

func (IsOcpAccountResponse_Result) Descriptor added in v0.3.0

func (IsOcpAccountResponse_Result) Enum added in v0.3.0

func (IsOcpAccountResponse_Result) EnumDescriptor deprecated added in v0.3.0

func (IsOcpAccountResponse_Result) EnumDescriptor() ([]byte, []int)

Deprecated: Use IsOcpAccountResponse_Result.Descriptor instead.

func (IsOcpAccountResponse_Result) Number added in v0.3.0

func (IsOcpAccountResponse_Result) String added in v0.3.0

func (IsOcpAccountResponse_Result) Type added in v0.3.0

type TokenAccountInfo

type TokenAccountInfo struct {

	// The token account's address
	Address *v1.SolanaAccountId `protobuf:"bytes,1,opt,name=address,proto3" json:"address,omitempty"`
	// The owner of the token account, which can also be thought of as a parent
	// account that links to one or more token accounts. This is provided when
	// available.
	Owner *v1.SolanaAccountId `protobuf:"bytes,2,opt,name=owner,proto3" json:"owner,omitempty"`
	// The token account's authority, which has access to moving funds for the
	// account. This can be the owner account under certain circumstances (eg.
	// ATA, primary account). This is provided when available.
	Authority *v1.SolanaAccountId `protobuf:"bytes,3,opt,name=authority,proto3" json:"authority,omitempty"`
	// The type of token account, which infers its intended use.
	AccountType v1.AccountType `` /* 126-byte string literal not displayed */
	// The account's derivation index for applicable account types. When this field
	// doesn't apply, a zero value is provided.
	Index uint64 `protobuf:"varint,5,opt,name=index,proto3" json:"index,omitempty"`
	// The source of truth for the balance calculation.
	BalanceSource TokenAccountInfo_BalanceSource `` /* 152-byte string literal not displayed */
	// The balance in quarks, as observed by the OCP. This may not reflect the value
	// on the blockchain and could be non-zero even if the account hasn't been created.
	// Use balance_source to determine how this value was calculated.
	Balance uint64 `protobuf:"varint,7,opt,name=balance,proto3" json:"balance,omitempty"`
	// The state of the account as it pertains to the OCP's ability to manage funds.
	ManagementState TokenAccountInfo_ManagementState `` /* 160-byte string literal not displayed */
	// The state of the account on the blockchain.
	BlockchainState TokenAccountInfo_BlockchainState `` /* 160-byte string literal not displayed */
	// Whether an account is claimed. This only applies to relevant account types
	// (eg. REMOTE_SEND_GIFT_CARD).
	ClaimState TokenAccountInfo_ClaimState `` /* 141-byte string literal not displayed */
	// For account types used as an intermediary for sending money between two
	// users (eg. REMOTE_SEND_GIFT_CARD), this represents the original exchange
	// data used to fund the account. Over time, this value will become stale:
	//  1. Exchange rates will fluctuate, so the total fiat amount will differ.
	//  2. External entities can deposit additional funds into the account, so
	//     the balance, in quarks, may be greater than the original quark value.
	//  3. The balance could have been received, so the total balance can show
	//     as zero.
	OriginalExchangeData *v11.ExchangeData `protobuf:"bytes,11,opt,name=original_exchange_data,json=originalExchangeData,proto3" json:"original_exchange_data,omitempty"`
	// The token account's mint
	Mint *v1.SolanaAccountId `protobuf:"bytes,12,opt,name=mint,proto3" json:"mint,omitempty"`
	// Time the account was created, if available. For OCP accounts, this is
	// the time of intent submission. Otherwise, for external accounts, it is
	// the time created on the blockchain.
	CreatedAt *timestamppb.Timestamp `protobuf:"bytes,13,opt,name=created_at,json=createdAt,proto3" json:"created_at,omitempty"`
	// For REMOTE_SEND_GIFT_CARD, if requesting_owner was provided, was
	// requesting_owner the issuer of the account.
	IsGiftCardIssuer bool `protobuf:"varint,14,opt,name=is_gift_card_issuer,json=isGiftCardIssuer,proto3" json:"is_gift_card_issuer,omitempty"`
	// contains filtered or unexported fields
}

func (*TokenAccountInfo) Descriptor deprecated

func (*TokenAccountInfo) Descriptor() ([]byte, []int)

Deprecated: Use TokenAccountInfo.ProtoReflect.Descriptor instead.

func (*TokenAccountInfo) GetAccountType

func (x *TokenAccountInfo) GetAccountType() v1.AccountType

func (*TokenAccountInfo) GetAddress

func (x *TokenAccountInfo) GetAddress() *v1.SolanaAccountId

func (*TokenAccountInfo) GetAuthority

func (x *TokenAccountInfo) GetAuthority() *v1.SolanaAccountId

func (*TokenAccountInfo) GetBalance

func (x *TokenAccountInfo) GetBalance() uint64

func (*TokenAccountInfo) GetBalanceSource

func (x *TokenAccountInfo) GetBalanceSource() TokenAccountInfo_BalanceSource

func (*TokenAccountInfo) GetBlockchainState

func (x *TokenAccountInfo) GetBlockchainState() TokenAccountInfo_BlockchainState

func (*TokenAccountInfo) GetClaimState

func (x *TokenAccountInfo) GetClaimState() TokenAccountInfo_ClaimState

func (*TokenAccountInfo) GetCreatedAt

func (x *TokenAccountInfo) GetCreatedAt() *timestamppb.Timestamp

func (*TokenAccountInfo) GetIndex

func (x *TokenAccountInfo) GetIndex() uint64

func (*TokenAccountInfo) GetIsGiftCardIssuer

func (x *TokenAccountInfo) GetIsGiftCardIssuer() bool

func (*TokenAccountInfo) GetManagementState

func (x *TokenAccountInfo) GetManagementState() TokenAccountInfo_ManagementState

func (*TokenAccountInfo) GetMint

func (x *TokenAccountInfo) GetMint() *v1.SolanaAccountId

func (*TokenAccountInfo) GetOriginalExchangeData

func (x *TokenAccountInfo) GetOriginalExchangeData() *v11.ExchangeData

func (*TokenAccountInfo) GetOwner

func (x *TokenAccountInfo) GetOwner() *v1.SolanaAccountId

func (*TokenAccountInfo) ProtoMessage

func (*TokenAccountInfo) ProtoMessage()

func (*TokenAccountInfo) ProtoReflect

func (x *TokenAccountInfo) ProtoReflect() protoreflect.Message

func (*TokenAccountInfo) Reset

func (x *TokenAccountInfo) Reset()

func (*TokenAccountInfo) String

func (x *TokenAccountInfo) String() string

func (*TokenAccountInfo) Validate

func (m *TokenAccountInfo) Validate() error

Validate checks the field values on TokenAccountInfo with the rules defined in the proto definition for this message. If any rules are violated, an error is returned.

type TokenAccountInfoValidationError

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

TokenAccountInfoValidationError is the validation error returned by TokenAccountInfo.Validate if the designated constraints aren't met.

func (TokenAccountInfoValidationError) Cause

Cause function returns cause value.

func (TokenAccountInfoValidationError) Error

Error satisfies the builtin error interface

func (TokenAccountInfoValidationError) ErrorName

ErrorName returns error name.

func (TokenAccountInfoValidationError) Field

Field function returns field value.

func (TokenAccountInfoValidationError) Key

Key function returns key value.

func (TokenAccountInfoValidationError) Reason

Reason function returns reason value.

type TokenAccountInfo_BalanceSource

type TokenAccountInfo_BalanceSource int32
const (
	// The account's balance could not be determined. This may be returned when
	// the data source is unstable and a reliable balance cannot be determined.
	TokenAccountInfo_BALANCE_SOURCE_UNKNOWN TokenAccountInfo_BalanceSource = 0
	// The account's balance was fetched directly from a finalized state on the
	// blockchain.
	TokenAccountInfo_BALANCE_SOURCE_BLOCKCHAIN TokenAccountInfo_BalanceSource = 1
	// The account's balance was calculated using cached values in OCP. Accuracy
	// is only guaranteed when management_state is LOCKED.
	TokenAccountInfo_BALANCE_SOURCE_CACHE TokenAccountInfo_BalanceSource = 2
)

func (TokenAccountInfo_BalanceSource) Descriptor

func (TokenAccountInfo_BalanceSource) Enum

func (TokenAccountInfo_BalanceSource) EnumDescriptor deprecated

func (TokenAccountInfo_BalanceSource) EnumDescriptor() ([]byte, []int)

Deprecated: Use TokenAccountInfo_BalanceSource.Descriptor instead.

func (TokenAccountInfo_BalanceSource) Number

func (TokenAccountInfo_BalanceSource) String

func (TokenAccountInfo_BalanceSource) Type

type TokenAccountInfo_BlockchainState

type TokenAccountInfo_BlockchainState int32
const (
	// The state of the account is unknown. This may be returned when the
	// data source is unstable and a reliable state cannot be determined.
	TokenAccountInfo_BLOCKCHAIN_STATE_UNKNOWN TokenAccountInfo_BlockchainState = 0
	// The account does not exist on the blockchain.
	TokenAccountInfo_BLOCKCHAIN_STATE_DOES_NOT_EXIST TokenAccountInfo_BlockchainState = 1
	// The account is created and exists on the blockchain.
	TokenAccountInfo_BLOCKCHAIN_STATE_EXISTS TokenAccountInfo_BlockchainState = 2
)

func (TokenAccountInfo_BlockchainState) Descriptor

func (TokenAccountInfo_BlockchainState) Enum

func (TokenAccountInfo_BlockchainState) EnumDescriptor deprecated

func (TokenAccountInfo_BlockchainState) EnumDescriptor() ([]byte, []int)

Deprecated: Use TokenAccountInfo_BlockchainState.Descriptor instead.

func (TokenAccountInfo_BlockchainState) Number

func (TokenAccountInfo_BlockchainState) String

func (TokenAccountInfo_BlockchainState) Type

type TokenAccountInfo_ClaimState

type TokenAccountInfo_ClaimState int32
const (
	// The account doesn't have a concept of being claimed, or the state
	// could not be fetched by server.
	TokenAccountInfo_CLAIM_STATE_UNKNOWN TokenAccountInfo_ClaimState = 0
	// The account has not yet been claimed.
	TokenAccountInfo_CLAIM_STATE_NOT_CLAIMED TokenAccountInfo_ClaimState = 1
	// The account is claimed. Attempting to claim it will fail.
	TokenAccountInfo_CLAIM_STATE_CLAIMED TokenAccountInfo_ClaimState = 2
	// The account hasn't been claimed, but is expired. Funds will move
	// back to the issuer. Attempting to claim it will fail.
	TokenAccountInfo_CLAIM_STATE_EXPIRED TokenAccountInfo_ClaimState = 3
)

func (TokenAccountInfo_ClaimState) Descriptor

func (TokenAccountInfo_ClaimState) Enum

func (TokenAccountInfo_ClaimState) EnumDescriptor deprecated

func (TokenAccountInfo_ClaimState) EnumDescriptor() ([]byte, []int)

Deprecated: Use TokenAccountInfo_ClaimState.Descriptor instead.

func (TokenAccountInfo_ClaimState) Number

func (TokenAccountInfo_ClaimState) String

func (TokenAccountInfo_ClaimState) Type

type TokenAccountInfo_ManagementState

type TokenAccountInfo_ManagementState int32
const (
	// The state of the account is unknown. This may be returned when the
	// data source is unstable and a reliable state cannot be determined.
	TokenAccountInfo_MANAGEMENT_STATE_UNKNOWN TokenAccountInfo_ManagementState = 0
	// OCP does not maintain a management state and won't move funds for this
	// account.
	TokenAccountInfo_MANAGEMENT_STATE_NONE TokenAccountInfo_ManagementState = 1
	// The account is in the process of transitioning to the LOCKED state.
	TokenAccountInfo_MANAGEMENT_STATE_LOCKING TokenAccountInfo_ManagementState = 2
	// The account's funds are locked and OCP has co-signing authority.
	TokenAccountInfo_MANAGEMENT_STATE_LOCKED TokenAccountInfo_ManagementState = 3
	// The account is in the process of transitioning to the UNLOCKED state.
	TokenAccountInfo_MANAGEMENT_STATE_UNLOCKING TokenAccountInfo_ManagementState = 4
	// The account's funds are unlocked and OCP no longer has co-signing
	// authority. The account must transition to the LOCKED state to have
	// management capabilities.
	TokenAccountInfo_MANAGEMENT_STATE_UNLOCKED TokenAccountInfo_ManagementState = 5
	// The account is in the process of transitioning to the CLOSED state.
	TokenAccountInfo_MANAGEMENT_STATE_CLOSING TokenAccountInfo_ManagementState = 6
	// The account has been closed and doesn't exist on the blockchain.
	// Subsequently, it also has a zero balance.
	TokenAccountInfo_MANAGEMENT_STATE_CLOSED TokenAccountInfo_ManagementState = 7
)

func (TokenAccountInfo_ManagementState) Descriptor

func (TokenAccountInfo_ManagementState) Enum

func (TokenAccountInfo_ManagementState) EnumDescriptor deprecated

func (TokenAccountInfo_ManagementState) EnumDescriptor() ([]byte, []int)

Deprecated: Use TokenAccountInfo_ManagementState.Descriptor instead.

func (TokenAccountInfo_ManagementState) Number

func (TokenAccountInfo_ManagementState) String

func (TokenAccountInfo_ManagementState) Type

type UnimplementedAccountServer

type UnimplementedAccountServer struct {
}

UnimplementedAccountServer must be embedded to have forward compatible implementations.

func (UnimplementedAccountServer) IsOcpAccount added in v0.3.0

type UnsafeAccountServer

type UnsafeAccountServer interface {
	// contains filtered or unexported methods
}

UnsafeAccountServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to AccountServer will result in compilation errors.

Jump to

Keyboard shortcuts

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