Skip to main content
Package: com.coinbase.cdp.resources.solanaaccounts

Method Details

listSolanaAccounts

Overload 1
Lists the Solana accounts belonging to the developer. The response is paginated, and by default, returns 20 accounts per page. If a name is provided, the response will contain only the account with that name. Returns: CdpClientHttpResponse<ListSolanaAccountsResponse> Overload 2
Lists the Solana accounts belonging to the developer. The response is paginated, and by default, returns 20 accounts per page. If a name is provided, the response will contain only the account with that name. Parameters: request - ListSolanaAccountsRequest Returns: CdpClientHttpResponse<ListSolanaAccountsResponse> Overload 3
Lists the Solana accounts belonging to the developer. The response is paginated, and by default, returns 20 accounts per page. If a name is provided, the response will contain only the account with that name. Parameters: requestOptions - RequestOptions Returns: CdpClientHttpResponse<ListSolanaAccountsResponse> Overload 4
Lists the Solana accounts belonging to the developer. The response is paginated, and by default, returns 20 accounts per page. If a name is provided, the response will contain only the account with that name. Parameters: request - ListSolanaAccountsRequest requestOptions - RequestOptions Returns: CdpClientHttpResponse<ListSolanaAccountsResponse>

createSolanaAccount

Overload 1
Creates a new Solana account. Returns: CdpClientHttpResponse<SolanaAccount> Overload 2
Creates a new Solana account. Parameters: request - CreateSolanaAccountRequest Returns: CdpClientHttpResponse<SolanaAccount> Overload 3
Creates a new Solana account. Parameters: requestOptions - RequestOptions Returns: CdpClientHttpResponse<SolanaAccount> Overload 4
Creates a new Solana account. Parameters: request - CreateSolanaAccountRequest requestOptions - RequestOptions Returns: CdpClientHttpResponse<SolanaAccount>

getSolanaAccount

Overload 1
Gets a Solana account by its address. Parameters: address - String Returns: CdpClientHttpResponse<SolanaAccount> Overload 2
Gets a Solana account by its address. Parameters: address - String request - GetSolanaAccountRequest Returns: CdpClientHttpResponse<SolanaAccount> Overload 3
Gets a Solana account by its address. Parameters: address - String requestOptions - RequestOptions Returns: CdpClientHttpResponse<SolanaAccount> Overload 4
Gets a Solana account by its address. Parameters: address - String request - GetSolanaAccountRequest requestOptions - RequestOptions Returns: CdpClientHttpResponse<SolanaAccount>

updateSolanaAccount

Overload 1
Updates an existing Solana account. Use this to update the account’s name or account-level policy. Parameters: address - String Returns: CdpClientHttpResponse<SolanaAccount> Overload 2
Updates an existing Solana account. Use this to update the account’s name or account-level policy. Parameters: address - String requestOptions - RequestOptions Returns: CdpClientHttpResponse<SolanaAccount> Overload 3
Updates an existing Solana account. Use this to update the account’s name or account-level policy. Parameters: address - String request - UpdateSolanaAccountRequest Returns: CdpClientHttpResponse<SolanaAccount> Overload 4
Updates an existing Solana account. Use this to update the account’s name or account-level policy. Parameters: address - String request - UpdateSolanaAccountRequest requestOptions - RequestOptions Returns: CdpClientHttpResponse<SolanaAccount>

getSolanaAccountByName

Overload 1
Gets a Solana account by its name. Parameters: name - String Returns: CdpClientHttpResponse<SolanaAccount> Overload 2
Gets a Solana account by its name. Parameters: name - String request - GetSolanaAccountByNameRequest Returns: CdpClientHttpResponse<SolanaAccount> Overload 3
Gets a Solana account by its name. Parameters: name - String requestOptions - RequestOptions Returns: CdpClientHttpResponse<SolanaAccount> Overload 4
Gets a Solana account by its name. Parameters: name - String request - GetSolanaAccountByNameRequest requestOptions - RequestOptions Returns: CdpClientHttpResponse<SolanaAccount>

importSolanaAccount

Overload 1
Import an existing Solana account into the developer’s CDP Project. This API should be called from the CDP SDK to ensure that the associated private key is properly encrypted. Parameters: request - ImportSolanaAccountRequest Returns: CdpClientHttpResponse<SolanaAccount> Overload 2
Import an existing Solana account into the developer’s CDP Project. This API should be called from the CDP SDK to ensure that the associated private key is properly encrypted. Parameters: request - ImportSolanaAccountRequest requestOptions - RequestOptions Returns: CdpClientHttpResponse<SolanaAccount>

