Retrieving the list of suppliers for a Survey
Overview
Every survey in PureSpectrum has a list of suppliers that send sample. To check the list of suppliers, and their performance on a survey, you may use this endpoint.
Use
Use the endpoint at GET /surveys/:surveyId/suppliers to fetch the list of suppliers and their performance on survey.
Important Considerations
None
Request
GET $apihost/$basepath/surveys/:surveyId/suppliers
($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)
Result
Response Code
200
Response Body
[
{
"group_ref": "abc",
"group_name": "PS suppliers",
"completes_goal": 100,
"remaining": 100,
"fielded": 0,
"cpi": 6,
"intent": {
"intent_value": null,
"intent_not_set": [
1,
23
],
"intent_denied": [],
"intent_accepted": []
},
"suppliers": [
{
"id": 1,
"name": "Supplier 1"
},
{
"id": 23,
"name": "Supplier 23"
}
]
},
{
"group_ref": null,
"group_name": null,
"completes_goal": 100,
"remaining": 100,
"fielded": 0,
"cpi": 4,
"last_start_date": "",
"intent": {
"intent_value": 0
},
"suppliers": [
{
"id": 16,
"name": "Supplier 16"
}
]
}
] |
Request:
GET $apihost/$basepath/surveys/:surveyId/suppliers?stats=1
Query Params:
stats = 1/0 ( 1 to get performance / 0 to not get perfromance )
($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)
Result
Response Code
200
Response Body
[
{
"group_ref": "abc",
"group_name": "PS suppliers",
"completes_goal": 100,
"remaining": 100,
"fielded": 0,
"cpi": 6,
"intent": {
"intent_value": 50,
"intent_not_set": [
1
],
"intent_denied": [
23
],
"intent_accepted": []
},
"suppliers": [
{
"id": 1,
"name": "Supplier 1"
},
{
"id": 23,
"name": "Supplier 23"
}
],
"performance": [
{
"name": "PS_Termination_Core",
"count": 1,
"percentage_of_supplier_total": 11,
"supplier_share_status": 100
},
{
"name": "PS_Side_In_Progress",
"count": 2,
"percentage_of_supplier_total": 22,
"supplier_share_status": 100
},
{
"name": "Complete",
"count": 6,
"percentage_of_supplier_total": 66,
"supplier_share_status": 75
}
],
"valid_clicks": 6,
"valid_click_cost": 3.5,
"valid_click_percentage": 67,
"total_click_cost": 2.33
},
{
"group_ref": null,
"group_name": null,
"completes_goal": 100,
"remaining": 98,
"fielded": 2,
"cpi": 4.17,
"last_start_date": 1576129870101,
"intent": {
"intent_value": 32
},
"suppliers": [
{
"id": 190,
"name": null
}
],
"performance": [
{
"name": "Complete",
"count": 2,
"percentage_of_supplier_total": 100,
"supplier_share_status": 25
}
],
"valid_clicks": 2,
"valid_click_cost": 2.92,
"valid_click_percentage": 100,
"total_click_cost": 2.92
}
]