Skip to main content
PUT
/
account
/
subaccount
/
{subaccount_id}
Update Sub-Account
curl --request PUT \
  --url https://api.sendpost.io/api/v1/account/subaccount/{subaccount_id} \
  --header 'Content-Type: application/json' \
  --header 'X-Account-ApiKey: <api-key>' \
  --data '
{
  "name": "FoxHole V1"
}
'
{
  "id": 50441,
  "apiKey": "pR0YIuxYSbVwmQi2Y8Qs",
  "name": "API",
  "labels": [],
  "smtpAuths": [
    {
      "id": 117,
      "username": "[email protected]",
      "password": "[email protected]",
      "created": 1567512491588004000,
      "updated": 1567512491588004000
    }
  ],
  "type": 1,
  "isPlus": false,
  "created": 1733844681120384500,
  "created_by": {
    "id": 117,
    "isVerified": true,
    "isForbidden": false,
    "firebaseUID": "1234567890",
    "email": "[email protected]",
    "name": "Raj",
    "url": "https://www.sendpost.io/logo.png",
    "companyName": "SendPost",
    "onboardQAnswered": true,
    "phoneNumber": "+919876543210",
    "notesColor": "#000000",
    "created": 1567512491588004000
  },
  "updated_by": {
    "id": 117,
    "isVerified": true,
    "isForbidden": false,
    "firebaseUID": "1234567890",
    "email": "[email protected]",
    "name": "Raj",
    "url": "https://www.sendpost.io/logo.png",
    "companyName": "SendPost",
    "onboardQAnswered": true,
    "phoneNumber": "+919876543210",
    "notesColor": "#000000",
    "created": 1567512491588004000
  },
  "blocked": false,
  "blocked_at": 0,
  "block_reason": "",
  "hb_exempt": false,
  "generate_weekly_report": false,
  "handlers": []
}

Authorizations

X-Account-ApiKey
string
header
required

This api key can be used for all account level operations

Path Parameters

subaccount_id
integer
required

The ID of the sub-account to update.

Example:

12

Body

application/json
name
string

New name for the sub-account.

Example:

"FoxHole V1"

Response

Sub-account successfully updated.

id
integer

Unique ID for the sub-account.

Example:

50441

apiKey
string

API key for the sub-account.

Example:

"pR0YIuxYSbVwmQi2Y8Qs"

name
string

Name of the sub-account.

Example:

"API"

labels
string[]

Labels associated with the sub-account

Example:
[]
smtpAuths
object[]

SMTP Auths associated with the sub-account

type
enum<integer>

Type of the sub-account

Available options:
0,
1
Example:

1

isPlus
boolean

Indicates whether the sub-account is a Plus sub-account

Example:

false

created
integer

UNIX epoch nano timestamp when the sub-account was created.

Example:

1733844681120384500

created_by
object

Member who created the sub-account

updated_by
object

Member who updated the sub-account

blocked
boolean

Indicates whether the sub-account is blocked

Example:

false

blocked_at
integer

UNIX epoch nano timestamp when the sub-account was blocked (0 if not blocked)

Example:

0

block_reason
string

Reason for blocking the sub-account

Example:

""

hb_exempt
boolean

Indicates whether the sub-account is exempt from hard bounce tracking

Example:

false

generate_weekly_report
boolean

Indicates whether weekly reports are generated for this sub-account

Example:

false

handlers
string[]

Handlers associated with the sub-account

Example:
[]