Skip to main content

Documentation Index

Fetch the complete documentation index at: https://docs.privy.io/llms.txt

Use this file to discover all available pages before exploring further.

Update an existing account by its unique account ID. Update the account’s display name and add new wallets to the account. When updating an account:
  • Update the display name for the account.
  • Add new wallets to the account, either by providing a wallets_configuration to create new wallets, or a list of wallet_ids to add existing wallets. Wallets cannot be removed from an account.
Update the wallets within an account directly to set owners, signers, policies, and more.
View the full API reference for updating an account.

Usage

To update an account via REST API, make a PATCH request to:
https://api.privy.io/v1/accounts/{account_id}

Path parameters

account_id
string
required
The unique ID of the account to update.

Body

display_name
string
An optional display name for the account.
Provide exactly one of the following (wallets_configuration or wallets_ids) to add wallets to the account:
wallets_configuration
object[]
New wallets to create and add to the account, each specified with a chain type and optional custody configuration. Maximum of five wallets total per account.Mutually exclusive with wallet_ids.Each item in the array has the following fields:
wallet_ids
string[]
required
IDs of existing wallets to add to the account. Must contain between one and five wallet IDs.Mutually exclusive with wallets_configuration.

Response

id
string
The unique ID of the account.
display_name
string | null
The updated display name for the account, or null if not set.
wallets
object[]
All wallets in the account, including any newly added wallets. Each wallet contains:
  • id (string): The wallet ID
  • chain_type ('ethereum' | 'solana'): The chain type of the wallet
  • address (string): The on-chain address of the wallet
  • custody (object | undefined): The custody configuration, if the wallet is custodial

Examples

Using wallets_configuration

Use wallets_configuration to create and add new wallets to the account.Request
curl --request PATCH https://api.privy.io/v1/accounts/<account-id> \
  -u "your-app-id:your-app-secret" \
  -H "privy-app-id: your-app-id" \
  -H "Content-Type: application/json" \
  -d '{
    "display_name": "Updated Account Name",
    "wallets_configuration": [
      {
        "chain_type": "solana"
      }
    ]
  }'
Response
{
  "id": "<account-id>",
  "display_name": "Updated Account Name",
  "wallets": [
    {
      "id": "<wallet-id>",
      "chain_type": "ethereum",
      "address": "0x4f3A1c8B2dE07f59Ca83b1eD6F42c9Ae5d03B7e"
    },
    {
      "id": "<wallet-id>",
      "chain_type": "ethereum",
      "address": "0x9bC2E4A0dF31856e7a4D9cB3F108e2Ac6b75d1E",
      "custody": {
        "provider": "bridge",
        "provider_user_id": "<insert-provider-user-id>"
      }
    },
    {
      "id": "<wallet-id>",
      "chain_type": "solana",
      "address": "7mXkPqR3nWvJhYzT5sLdAeG2cFbN9pUoViQwKtBxC4D"
    }
  ]
}

Using wallet_ids

Use wallet_ids to add existing wallets to the account.Request
curl --request PATCH https://api.privy.io/v1/accounts/<account-id> \
  -u "your-app-id:your-app-secret" \
  -H "privy-app-id: your-app-id" \
  -H "Content-Type: application/json" \
  -d '{
    "wallet_ids": [
      "<wallet-id-1>"
    ]
  }'
Response
{
  "id": "<account-id>",
  "display_name": "Updated Account Name",
  "wallets": [
    {
      "id": "<wallet-id>",
      "chain_type": "ethereum",
      "address": "0x4f3A1c8B2dE07f59Ca83b1eD6F42c9Ae5d03B7e"
    },
    {
      "id": "<wallet-id-1>",
      "chain_type": "solana",
      "address": "7mXkPqR3nWvJhYzT5sLdAeG2cFbN9pUoViQwKtBxC4D"
    }
  ]
}