exportSolanaAccount

Overload 1
Export an existing Solana account’s private key. It is important to store the private key in a secure place after it’s exported. Parameters: address - String request - ExportSolanaAccountRequest Returns: CdpClientHttpResponse<ExportSolanaAccountResponse> Overload 2
Export an existing Solana account’s private key. It is important to store the private key in a secure place after it’s exported. Parameters: address - String request - ExportSolanaAccountRequest requestOptions - RequestOptions Returns: CdpClientHttpResponse<ExportSolanaAccountResponse>

exportSolanaAccountByName

Overload 1
Export an existing Solana account’s private key by its name. It is important to store the private key in a secure place after it’s exported. Parameters: name - String request - ExportSolanaAccountByNameRequest Returns: CdpClientHttpResponse<ExportSolanaAccountByNameResponse> Overload 2
Export an existing Solana account’s private key by its name. It is important to store the private key in a secure place after it’s exported. Parameters: name - String request - ExportSolanaAccountByNameRequest requestOptions - RequestOptions Returns: CdpClientHttpResponse<ExportSolanaAccountByNameResponse>

signSolanaTransaction

Overload 1
Signs a transaction with the given Solana account. The unsigned transaction should be serialized into a byte array and then encoded as base64. Transaction types The following transaction types are supported: Legacy transactions Versioned transactions The developer is responsible for ensuring that the unsigned transaction is valid, as the API will not validate the transaction. Parameters: address - String request - SignSolanaTransactionRequest Returns: CdpClientHttpResponse<SignSolanaTransactionResponse> Overload 2
Signs a transaction with the given Solana account. The unsigned transaction should be serialized into a byte array and then encoded as base64. Transaction types The following transaction types are supported: Legacy transactions Versioned transactions The developer is responsible for ensuring that the unsigned transaction is valid, as the API will not validate the transaction. Parameters: address - String request - SignSolanaTransactionRequest requestOptions - RequestOptions Returns: CdpClientHttpResponse<SignSolanaTransactionResponse>

signSolanaMessage

Overload 1
Signs an arbitrary message with the given Solana account. WARNING: Never sign a message that you didn’t generate, as it can be an arbitrary transaction. For example, it might send all of your funds to an attacker. Parameters: address - String request - SignSolanaMessageRequest Returns: CdpClientHttpResponse<SignSolanaMessageResponse> Overload 2
Signs an arbitrary message with the given Solana account. WARNING: Never sign a message that you didn’t generate, as it can be an arbitrary transaction. For example, it might send all of your funds to an attacker. Parameters: address - String request - SignSolanaMessageRequest requestOptions - RequestOptions Returns: CdpClientHttpResponse<SignSolanaMessageResponse>

sendSolanaTransaction

Overload 1
Signs and sends a single Solana transaction using multiple Solana accounts. The transaction may contain several instructions, each of which may require signatures from different account keys. The transaction should be serialized into a byte array and base64 encoded. The API handles recent blockhash management and fee estimation, leaving the developer to provide only the minimal set of fields necessary to send the transaction. Transaction types The following transaction types are supported: Legacy transactions Versioned transactions Instruction Batching To batch multiple operations, include multiple instructions within a single transaction. All instructions within a transaction are executed atomically - if any instruction fails, the entire transaction fails and is rolled back. Network Support The following Solana networks are supported: solana - Solana Mainnet solana-devnet - Solana Devnet The developer is responsible for ensuring that the unsigned transaction is valid, as the API will not validate the transaction. Parameters: request - SendSolanaTransactionRequest Returns: CdpClientHttpResponse<SendSolanaTransactionResponse> Overload 2
Signs and sends a single Solana transaction using multiple Solana accounts. The transaction may contain several instructions, each of which may require signatures from different account keys. The transaction should be serialized into a byte array and base64 encoded. The API handles recent blockhash management and fee estimation, leaving the developer to provide only the minimal set of fields necessary to send the transaction. Transaction types The following transaction types are supported: Legacy transactions Versioned transactions Instruction Batching To batch multiple operations, include multiple instructions within a single transaction. All instructions within a transaction are executed atomically - if any instruction fails, the entire transaction fails and is rolled back. Network Support The following Solana networks are supported: solana - Solana Mainnet solana-devnet - Solana Devnet The developer is responsible for ensuring that the unsigned transaction is valid, as the API will not validate the transaction. Parameters: request - SendSolanaTransactionRequest requestOptions - RequestOptions Returns: CdpClientHttpResponse<SendSolanaTransactionResponse>