Divendo API 2.0

We’ve rebuilt our API from the ground up to be easier than ever to integrate our platform with your favourite software

Retrieve all cancellation reasons

GET/store/cancellationreasons

Gets information about all cancellation reasons within your store configuration.

Querystring count The number of records to return
offset The number of records from a collection to skip

Example response

HTTP/1.1 200 OK
Content-Type: application/json; charset=utf-8

{
  "total": 15,
  "count": 3,
  "offset": 0,
  "results": [
    {
      "id": "56409c4546fc560098c64081",
      "name": "Arrived too late"
    },
    {
      "id": "56409c5346fc560098c6408e",
      "name": "Changed mind"
    },
    {
      "id": "56409c3646fc560098c6407e",
      "name": "Defective"
    }
  ]
}

Lookup a specific cancellation reason

GET/store/cancellationreasons/{id}

Gets information about a specific cancellation reason within your store configuration.

Parameters id The unique id for the cancellation reason

Example response

HTTP/1.1 200 OK
Content-Type: application/json; charset=utf-8

{
  "id": "56409c4546fc560098c64071",
  "name": "Arrived too late"
}

Create a new cancellation reason

POST/store/cancellationreasons

Creates a new cancellation reason within your store configuration.

Request body Cancellation Reason

Example request

Content-Type: application/json; charset=utf-8

{
  "name": "Unwanted gift"
}

Example response

HTTP/1.1 200 OK
Content-Type: application/json; charset=utf-8

{
  "id": "5aba33809b04b42268a9e901",
  "name": "Unwanted gift"
}

Update a cancellation reason

PUT/store/cancellationreasons/{id}

Updates the settings for a specific cancellation reason.

Parameters id The unique id for the cancellation reason
Request body Cancellation Reason

Example request

Content-Type: application/json; charset=utf-8

{
  "name": "Unwanted present"
}

Example response

HTTP/1.1 200 OK
Content-Type: application/json; charset=utf-8

{
  "id": "5aba33809b04b42268a9e901",
  "name": "Unwanted present"
}

Delete a cancellation reason

DELETE/store/cancellationreasons/{id}

Deletes a cancellation reason from your store configuration.

Parameters id The unique id for the cancellation reason

Example response

HTTP/1.1 204 No Content
Content-Type: application/json; charset=utf-8