UNPKG

@okutrade/account-api

Version:

TypeScript client for OKU Account API using Connect-ES

115 lines (114 loc) 3.51 kB
import type { GenFile, GenMessage, GenService } from "@bufbuild/protobuf/codegenv1"; import type { Timestamp } from "@bufbuild/protobuf/wkt"; import type { Message } from "@bufbuild/protobuf"; /** * Describes the file gfxcafe/oku/account/v1/wallet.proto. */ export declare const file_gfxcafe_oku_account_v1_wallet: GenFile; /** * AddressHoldingsRequest is the request to get wallet holdings * * @generated from message gfxcafe.oku.account.v1.AddressHoldingsRequest */ export type AddressHoldingsRequest = Message<"gfxcafe.oku.account.v1.AddressHoldingsRequest"> & { /** * Ethereum address to get holdings for * * @generated from field: string address = 1; */ address: string; /** * Chain identifier (e.g., "1", "ethereum", "eip155:1") * * @generated from field: string chain = 2; */ chain: string; }; /** * Describes the message gfxcafe.oku.account.v1.AddressHoldingsRequest. * Use `create(AddressHoldingsRequestSchema)` to create a new message. */ export declare const AddressHoldingsRequestSchema: GenMessage<AddressHoldingsRequest>; /** * TokenBalance represents a token balance * * @generated from message gfxcafe.oku.account.v1.TokenBalance */ export type TokenBalance = Message<"gfxcafe.oku.account.v1.TokenBalance"> & { /** * Token contract address * * @generated from field: string token_address = 1; */ tokenAddress: string; /** * Balance amount as a string (to handle large numbers) * * @generated from field: string balance = 2; */ balance: string; /** * Token symbol (if available) * * @generated from field: string symbol = 3; */ symbol: string; /** * Token name (if available) * * @generated from field: string name = 4; */ name: string; /** * Token decimals * * @generated from field: int32 decimals = 5; */ decimals: number; }; /** * Describes the message gfxcafe.oku.account.v1.TokenBalance. * Use `create(TokenBalanceSchema)` to create a new message. */ export declare const TokenBalanceSchema: GenMessage<TokenBalance>; /** * AddressHoldingsResponse returns the wallet holdings * * @generated from message gfxcafe.oku.account.v1.AddressHoldingsResponse */ export type AddressHoldingsResponse = Message<"gfxcafe.oku.account.v1.AddressHoldingsResponse"> & { /** * List of token balances * * @generated from field: repeated gfxcafe.oku.account.v1.TokenBalance balances = 1; */ balances: TokenBalance[]; /** * When the balance data was last updated * * @generated from field: google.protobuf.Timestamp last_updated = 2; */ lastUpdated?: Timestamp; }; /** * Describes the message gfxcafe.oku.account.v1.AddressHoldingsResponse. * Use `create(AddressHoldingsResponseSchema)` to create a new message. */ export declare const AddressHoldingsResponseSchema: GenMessage<AddressHoldingsResponse>; /** * WalletService provides wallet-related functionality * * @generated from service gfxcafe.oku.account.v1.WalletService */ export declare const WalletService: GenService<{ /** * Get token holdings for a wallet address (/wallet/{address}/holdings) * * @generated from rpc gfxcafe.oku.account.v1.WalletService.AddressHoldings */ addressHoldings: { methodKind: "unary"; input: typeof AddressHoldingsRequestSchema; output: typeof AddressHoldingsResponseSchema; }; }>;