menu
Update an account
Renames an account (workspace). Partial update, but the name is currently the only writable field here - webhook settings have their own dedicated endpoint.
Endpoint
PATCH https://api.sendstreak.com/v2/accounts/{accountId}
All v2 endpoints require a bearer token - see Authentication.
Path parameters
| Parameter | Type | Description |
|---|---|---|
accountId | string | The account the request is scoped to. |
Request body
| Field | Type | Required | Description |
|---|---|---|---|
name | string | yes | The account (workspace) name, shown across the dashboard and in team invitations. |
Response
The updated account.
{
"_id": "665f0a2b1c9d440012ab34cd",
"name": "Example name",
"webhooks": {
"authType": "basic",
"events": [
"message_bounced"
],
"passwordOrToken": "webhook-bearer-token",
"signingSecret": "whsec_9f8e7d6c5b4a39281706",
"url": "https://example.com/webhooks/sendstreak",
"username": "smtp-user"
}
}
Errors
| Status | Description |
|---|---|
400 | The request body or parameters failed validation. |
401 | Missing or invalid token, or the token is not authorized for this account/user. |
See Errors and rate limits for what error responses look like.
Curl example
curl --location --request PATCH 'https://api.sendstreak.com/v2/accounts/YOUR_ACCOUNT_ID' \
--header 'Authorization: Bearer YOUR_API_TOKEN' \
--header 'Content-Type: application/json' \
--data-raw '{
"name": "Example name"
}'