Delete closing document

The Delete closing document method is used for deleting information about a closing document of an account of the current reseller or any of its downstream resellers.

An API token of a manager is required for authorization. To get an API token via the Operator Control Panel, see Viewing and updating manager's information

The manager's API token specified in an API request determines:

  • The role and access level of the manager, which determine the availability of a method.
  • The current reseller and downstream resellers accessible within a method.

DELETE {base_url}/api/v3/resellers/{reseller_id}/accounts/{account_id}/external_invoices/{external_invoice_id}

Arguments

Name

Parameter Type

Data type

Required/Optional

Description

X-Api-TokenheaderstringRequiredAPI token of a manager that performs the operation (see Viewing and updating manager's information)
Content-TypeheaderstringRequiredMedia type of the request. Specify the following: application/vnd.api+json
AcceptheaderstringRequired

Supported media types of the answer. Specify the following: application/vnd.api+json

base_urlpathstringRequiredActivePlatform URL
reseller_idpathnumberRequiredID of the current reseller or any of its downstream resellers (see Viewing and updating reseller general information)
account_idpathnumberRequiredAccount ID

external_invoice_id

pathnumberRequiredClosing document ID in the platform

Response model

If no errors are encountered, the method returns information about the closing document except for file (see the response model in Get closing document).

Request example

DELETE /api/v3/resellers/1/accounts/505/external_invoices/277
Host: test.activeplatform.com
Content-Type: application/vnd.api+json
X-Api-Token: vY5fwetestK3gJXZH5uHCw
Accept: application/vnd.api+json

Response example

{
    "data": {
        "id": "277",
        "type": "external_invoices",
        "attributes": {
            "created_at": "2022-08-29T10:30:35.541209+0000",
            "updated_at": "2022-08-29T11:04:44.315677+0000",
            "type": "invoice",
            "key": "0493e78a-e8ef-11e9-81b4-2a2ae2dbcce4",
            "name": "Invoice ext",
            "start_date": "2019-11-01",
            "end_date": "2019-11-30",
            "amount": {
                "currency": "EUR",
                "total": "123.45"
            }
        }
    }
}