Skip to main content

Suggestion

Request

Method: POST

Endpoint: /suggestion

curl --location 'https://<PA_SEARCH_END_POINT>/suggestion' \
--header 'Content-Type: application/json' \
--header 'Authorization: Bearer cGFTZXXXXXXXXXXXXXXXA==' \
--data '{
"customer_id": "XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX",
"website_id": "XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX",
"q": "SEARCH STRING",
"client": "CLIENT SHORTCODE"
}

Fields

FieldTypeRequiredDefaultDescription
customer_idStringNo (Required only if Personalization is enabled)Unique identifier for the customer, obtained from the Config API. This identifier persists throughout the customer's lifetime on the platform. For details on retrieving a customer ID, please refer to the Config API documentation.
website_idStringYesClient unique website id provided by PA
qStringYesInput search query string
clientStringYesUnique client shortcode provided by PA

Response

{
"payload": {
"suggested_terms": [
{}
],
"synthetic_suggested_terms": [
{}
],
"synthetic_trending_terms": [
{}
],
"trending_terms": [
{}
]
},
"type": 1
}