Campaigns API (xx.xx.xx)

MediaMath Platform API

Download OpenAPI description
Languages
Servers
Mock server
https://apidocs.mediamath.com/_mock/apis/campaigns-api/openapi/

Organizations

Organizations

Operations

Agencies

Agencies

Operations

Advertisers

Advertisers

Operations

Campaigns

Campaigns

Operations

Strategies

Strategies

Operations

Targeting

Targeting

Operations

Vendor Contracts

Vendor Contracts

Operations

Strategy Templates

Strategy Templates

Operations

Atomic Creatives

Atomic Creatives

Operations

Concepts

Concepts

Operations

Creatives

Creatives

Operations

Pixel Bundles

Pixel Bundles

Operations

Campaign Plans

Campaign Plans

Operations

Strategy Plans

Strategy Plans

Operations

Bulk Update

Bulk Update

Operations

Marketplaces

Marketplaces

Operations

Users

Users

Operations

List users

Request

Get a list of users

Query
page_limitinteger[ 1 .. 1000 ]

Number of elements in the collection to retrieve

Example: page_limit=100
page_offsetinteger[ 0 .. 1000 ]

Index of the first element in the collection to retrieve

Example: page_offset=0
sort_bystring

The field to sort by. You can use any field name in ascending or descending order. For ascending order, use the field name directly, e.g., id. For descending order, prefix the field name with a hyphen (-), e.g., -id.

Example: sort_by=id, -id, name, -name
sort_orderstring

Sorting order for the sort_by parameter for the result list

qstring

Query search for filtering. This parameter can be used to filter results based on various fields.

  • q=name=:{search}* to find all results with names starting with "search".
  • q=status==true to find all active entities.
  • q=id>=1000 to find all entities with id greater than or equal to 1000.
curl -i -X GET \
  'https://apidocs.mediamath.com/_mock/apis/campaigns-api/openapi/users?page_limit=100&page_offset=0&q=string&sort_by=id%2C%20-id%2C%20name%2C%20-name&sort_order=string' \
  -H 'Authorization: Bearer <YOUR_TOKEN_HERE>'

Responses

standard list of entities

Bodyapplication/json
dataArray of objects or null
metaobject(pagination metadata)
Response
application/json
{ "data": [ {} ], "meta": { "status": "success", "count": 10, "total_count": 100, "offset": 0, "next_page": "string", "prev_page": "string" } }

Create a User

Request

Create a user

Bodyapplication/jsonrequired
titlestring<= 64 characters
activeboolean
languagestring
zone_namestring
first_namestring[ 1 .. 32 ] charactersrequired
last_namestring[ 1 .. 32 ] charactersrequired
phonestring<= 24 characters
usernamestring[ 1 .. 255 ] charactersrequired
rolesArray of integers(int16)required
curl -i -X POST \
  https://apidocs.mediamath.com/_mock/apis/campaigns-api/openapi/users \
  -H 'Authorization: Bearer <YOUR_TOKEN_HERE>' \
  -H 'Content-Type: application/json' \
  -d '{
    "title": "string",
    "active": true,
    "language": "string",
    "zone_name": "string",
    "first_name": "string",
    "last_name": "string",
    "phone": "string",
    "username": "string",
    "roles": [
      0
    ]
  }'

Responses

Created

Bodyapplication/json
dataobject(user)
metaobject
Response
application/json
{ "data": { "title": "string", "active": true, "language": "string", "zone_name": "string", "id": 0, "entity_type": "string", "username": "string", "version": 0, "first_name": "string", "last_name": "string", "link_ldap": true, "link_saml": true, "phone": "string", "mobile": "string", "fax": "string", "type": "string", "role": "string", "scope": "string", "view_organizations": true, "edit_campaigns": true, "edit_margins_and_performance": true, "creator_id": 0, "created_on": "2019-08-24T14:15:22Z", "updated_on": "2019-08-24T14:15:22Z", "last_login_on": "string", "access_internal_fees": true, "view_segments": true, "edit_segments": true, "view_data_definition": true, "edit_data_definition": true, "view_dmp_reports": true, "email": "string", "roles": [], "permissions": {} }, "meta": { "status": "success" } }

Get a User

Request

Get a User by its ID

Path
user_idintegerrequired

Numeric ID of the user to get

Query
extendedboolean

Get extended properties in response

