QBP on API
In some cases, you may desire to set up a QBP survey as per UI.
This can be accomplished using the QBP API.
The QBP feature must be enabled from an operator to use this API
Request
POST $apihost/$basepath/buyers/v2/surveys
Â
($apihost is the environment against which you are testing, and $basepath is the base path with the api version. All Buy API calls will require access-token parameter in the header)Â
Request Payload when QBP is Enable:
{
"qbp" : {
"enable": true,
"quota_ids": [
"abc", // buyer_quota_id
"xyz"
]
"category": "Age" // optional in case of UI.
}
}
Request Payload when QBP is Disable:
{
"qbp" : {
"enable": false
}
}
Example:
POST $apihost/$basepath/buyers/v2/surveys
Body:Â
ResultÂ
Error 1:
QBP can’t be enabled without quotas.
Error Message 1:
Error 2:
QBP quotas can’t be enabled after getting the survey live, User can only change it in the draft survey.