Unsubscribe a business
DELETEhttps://api.staging.powerapi.com/api/v2/businesses/:business_id/subscriptions
This endpoint lets you unsubscribe a business to one or several products
Request
Path Parameters
business_id stringrequired
- application/json
Bodyrequired
canceling_date number
Date of cancellation (UNIX timestamp)
Example:
1540628702
products string[]required
List of products being canceled
Possible values: [presence_management
, review_management
, review_booster
, messages
]
Example:
["presence_management"]
Responses
- 200
- 400
- 401
- 403
- 404
- 422
- 500
- application/json
- Schema
- Example (auto)
Schema
presence_management objectrequired
review_management objectrequired
review_booster objectrequired
messages objectrequired
{
"presence_management": {
"status": "inactive"
},
"review_management": {
"status": "inactive"
},
"review_booster": {
"status": "inactive"
},
"messages": {
"status": "inactive"
}
}
- application/json
- Schema
- Example (auto)
Schema
statusCode integerrequired
HTTP status code
Example:
404
message string
Error message
Example:
Cannot find item
error string
Error name
Example:
Not Found
{
"statusCode": 404,
"message": "Cannot find item",
"error": "Not Found"
}
- application/json
- Schema
- Example (auto)
Schema
statusCode integerrequired
HTTP status code
Example:
404
message string
Error message
Example:
Cannot find item
error string
Error name
Example:
Not Found
{
"statusCode": 404,
"message": "Cannot find item",
"error": "Not Found"
}
- application/json
- Schema
- Example (auto)
Schema
statusCode integerrequired
HTTP status code
Example:
404
message string
Error message
Example:
Cannot find item
error string
Error name
Example:
Not Found
{
"statusCode": 404,
"message": "Cannot find item",
"error": "Not Found"
}
- application/json
- Schema
- Example (auto)
Schema
statusCode integerrequired
HTTP status code
Example:
404
message string
Error message
Example:
Cannot find item
error string
Error name
Example:
Not Found
{
"statusCode": 404,
"message": "Cannot find item",
"error": "Not Found"
}
- application/json
- Schema
- Example (auto)
Schema
statusCode integerrequired
HTTP status code
Example:
404
message string
Error message
Example:
Cannot find item
location stringrequired
Where in the request the error occurred
Possible values: [query
, body
, response
, param
]
errors object[]required
{
"statusCode": 404,
"message": "Cannot find item",
"location": "query",
"errors": [
{
"path": "business.id",
"constraints": {
"object_required_property": "Required property"
}
}
]
}
- application/json
- Schema
- Example (auto)
Schema
statusCode integerrequired
HTTP status code
Example:
404
message string
Error message
Example:
Cannot find item
error string
Error name
Example:
Not Found
{
"statusCode": 404,
"message": "Cannot find item",
"error": "Not Found"
}
Authorization: http
name: bearertype: httpscheme: bearerbearerFormat: JWT
- curl
- python
- go
- nodejs
- ruby
- java
- powershell
- CURL
curl -L -X DELETE 'https://api.staging.powerapi.com/api/v2/businesses/:business_id/subscriptions' \
-H 'Content-Type: application/json' \
-H 'Accept: application/json' \
-H 'Authorization: Bearer <TOKEN>' \
-d '{
"canceling_date": 1540628702,
"products": [
"presence_management"
]
}'
ResponseClear