curl -i -X GET \
  'https://apidocs.mediamath.com/_mock/apis/campaigns-api/openapi/users/{user_id}?extended=true' \
  -H 'Authorization: Bearer <YOUR_TOKEN_HERE>'

Responses

User GET

Bodyapplication/json
dataobject(user)
metaobject
Response
application/json
{ "data": { "title": "string", "active": true, "language": "string", "zone_name": "string", "id": 0, "entity_type": "string", "username": "string", "version": 0, "first_name": "string", "last_name": "string", "link_ldap": true, "link_saml": true, "phone": "string", "mobile": "string", "fax": "string", "type": "string", "role": "string", "scope": "string", "view_organizations": true, "edit_campaigns": true, "edit_margins_and_performance": true, "creator_id": 0, "created_on": "2019-08-24T14:15:22Z", "updated_on": "2019-08-24T14:15:22Z", "last_login_on": "string", "access_internal_fees": true, "view_segments": true, "edit_segments": true, "view_data_definition": true, "edit_data_definition": true, "view_dmp_reports": true, "email": "string", "roles": [], "permissions": {} }, "meta": { "status": "success" } }

Update a User

Request

Update a user by id

Path
user_idintegerrequired

Numeric ID of the user to update

Bodyapplication/jsonrequired
titlestring<= 64 characters
activeboolean
languagestring
zone_namestring
versionintegerrequired
first_namestringrequired
last_namestringrequired
phonestring
rolesArray of integers(int16)required
curl -i -X POST \
  'https://apidocs.mediamath.com/_mock/apis/campaigns-api/openapi/users/{user_id}' \
  -H 'Authorization: Bearer <YOUR_TOKEN_HERE>' \
  -H 'Content-Type: application/json' \
  -d '{
    "title": "string",
    "active": true,
    "language": "string",
    "zone_name": "string",
    "version": 0,
    "first_name": "string",
    "last_name": "string",
    "phone": "string",
    "roles": [
      0
    ]
  }'

Responses

Updated

Bodyapplication/json
dataobject(user)
metaobject
Response
application/json
{ "data": { "title": "string", "active": true, "language": "string", "zone_name": "string", "id": 0, "entity_type": "string", "username": "string", "version": 0, "first_name": "string", "last_name": "string", "link_ldap": true, "link_saml": true, "phone": "string", "mobile": "string", "fax": "string", "type": "string", "role": "string", "scope": "string", "view_organizations": true, "edit_campaigns": true, "edit_margins_and_performance": true, "creator_id": 0, "created_on": "2019-08-24T14:15:22Z", "updated_on": "2019-08-24T14:15:22Z", "last_login_on": "string", "access_internal_fees": true, "view_segments": true, "edit_segments": true, "view_data_definition": true, "edit_data_definition": true, "view_dmp_reports": true, "email": "string", "roles": [], "permissions": {} }, "meta": { "status": "success" } }

User Audit Log

Request

Get a list changes to this user

Path
user_idintegerrequired

Numeric ID of the user

Query
page_limitinteger[ 1 .. 1000 ]

Number of elements in the collection to retrieve

Example: page_limit=100
page_offsetinteger[ 0 .. 1000 ]

Index of the first element in the collection to retrieve

Example: page_offset=0
curl -i -X GET \
  'https://apidocs.mediamath.com/_mock/apis/campaigns-api/openapi/users/{user_id}/history?page_limit=100&page_offset=0' \
  -H 'Authorization: Bearer <YOUR_TOKEN_HERE>'

Responses

list of changes to an entity

Bodyapplication/json
dataArray of objects or null
metaobject(pagination metadata)
Response
application/json
{ "data": [ {} ], "meta": { "status": "success", "count": 10, "total_count": 100, "offset": 0, "next_page": "string", "prev_page": "string" } }

Query User Permissions

Request

Get a list of permissions

Path
user_idintegerrequired

User ID

Query
page_limitinteger[ 1 .. 1000 ]

Number of elements in the collection to retrieve

Example: page_limit=100
page_offsetinteger[ 0 .. 1000 ]

Index of the first element in the collection to retrieve

Example: page_offset=0
organization_idArray of integers

Numeric ID of the user

agency_idArray of integers

Numeric ID of the agency

advertiser_idArray of integers

Numeric ID of the advertiser

campaign_idArray of integers

Numeric ID of the campaign

strategy_idArray of integers

Numeric ID of the strategy

