Skip to content

Disable a subaccount

Request

Disable a subaccount

Security
basicAuth
Path
subaccount_idstringrequired

The ID of the subaccount

Query
reasonstring

The reason for disabling the subaccount

notestring

A note for the subaccount

curl -i -X POST \
  -u '<username>:<password>' \
  'https://api.mailgun.net/v5/accounts/subaccounts/{subaccount_id}/disable?reason=string&note=string'

Responses

Subaccount disabled successfully

Bodyapplication/json
subaccountobject(github.com-mailgun-accounts-api-Subaccount)
Response
{ "subaccount": { "id": "123", "name": "My subaccount", "created_at": "Wed, 06 Nov 2024 19:48:29 GMT", "updated_at": "Wed, 28 May 2025 20:03:05 GMT", "status": "disabled" } }