Get information about the Reseller asynchronous task by ID

The Get information about the Reseller async task by ID method is used with ordering a new Subscription (see Create a Sales Order) for checking the status of an asynchronous task of the current Reseller or any of its downstream Resellers. An asynchronous task is used to validate the values of additional attributes on the Service side (see Validate the Reseller's Plan order attributes).

Access to the current Reseller and downstream Resellers is determined by the Manager's token in the API request.

GET {base_url}/api/v3/resellers/{reseller_id}/async_tasks/{async_task_id}

Arguments

Name

Parameter Type

Data type

Required/Optional

Description

X-Api-TokenheaderstringRequiredAPI token of the Manager that performs the operation (see Viewing and updating manager's information)
Content-TypeheaderstringRequiredIndicates the media type (text/html or text/JSON) of the request that is sent to the server by the client (browser)
AcceptheaderstringRequired

Information about data types that the client (browser) supports

reseller_idpathintegerRequiredID of the current Reseller or any of its downstream Resellers (see Viewing and updating reseller general information)

async_task_id

pathintegerRequiredID of the asynchronous task

Response model

Name

Data type

Description

dataobjectResponse data

idstringID of the asynchronous task

typestringData type

attributesobjectAttributes of the asynchronous task


statusstring

Status of the asynchronous task:

  • pending — the task is created.
  • running — the task is active, validation is undergoing.
  • completed — the task is completed successfully.
  • failed — the task is failed due to an error on the platform side.


failure_messagestringError description — if the asynchronous task is failed due to an error on the platform side (status = failed)


resultsobjectInformation about validation of additional attributes — if the asynchronous task is completed successfully (status = completed)



validbool

Validation result:

  • true — all additional attributes are valid.
  • false — any of additional attributes are not valid.



errorsarrayList of keys of additional attributes and error descriptions — if any of additional attributes are not valid (validfalse)



application_attributesobject

Request example

GET /api/v3/resellers/1/async_tasks/9b68427b-52d5-4c01-9b77-eb1b70517414
Host: test.activeplatform.com
Content-Type: application/vnd.api+json
X-Api-Token: vY5fwetestK3gJXZH5uHCw
Accept: application/vnd.api+json

Response example 

{
     "data":
    {
        "id": "9b68427b-52d5-4c01-9b77-eb1b70517414",
        "type": "async_tasks",
        "attributes":
        {
            "status": "completed",
            "failure_message": "",
            "results":
                {
                    "valid": true,
                    "errors": [{}] ,
                    "application_attributes": {application_attributes}
                }
        }
    }
}