DELETE
/
listings
/
{listing-id}
/

Allows for a listing to be immediately deleted or to be scheduled for deletion.

All date fields included in the body parameters need to be specified as ISO8601-formatted date strings.

Date fields should follow a “YYYY-MM-DD” format.

Authorization
string
default: "none"required

The authentication token for your request

Path

listing_id
string
default: "none"required

The id of the listing to be deleted

Body

inactive-date
date
default: "Current date"required

The date at which the listing should be deleted.

If left empty, it defaults to the current date

Response

success
boolean

Indicates whether the listing has been succesfully scheduled for deletion or not.

listing_id
boolean

The id of the listing scheduled for deletion.

Errors

Listed below are common errors that may be returned by the endpoint, along with their corresponding status code.

Status Code - 400

Missing Authorization header
{
   "error": {
    "type": "missing_authorization",
    "message": "Your request does not include an 'Authorization' header with a bearer token for your account."
  }
}

Status Code - 401

Expired Authorization header bearer token value
{
   "error": {
    "type": "expired_token",
    "message": "The bearer token you have provided in the 'Authorization' header has expired. Please obtain a new one."
  }
}

Status Code - 401

Invalid Authorization header bearer token value
{
   "error": {
    "type": "invalid_authorization",
    "message": "The bearer token you have provided in the 'Authorization' header is invalid."
  }
}

Status Code - 401

Returned if the currently authenticated user does not have permission to delete the listing they are attempting to delete

Invalid/Expired Authorization header bearer token value
{
   "error": {
    "type": "not_authorized",
    "message": "The user you have authenticated as is not authorized to delete the listing you are attempting to delete."
  }
}