MediaMath Platform API
MediaMath Platform API
curl -i -X POST \
https://apidocs.mediamath.com/targeting \
-H 'Authorization: Bearer <YOUR_TOKEN_HERE>' \
-H 'Content-Type: application/json' \
-d '{
"strategy_id": [
0
],
"targeting": {
"audience": {
"include": [
{
"operator": "AND",
"audience_segment_ids": [
0
]
}
],
"exclude": [
{
"operator": "AND",
"audience_segment_ids": [
0
]
}
]
},
"contextual": {
"include": [
{
"code": "string",
"operator": "AND",
"target_value_ids": [
0
]
}
],
"exclude": [
{
"code": "string",
"operator": "AND",
"target_value_ids": [
0
]
}
]
},
"my_data": {
"include": {
"pixel_bundle_ids": [
0
],
"operator": "AND"
},
"exclude": {
"pixel_bundle_ids": [
0
]
}
},
"location": {
"include": [
{
"code": "string",
"operator": "AND",
"target_value_ids": [
0
]
}
],
"exclude": [
{
"code": "string",
"operator": "AND",
"target_value_ids": [
0
]
}
]
},
"technology": {
"include": [
{
"code": "string",
"operator": "AND",
"target_value_ids": [
0
]
}
],
"exclude": [
{
"code": "string",
"operator": "AND",
"target_value_ids": [
0
]
}
]
},
"day_parts": [
{
"user_time": true,
"start_hour": 1,
"end_hour": 5,
"days": [
"M",
"T",
"W",
"S",
"U"
]
}
]
}
}'
{ "data": { "location": [ … ] }, "meta": { "status": "string", "count": 0 }, "errors": [ null ] }
curl -i -X POST \
https://apidocs.mediamath.com/contextual_segments/cpm_estimate \
-H 'Authorization: Bearer <YOUR_TOKEN_HERE>' \
-H 'Content-Type: application/json' \
-d '{
"currency_code": "USD",
"include": [
{
"code": "string",
"operator": "string",
"segments": [
{
"targeting_segment_id": 0,
"user_cpm": 0
}
]
}
],
"exclude": {
"code": "string",
"operator": "string",
"segments": [
{
"targeting_segment_id": 0,
"user_cpm": 0
}
]
}
}'
{ "data": { "cpm": { … } }, "meta": { "status": "success" } }
curl -i -X GET \
'https://apidocs.mediamath.com/targeting_segments/frequently_used?advertiser_id=0&top=0' \
-H 'Authorization: Bearer <YOUR_TOKEN_HERE>'
{ "data": [ { … } ], "meta": { "status": "success" } }