Checkout validation
A webhook that lets you check if a plan or quantity change is allowed before the user can checkout.
Last updated
Was this helpful?
Was this helpful?
{
"type": "CheckoutValidation",
"payload": {
"tenant": {
"id": 132,
"code": "8c665dde-69ae-4c53-990b-3d19bf71791e",
"name": "Superdesk Inc"
},
"change": {
"features": [
{
"code": "users",
"name": "Users",
"value": "",
"quantity": 10,
"plan": {
"code": "enterprise",
"name": "Enterprise"
},
"price_list": {
"code": null,
"name": "Enterprise Monthly"
}
},
{
"code": "widgets",
"name": "Widgets",
"value": "100",
"quantity": 100,
"plan": {
"code": "enterprise",
"name": "Enterprise"
},
"price_list": {
"code": null,
"name": "Enterprise Monthly"
}
}
]
}
}
}HTTP STATUS CODE: 200 - OKHTTP STATUS CODE: 422 - Unprocessable Content[
"You have too many users to downgrade to this plan. Please remove some users and try again."
]