---
title: "Update exchange wallet credentials"
method: PATCH
path: "/v1/portfolios/{portfolioSlug}/wallets/{chainId}/{walletAddress}/credentials"
tags: ["Wallets"]
---

# Update exchange wallet credentials

`PATCH /v1/portfolios/{portfolioSlug}/wallets/{chainId}/{walletAddress}/credentials`

## Request

- Base URL: `https://api.tokenbooks.io` (the document declares no server; this is the origin it was published from)
- URL: `https://api.tokenbooks.io/v1/portfolios/{portfolioSlug}/wallets/{chainId}/{walletAddress}/credentials`
- Auth: API key in header `x-api-key`

Updates only the supplied credential fields for an existing exchange wallet in the selected portfolio. Provide at least one non-null credential value; omitted fields remain unchanged, and a request containing only null values is rejected. Requires portfolio.wallets.update permission. OAuth token fields may be supplied only from an authorization flow controlled by the caller. Returns 204 with an empty body.

## Path parameters

- `chainId` string, required
- `walletAddress` string, required
- `portfolioSlug` string, required

## Request body

- object
  - `apiKey` string, nullable: API key or RPC URL
  - `secret` string, nullable: API secret or explorer URL
  - `uid` string, nullable: Optional exchange uid
  - `login` string, nullable: Optional exchange login
  - `password` string, nullable: Optional exchange password
  - `privateKey` string, nullable: Integration authentication private key. Never provide a wallet signing or spending key.
  - `walletAddress` string, nullable: Optional credential wallet address
  - `accountId` string, nullable: Optional exchange subaccount identifier
  - `token` string, nullable: OAuth or bearer token. API-key callers may provide this when creating or updating a wallet only from an authorization flow they control.
  - `refreshToken` string, nullable: OAuth refresh token. API-key callers may provide this when creating or updating a wallet only from an authorization flow they control.
  - `tokenExpiresAt` string, date-time, nullable: OAuth token expiry timestamp. API-key callers may provide this when creating or updating a wallet only from an authorization flow they control.

## Response `204`

Wallet credentials updated.

---

[API](https://skmtc.dev/tokenbooks/apis/tokenbooks-public-api.md) · [All operations](https://skmtc.dev/tokenbooks/apis/tokenbooks-public-api/llms.txt) · [OpenAPI document](https://skmtc.dev/tokenbooks/apis/tokenbooks-public-api/revisions/180622e6255e?raw)
