Edit Account

Edit Account

POST

/api/portal/v1/admin/editAccount

Description

Rename an account.

Authentication

This endpoint requires a Bearer token in the Authorization header.

  • Authorization: Bearer <token>. A valid Portal API session token or API token belonging to an administrator.

Request Body

The request body should be JSON-encoded.

  • id: The id of the account to edit.
  • name: The new name for the account.

Response Schema

On success, the endpoint returns the updated account record. See Get Account for the field descriptions.

Error Responses

  • 400 Bad Request: The request body is missing the id or name field.
  • 401 Unauthorized: The Authorization header is missing or the token is not valid.
  • 403 Forbidden: The authenticated user is not an administrator.
  • 404 Not Found: No account exists with the given id.
Example Request
POST https://<your-host>:9909/api/portal/v1/admin/editAccount
Authorization: Bearer <token>
Content-Type: application/json

{
    "id": 42,
    "name": "Zydro Marine Inc"
}

Example Response
Status Code: 200 OK
Response Body:
{
    "id": 42,
    "name": "Zydro Marine Inc",
    "planInstance": "oem",
    "metadata": {},
    "createdAt": 1736942400000
}
VectorCharts.com © 2024, Zydro Marine Technologies, Inc. · vectorcharts.com