curl -i -X GET \
  'https://apidocs.mediamath.com/_mock/apis/campaigns-api/openapi/permissions/{user_id}?advertiser_id=0&agency_id=0&campaign_id=0&organization_id=0&page_limit=100&page_offset=0&strategy_id=0' \
  -H 'Authorization: Bearer <YOUR_TOKEN_HERE>'

Responses

OK

Bodyapplication/json
dataobject(permission_list)
metaobject
Response
application/json
{ "data": { "organizations": [], "agencies": [], "advertisers": [], "campaigns": [], "strategies": [] }, "meta": { "status": "success" } }

Query User Permissions

Request

Get a list of permissions

Path
user_idintegerrequired

User ID

Query
page_limitinteger[ 1 .. 1000 ]

Number of elements in the collection to retrieve

Example: page_limit=100
page_offsetinteger[ 0 .. 1000 ]

Index of the first element in the collection to retrieve

Example: page_offset=0
Bodyapplication/jsonrequired
organizationsArray of integers
agenciesArray of integers
advertisersArray of integers
campaignsArray of integers
strategiesArray of integers
curl -i -X POST \
  'https://apidocs.mediamath.com/_mock/apis/campaigns-api/openapi/permissions/{user_id}?page_limit=100&page_offset=0' \
  -H 'Authorization: Bearer <YOUR_TOKEN_HERE>' \
  -H 'Content-Type: application/json' \
  -d '{
    "organizations": [
      0
    ],
    "agencies": [
      0
    ],
    "advertisers": [
      0
    ],
    "campaigns": [
      0
    ],
    "strategies": [
      0
    ]
  }'

Responses

OK

Bodyapplication/json
dataobject(permission_list)
metaobject
Response
application/json
{ "data": { "organizations": [], "agencies": [], "advertisers": [], "campaigns": [], "strategies": [] }, "meta": { "status": "success" } }

List Permissions to All Organizations

Request

Get a list of permissions

Path
user_idintegerrequired

User ID

Query
page_limitinteger[ 1 .. 1000 ]

Number of elements in the collection to retrieve

Example: page_limit=100
page_offsetinteger[ 0 .. 1000 ]

Index of the first element in the collection to retrieve

Example: page_offset=0
curl -i -X GET \
  'https://apidocs.mediamath.com/_mock/apis/campaigns-api/openapi/permissions/{user_id}/organizations?page_limit=100&page_offset=0' \
  -H 'Authorization: Bearer <YOUR_TOKEN_HERE>'

Responses

OK

Bodyapplication/json
dataArray of objects(permission_organization)
metaobject(pagination metadata)
Response
application/json
{ "data": [ {} ], "meta": { "status": "success", "count": 10, "total_count": 100, "offset": 0, "next_page": "string", "prev_page": "string" } }

List Permissions to All Agencies

Request

Get a list of permissions

Path
user_idintegerrequired

User ID

Query
page_limitinteger[ 1 .. 1000 ]

Number of elements in the collection to retrieve

Example: page_limit=100
page_offsetinteger[ 0 .. 1000 ]

Index of the first element in the collection to retrieve

Example: page_offset=0
curl -i -X GET \
  'https://apidocs.mediamath.com/_mock/apis/campaigns-api/openapi/permissions/{user_id}/agencies?page_limit=100&page_offset=0' \
  -H 'Authorization: Bearer <YOUR_TOKEN_HERE>'

Responses

OK

Bodyapplication/json
dataArray of objects(permission_agency)
metaobject(pagination metadata)
Response
application/json
{ "data": [ {} ], "meta": { "status": "success", "count": 10, "total_count": 100, "offset": 0, "next_page": "string", "prev_page": "string" } }

List Permissions to All Advertisers

Request

Get a list of permissions

Path
user_idintegerrequired

User ID

Query
page_limitinteger[ 1 .. 1000 ]

Number of elements in the collection to retrieve

Example: page_limit=100
page_offsetinteger[ 0 .. 1000 ]

Index of the first element in the collection to retrieve

Example: page_offset=0
curl -i -X GET \
  'https://apidocs.mediamath.com/_mock/apis/campaigns-api/openapi/permissions/{user_id}/advertisers?page_limit=100&page_offset=0' \
  -H 'Authorization: Bearer <YOUR_TOKEN_HERE>'

Responses

OK

