Overview
Prism is AdGem's Offer Personalization API. The /v1/offers endpoint is its GraphQL entry point for retrieving targeted offers — all GraphQL queries are sent as POST requests to this single endpoint.
Endpoint
POST https://targeted-api.adgem.com/v1/offers
Request
Headers
| Header | Value | Required | Description |
|---|---|---|---|
Authorization | Bearer <your-jwt-token> | Yes | JWT access token obtained from the Tokens endpoint |
Content-Type | application/json | Yes | Request body format |
Body
The request body must contain a valid GraphQL query in JSON format:
| Field | Type | Required | Description |
|---|---|---|---|
query | string | Yes | The GraphQL query string |
variables | object | No | Variables referenced in the query |
Example Request
curl -X POST https://targeted-api.adgem.com/v1/offers \
-H "Authorization: Bearer <your-jwt-token>" \
-H "Content-Type: application/json" \
-d '{
"query": "query GetOffers($playerId: String!) { offers(player_id: $playerId) { id name total_payout_usd creatives { name description } } }",
"variables": {
"playerId": "user-123"
}
}'
Example Response (200 OK)
{
"data": {
"offers": [
{
"id": "123456789",
"name": "Example Offer",
"total_payout_usd": 1.50,
"creatives": {
"name": "Example Offer Creative",
"description": "Complete this offer to earn rewards."
}
}
]
}
}
Error Responses
401 Unauthorized
Returned when the JWT token is missing or invalid.
{
"message": "Invalid or missing token."
}
403 Forbidden
Returned when the token is valid but lacks the required scopes.
{
"message": "Forbidden operation."
}
Available Queries
See Also
- Authentication Guide - How to obtain a JWT access token
- Tokens Endpoint - Token acquisition endpoint reference
- Playground - Interactive GraphQL playground to test queries