Retrieve ad widget data by ID.
Important: Use the accessToken returned by the POST /ads endpoint (NOT the token from /auth/token) as the Bearer token for this request.
GET
/ads/{ad_id}
curl \
--request GET 'https://api.thankly.ai/ads/{ad_id}' \
--header "Authorization: Bearer $ACCESS_TOKEN"
Response examples (200)
{
"adId": "string",
"status": "pending",
"widgets": [
{
"type": "hotels",
"items": [
{
"title": "The Plaza Hotel",
"description": "Iconic luxury hotel in the heart of Manhattan with elegant rooms and world-class service",
"link": "https://theplazany.com",
"address": "768 5th Avenue, New York, NY 10019",
"type": "hotels"
}
]
}
]
}
Response examples (403)
{
"detail": "Token ad_id does not match requested ad_id"
}
Response examples (404)
{
"detail": "Ad not found"
}
Response examples (500)
{
"detail": "Failed to fetch ads"
}