Solana Accounts

Export Solana account

Changed on

Export an existing Solana account's private key. It is important to store the private key in a secure place after it's exported.

post/v2/solana/accounts/{address}/export

Request

  • Base URL
    https://api.cdp.coinbase.com/platform
  • Auth
    HTTP bearer

Path parameters

address, string required

The base58 encoded address of the Solana account.

Headers

X-Wallet-Auth, string required

A JWT signed using your Wallet Secret, encoded in base64. Refer to the Generate Wallet Token section of our Authentication docs for more details on how to generate your Wallet Token.

X-Idempotency-Key, string

An optional string request header for making requests safely retryable. When included, duplicate requests with the same key will return identical responses. Refer to our Idempotency docs for more information on using idempotency keys.

Request body

object required
exportEncryptionKey, string required

The base64-encoded, public part of the RSA key in DER format used to encrypt the account private key.

Example request

{
  "exportEncryptionKey": "U2FsdGVkX1+vupppZksvRf5X5YgHq4+da+Q4qf51+Q4="
}

Response

Successfully exported Solana account.

object required
encryptedPrivateKey, string required

The base64-encoded, encrypted private key of the Solana account which is a 32 byte raw private key. The private key is encrypted in transport using the exportEncryptionKey in the request.

Example response

{
  "encryptedPrivateKey": "U2FsdGVkX1+vupppZksvRf5X5YgHq4+da+Q4qf51+Q4="
}

Changes

    • warning

      added the new policy_not_applicable enum value to the errorType response property for the response status

    • warning

      added the new policy_not_applicable enum value to the errorType response property for the response status

    • warning

      added the new policy_not_applicable enum value to the errorType response property for the response status

    5 more changes in this revision