> ## Documentation Index
> Fetch the complete documentation index at: https://docs.cryptomate.me/llms.txt
> Use this file to discover all available pages before exploring further.

# Update account

> Update an existing treasury account.

Updates account details such as the alias. Requires an API key with access level 2 or higher.

## Path parameters

<ParamField path="accountId" type="string" required>
  The account ID to update.
</ParamField>

## Body

<ParamField body="alias" type="string" required>
  New friendly alias name for the account.
</ParamField>

## Response

<ResponseField name="id" type="string">
  Unique account identifier.
</ResponseField>

<ResponseField name="alias" type="string">
  Friendly alias name for the account.
</ResponseField>

<RequestExample>
  ```bash cURL theme={null}
  curl -X PUT "https://api.cryptomate.me/mpc/accounts/acc_6f1e2a30-4a3c-4b2e-9a1d-5e8c9b7a1f23" \
    -H "x-api-key: $CRYPTOMATE_API_KEY" \
    -H "Content-Type: application/json" \
    -d '{
      "alias": "Updated Account Name"
    }'
  ```
</RequestExample>

<ResponseExample>
  ```json 200 OK theme={null}
  {
    "id": "acc_6f1e2a30-4a3c-4b2e-9a1d-5e8c9b7a1f23",
    "alias": "Updated Account Name"
  }
  ```

  ```json 404 Not Found theme={null}
  {
    "code": "NOT_FOUND",
    "message": "Resource not found"
  }
  ```
</ResponseExample>