Bodyapplication/json
dataArray of objects(permission_advertiser)
metaobject(pagination metadata)
Response
application/json
{ "data": [ {} ], "meta": { "status": "success", "count": 10, "total_count": 100, "offset": 0, "next_page": "string", "prev_page": "string" } }

List Permissions to All Campaigns

Request

Get a list of permissions

Path
user_idintegerrequired

User ID

Query
page_limitinteger[ 1 .. 1000 ]

Number of elements in the collection to retrieve

Example: page_limit=100
page_offsetinteger[ 0 .. 1000 ]

Index of the first element in the collection to retrieve

Example: page_offset=0
curl -i -X GET \
  'https://apidocs.mediamath.com/_mock/apis/campaigns-api/openapi/permissions/{user_id}/campaigns?page_limit=100&page_offset=0' \
  -H 'Authorization: Bearer <YOUR_TOKEN_HERE>'

Responses

OK

Bodyapplication/json
dataArray of objects(permission_campaign)
metaobject(pagination metadata)
Response
application/json
{ "data": [ {} ], "meta": { "status": "success", "count": 10, "total_count": 100, "offset": 0, "next_page": "string", "prev_page": "string" } }

List Permissions to All Strategies

Request

Get a list of permissions

Path
user_idintegerrequired

User ID

Query
page_limitinteger[ 1 .. 1000 ]

Number of elements in the collection to retrieve

Example: page_limit=100
page_offsetinteger[ 0 .. 1000 ]

Index of the first element in the collection to retrieve

Example: page_offset=0
curl -i -X GET \
  'https://apidocs.mediamath.com/_mock/apis/campaigns-api/openapi/permissions/{user_id}/strategies?page_limit=100&page_offset=0' \
  -H 'Authorization: Bearer <YOUR_TOKEN_HERE>'

Responses

OK

Bodyapplication/json
dataArray of objects(permission_strategy)
metaobject(pagination metadata)
Response
application/json
{ "data": [ {} ], "meta": { "status": "success", "count": 10, "total_count": 100, "offset": 0, "next_page": "string", "prev_page": "string" } }

Query User Permissions

Request

Get a list of permissions in V2 format

Path
user_idintegerrequired

User ID

curl -i -X GET \
  'https://apidocs.mediamath.com/_mock/apis/campaigns-api/openapi/permissions/{user_id}/v2format' \
  -H 'Authorization: Bearer <YOUR_TOKEN_HERE>'

Responses

OK

Bodyapplication/json
dataobject(permission_v2_object)
metaobject
Response
application/json
{ "data": { "flags": {}, "entities": {} }, "meta": { "status": "success" } }

Query User Permissions

Request

Get a list of permissions

Path
user_idintegerrequired

User ID

Bodyapplication/jsonrequired
organizationsArray of integers
agenciesArray of integers
advertisersArray of integers
curl -i -X POST \
  'https://apidocs.mediamath.com/_mock/apis/campaigns-api/openapi/permissions/{user_id}/v2format' \
  -H 'Authorization: Bearer <YOUR_TOKEN_HERE>' \
  -H 'Content-Type: application/json' \
  -d '{
    "organizations": [
      0
    ],
    "agencies": [
      0
    ],
    "advertisers": [
      0
    ]
  }'

Responses

OK

Bodyapplication/json
dataobject(permission_v2_object)
metaobject
Response
application/json
{ "data": { "flags": {}, "entities": {} }, "meta": { "status": "success" } }

Enterprise Controls

Enterprise Controls

Operations

General

General

Operations

Currency Rates

Currency Rates

Operations

Site Lists

Site Lists

Operations

Timezones

Timezones

Operations

Strategy Groups

Strategy Groups

Operations

Strategy Day Parts

Strategy Day Parts

Operations

Strategy Deals

Strategy Deals

Operations

Strategy IP Addresses

Strategy IP Addresses

Operations

Strategy Concepts

Strategy Concepts

Operations

Targeting Segments

Targeting Segments

Operations

Strategy Target Values

Strategy Target Values

Operations

List Organization Settings

Operations

Update Organization Settings

Operations

New Strategy Plans

Operations

Strategy Plan Target Values

Operations

Campaigns Budget Flights

Operations

User Settings

Operations

Update User Settings

Operations

Supply Sources

Operations

Vendors

Operations

Ad Servers

Operations

Site Lists Site Download

Operations

Site Lists Assignments

Operations

Targeting Segment Objectives

Operations

Targeting Segment Objective

Operations