Campaign Query Requests

Use the Campaign Query API to retrieve detailed information and perfomance metrics from campaigns and optionally their associated goals and ads.

Getting Started

  • Base URL: https://api.videoplaza.com/v3/campaigns.
  • Requests: GET requests are used. You pass parameters by using common REST parameters like PATH and QUERY, as well as HTTP HEADERS. The body of the requests should be provided in JSON format and encoded using UTF-8.
  • Responses: All responses contain an HTTP status code in the header and the body is in JSON format.
  • Swagger documentation: Campaign API v3 - Campaigns
  • Related user documentation:
The Campaign Query endpoints allow you to:

Query for Multiple Campaigns

This endpoint enables you to list all campaigns associated with your account. Various query parameters allow you to get very detailed and specific information on a subset of campaigns that match your query, all within one API call. You can expand goals and ads associated with the campaigns, which results in a nested structure representing the hierarchy between campaigns, goal, and ads. You can also embed metrics and this way quickly retrieve one, several, or all available metrics for the listed campaigns. Embedded metrics are only returned on the campaigns and not on expanded objects, to allow scaling for larger accounts with many goals and ads within campaigns. Paging is added by default but can also be specified using paging parameters, to further narrow down the result. This is especially important for heavy requests that include lots of embedded objects. The available query parameters are described in detail in the table below.

Method GET
URL /v3/campaigns
Header Authentication header (x-o-api-key)
Content type application/json
URL params -
Query params
Note: All query parameters are optional.
  • expand: add the parameter to the query string to expand either all the goals associated with the campaign (expand=goals), or all the goals associated with the campaign and all the ads associated with the listed goals (expand=goals&expand=ads). Possible values are:
    • goals
    • ads
    If the parameter is not present, a link to each goal's details is returned.
    "goals": [
                    {
                        "id": "<goal ID>",
                        "href": "https://api.videoplaza.com/v3/goals/<goal ID>"
                    }
                ]
  • embed: add the parameter to the query string to retrieve the metrics available for the campaigns. When listing all campaigns, the metrics are returned only for campaigns, never for expanded goals and ads, if there are any.
    • Add embed=metrics to the query string to retrieve all the available metrics.
    • Add embed=metrics&metrics=<value> to the query string to retrieve one or several specific metrics. Possible values are:
      • impression
      • clickThrough
      • start
      • firstQuartile
      • midpoint
      • thirdQuartile
      • complete

      For example: embed=metrics&metrics=impression&metrics=clickThrough&metrics=complete

  • includeDeletedGoals: add the parameter to the query string to include all associated, but deleted goals. By default, they are not listed.
  • includeDeletedCampaigns: add the parameter to the query string to include any deleted campaigns in the results. By default, they are not listed.
  • campaigns.started.before: filter on campaigns that started before a specific date and time. See Date and Time Format on how to format this field.
  • campaigns.started.after: filter on campaigns that started after a specific date and time. See Date and Time Format on how to format this field.
  • campaigns.ended.before: filter on campaigns that ended before a specific date and time. See Date and Time Format on how to format this field.
  • campaigns.ended.after: filter on campaigns that ended after a specific date and time. See Date and Time Format on how to format this field.
  • campaign.state: filter on campaigns in a specific state. By default, campaigns of all states are included in the response. Enter a campaign.state=<value> for each state you want to filter on. Possible values are:
    • enabled
    • disabled
    • archived
  • ids: add ids=<value> to the query string for each specific campaign you want listed in the results. The <value> corresponds to an exact campaign's ID.
  • pageSize: enter the number of campaigns to return for each page. You can use this feature if you want to create pagination in your user interface. The value must be between 1 and 100. The default value is 10.
  • pageNumber: enter the number of the page you want the results from. This parameter works in combination with the pageSize parameter. The default value is 1. Based on the pageSize value you provide and the totalCount value returned (see Response Body Format), you can calculate how many pages there are in total.
Body -
Success response

HTTP status: 200 OK

Header: -

Body: see Response Body Format.

Example - No Expanded Objects:

Request header:

GET /v3/campaigns?campaigns.started.after=2018-07-19T00:00:00Z&embed=metrics HTTP/1.1
Host: api.videoplaza.com
Content-type: application/json
x-o-api-key="<your key>"

Request body: -

Success response:

HTTP status:
  200 (OK)

Body:
{
    "campaigns": [
        {
            "id": "b8d44a5e-6e1d-42a5-a5fd-cb504cf514a3",
            "name": "Ooyala autumn campaign",
            "description": "Ooyala autumn 2018 campaign (sponsor)",
            "start": "2018-08-30T22:00:00Z",
            "end": "2018-10-31T23:00:00Z",
            "brand": {
                "id": "5fc003be-a09f-4fc6-8d88-a8200b24f70d"
            },
            "agency": {
                "id": "efab6d70-855d-425e-abff-d5edcd36afc1"
            },
            "advertiser": {
                "id": "2c3364bb-5fb6-4bab-b327-ecaddc08a0ae"
            },
            "state": "disabled",
            "ignoreGlobalExternalTrackers": false,
            "includedInForecast": true,
            "exclusive": false,
            "deleted": false,
            "sequenceScope": "session",
            "goals": [
                {
                    "id": "4866d0b3-2686-4fed-a87a-8f419cf5c935",
                    "href": "https://api.videoplaza.com/v3/goals/4866d0b3-2686-4fed-a87a-8f419cf5c935"
                }
            ],
            "priority": {
                "value": 5,
                "origin": {
                    "id": "301af24d-d8bf-4ddf-985a-c94cdf254ebb",
                    "entity": "site"
                }
            },
            "frontload": {
                "value": 30,
                "origin": {
                    "id": "301af24d-d8bf-4ddf-985a-c94cdf254ebb",
                    "entity": "site"
                }
            },
            "metrics": {
                "impression": 0,
                "clickThrough": 0,
                "start": 0,
                "firstQuartile": 0,
                "midpoint": 0,
                "thirdQuartile": 0,
                "complete": 0
            }
        },
        {
            "id": "57e239e6-003d-4c01-804f-695d05fdd5da",
            "name": "Ooyala summer campaign",
            "description": "Ooyala summer 2018 campaign.",
            "customId": "Custom campaign ID",
            "start": "2018-07-19T22:00:00Z",
            "end": "2018-09-15T22:00:00Z",
            "brand": {
                "id": "5fc003be-a09f-4fc6-8d88-a8200b24f70d"
            },
            "agency": {
                "id": "efab6d70-855d-425e-abff-d5edcd36afc1"
            },
            "advertiser": {
                "id": "2c3364bb-5fb6-4bab-b327-ecaddc08a0ae"
            },
            "state": "enabled",
            "ignoreGlobalExternalTrackers": false,
            "includedInForecast": true,
            "exclusive": false,
            "deleted": false,
            "sequenceScope": "session",
            "goals": [
                {
                    "id": "e26d57f8-ba36-422e-8730-8b7e44311d9f",
                    "href": "https://api.videoplaza.com/v3/goals/e26d57f8-ba36-422e-8730-8b7e44311d9f"
                },
                {
                    "id": "80028bd7-95d3-4d89-8945-6d0801b5c03e",
                    "href": "https://api.videoplaza.com/v3/goals/80028bd7-95d3-4d89-8945-6d0801b5c03e"
                }
            ],
            "priority": {
                "value": 4,
                "origin": {
                    "id": "57e239e6-003d-4c01-804f-695d05fdd5da",
                    "href": "https://api.videoplaza.com/v3/campaigns/57e239e6-003d-4c01-804f-695d05fdd5da",
                    "entity": "campaign"
                }
            },
            "frontload": {
                "value": 30,
                "origin": {
                    "id": "301af24d-d8bf-4ddf-985a-c94cdf254ebb",
                    "entity": "site"
                }
            },
            "metrics": {
                "impression": 0,
                "clickThrough": 0,
                "start": 0,
                "firstQuartile": 0,
                "midpoint": 0,
                "thirdQuartile": 0,
                "complete": 0
            }
        }
    ],
    "pagination": {
        "totalCount": 2,
        "pageSize": 10,
        "pageNumber": 1
    }
}

Example - Expanded Objects:

Request header:

GET /v3/campaigns?campaigns.started.after=2018-07-19T00:00:00Z&expand=goals&expand=ads&embed=metrics&metrics=impression&metrics=complete HTTP/1.1
Host: api.videoplaza.com
Content-type: application/json
x-o-api-key="<your key>"

Request body: -

Success response:

HTTP status:
  200 (OK)

Body:
{
    "campaigns": [
        {
            "id": "b8d44a5e-6e1d-42a5-a5fd-cb504cf514a3",
            "name": "Ooyala autumn campaign",
            "description": "Ooyala autumn 2018 campaign (sponsor)",
            "start": "2018-08-30T22:00:00Z",
            "end": "2018-10-31T23:00:00Z",
            "brand": {
                "id": "5fc003be-a09f-4fc6-8d88-a8200b24f70d"
            },
            "agency": {
                "id": "efab6d70-855d-425e-abff-d5edcd36afc1"
            },
            "advertiser": {
                "id": "2c3364bb-5fb6-4bab-b327-ecaddc08a0ae"
            },
            "state": "disabled",
            "ignoreGlobalExternalTrackers": false,
            "includedInForecast": true,
            "exclusive": false,
            "deleted": false,
            "sequenceScope": "session",
            "goals": [
                {
                    "id": "4866d0b3-2686-4fed-a87a-8f419cf5c935",
                    "name": "Ooyala autumn goal",
                    "description": "Sponsor goal",
                    "target": {
                        "value": 100,
                        "unit": "percent"
                    },
                    "start": "2018-08-30T22:00:00Z",
                    "end": "2018-10-31T23:00:00Z",
                    "pricing": {
                        "value": 8,
                        "pricingModel": "cpm"
                    },
                    "ads": [
                        {
                            "id": "a8ba0677-4e9e-4d65-a7ed-e5be2ef2a289",
                            "name": "Sponsor ad",
                            "creative": {
                                "insertionPoint": "preroll",
                                "type": "standardPlaceholder"
                            },
                            "enabled": true,
                            "description": "Sponsor ad",
                            "weight": {
                                "proportional": true,
                                "totalOverridden": 0,
                                "value": 1
                            },
                            "start": {
                                "value": "2018-08-30T22:00:00Z",
                                "origin": {
                                    "id": "4866d0b3-2686-4fed-a87a-8f419cf5c935",
                                    "href": "https://api.videoplaza.com/v3/goals/4866d0b3-2686-4fed-a87a-8f419cf5c935",
                                    "entity": "goal"
                                }
                            },
                            "end": {
                                "value": "2018-10-31T23:00:00Z",
                                "origin": {
                                    "id": "4866d0b3-2686-4fed-a87a-8f419cf5c935",
                                    "href": "https://api.videoplaza.com/v3/goals/4866d0b3-2686-4fed-a87a-8f419cf5c935",
                                    "entity": "goal"
                                }
                            },
                            "externalTrackers": [
                                {
                                    "id": "7d78e034-95da-4773-a109-edae9f4cce60",
                                    "url": "http://tracking.com",
                                    "event": "impression"
                                }
                            ],
                            "deviceContainers": [
                                {
                                    "id": "6b79564c-8a8c-102f-9f01-001e4f3cd645"
                                }
                            ],
                            "created": "2018-07-20T08:41:51Z",
                            "modified": "2018-07-20T08:41:51Z"
                        }
                    ],
                    "type": "shareOfVoice",
                    "deleted": false,
                    "priority": {
                        "value": 5,
                        "origin": {
                            "id": "301af24d-d8bf-4ddf-985a-c94cdf254ebb",
                            "entity": "site"
                        }
                    },
                    "adPosition": "any",
                    "sponsorPlacement": "default",
                    "skipSettings": {
                        "value": {
                            "parentOverride": false
                        }
                    },
                    "frontload": {
                        "value": 30,
                        "origin": {
                            "id": "301af24d-d8bf-4ddf-985a-c94cdf254ebb",
                            "entity": "site"
                        }
                    },
                    "goalMode": "sponsor"
                }
            ],
            "priority": {
                "value": 5,
                "origin": {
                    "id": "301af24d-d8bf-4ddf-985a-c94cdf254ebb",
                    "entity": "site"
                }
            },
            "frontload": {
                "value": 30,
                "origin": {
                    "id": "301af24d-d8bf-4ddf-985a-c94cdf254ebb",
                    "entity": "site"
                }
            },
            "metrics": {
                "impression": 0,
                "complete": 0
            }
        },
        {
            "id": "57e239e6-003d-4c01-804f-695d05fdd5da",
            "name": "Ooyala summer campaign",
            "description": "Ooyala summer 2018 campaign.",
            "customId": "Custom campaign ID",
            "start": "2018-07-19T22:00:00Z",
            "end": "2018-09-15T22:00:00Z",
            "brand": {
                "id": "5fc003be-a09f-4fc6-8d88-a8200b24f70d"
            },
            "agency": {
                "id": "efab6d70-855d-425e-abff-d5edcd36afc1"
            },
            "advertiser": {
                "id": "2c3364bb-5fb6-4bab-b327-ecaddc08a0ae"
            },
            "state": "enabled",
            "ignoreGlobalExternalTrackers": false,
            "includedInForecast": true,
            "exclusive": false,
            "deleted": false,
            "sequenceScope": "session",
            "goals": [
                {
                    "id": "e26d57f8-ba36-422e-8730-8b7e44311d9f",
                    "name": "Ooyala summer goal I/II",
                    "description": "Ooyala summer goal I/II",
                    "target": {
                        "value": 250000,
                        "unit": "impression"
                    },
                    "start": "2018-07-19T22:00:00Z",
                    "end": "2018-08-27T22:00:00Z",
                    "pricing": {
                        "value": 10,
                        "pricingModel": "cpm"
                    },
                    "ads": [
                        {
                            "id": "b15b100d-6c2b-4daf-94c4-7a53ea0da0f7",
                            "name": "Ooyala pre-roll ad",
                            "creative": {
                                "insertionPoint": "preroll",
                                "asset": {
                                    "id": "1a55837f-ed05-4abe-bbfd-3ac098e9bf7d",
                                    "href": "https://api.videoplaza.com/v1/assets/1a55837f-ed05-4abe-bbfd-3ac098e9bf7d"
                                },
                                "clickDestinationUri": "http://ooyala.com",
                                "type": "standard"
                            },
                            "enabled": true,
                            "description": "Ooyala pre-roll ad",
                            "weight": {
                                "proportional": true,
                                "totalOverridden": 0,
                                "value": 1
                            },
                            "customId": "Custom ad ID",
                            "start": {
                                "value": "2018-07-19T22:00:00Z",
                                "origin": {
                                    "id": "e26d57f8-ba36-422e-8730-8b7e44311d9f",
                                    "href": "https://api.videoplaza.com/v3/goals/e26d57f8-ba36-422e-8730-8b7e44311d9f",
                                    "entity": "goal"
                                }
                            },
                            "end": {
                                "value": "2018-08-27T22:00:00Z",
                                "origin": {
                                    "id": "e26d57f8-ba36-422e-8730-8b7e44311d9f",
                                    "href": "https://api.videoplaza.com/v3/goals/e26d57f8-ba36-422e-8730-8b7e44311d9f",
                                    "entity": "goal"
                                }
                            },
                            "externalTrackers": [
                                {
                                    "id": "2a632119-56cf-48dc-bbf8-222c19efc862",
                                    "url": "http://click-tracking.com",
                                    "event": "clickThrough"
                                },
                                {
                                    "id": "51003782-c591-4ebe-9eb5-fad45e862345",
                                    "url": "http://tracking.com",
                                    "event": "impression"
                                }
                            ],
                            "deviceContainers": [
                                {
                                    "id": "27375d12-e3ad-46ce-ad78-eece92928c90"
                                },
                                {
                                    "id": "a6b5b571-c517-4597-861b-24d2d190d642"
                                }
                            ],
                            "created": "2018-07-20T08:29:49Z",
                            "modified": "2018-07-23T15:00:51Z"
                        }
                    ],
                    "type": "impression",
                    "deleted": false,
                    "priority": {
                        "value": 4,
                        "origin": {
                            "id": "57e239e6-003d-4c01-804f-695d05fdd5da",
                            "href": "https://api.videoplaza.com/v3/campaigns/57e239e6-003d-4c01-804f-695d05fdd5da",
                            "entity": "campaign"
                        }
                    },
                    "customId": "Custom goal ID",
                    "adPosition": "any",
                    "goalSequence": {
                        "sequence": 1,
                        "totalAmountOfGoals": 2,
                        "sequenceScope": "lifetime"
                    },
                    "skipSettings": {
                        "value": {
                            "showWhen": "afterFirstUnique",
                            "resetAfter": 12,
                            "skipOffset": {
                                "value": 5,
                                "unit": "seconds"
                            },
                            "parentOverride": true
                        },
                        "origin": {
                            "id": "e26d57f8-ba36-422e-8730-8b7e44311d9f",
                            "href": "https://api.videoplaza.com/v3/goals/e26d57f8-ba36-422e-8730-8b7e44311d9f",
                            "entity": "goal"
                        }
                    },
                    "cap": {
                        "capType": "dailyCap",
                        "capValue": 11000
                    },
                    "frontload": {
                        "value": 30,
                        "origin": {
                            "id": "301af24d-d8bf-4ddf-985a-c94cdf254ebb",
                            "entity": "site"
                        }
                    },
                    "goalMode": "normal"
                },
                {
                    "id": "80028bd7-95d3-4d89-8945-6d0801b5c03e",
                    "name": "Ooyala summer goal II/II",
                    "description": "Ooyala summer goal II/II",
                    "target": {
                        "value": 250000,
                        "unit": "impression"
                    },
                    "start": "2018-08-15T22:00:00Z",
                    "end": "2018-09-15T22:00:00Z",
                    "pricing": {
                        "value": 10,
                        "pricingModel": "cpm"
                    },
                    "ads": [
                        {
                            "id": "e9fc0519-b807-42fe-a101-bd7c65eea957",
                            "name": "Ooyala mid-roll ad",
                            "creative": {
                                "insertionPoint": "midroll",
                                "asset": {
                                    "id": "f24ce53c-f714-4820-9dbf-aa1bc578facb",
                                    "href": "https://api.videoplaza.com/v1/assets/f24ce53c-f714-4820-9dbf-aa1bc578facb"
                                },
                                "clickDestinationUri": "http://ooyala.com",
                                "type": "standard"
                            },
                            "enabled": true,
                            "description": "Ooyala mid-roll ad",
                            "weight": {
                                "proportional": true,
                                "totalOverridden": 0,
                                "value": 1
                            },
                            "customId": "Custom ad ID",
                            "start": {
                                "value": "2018-08-15T22:00:00Z",
                                "origin": {
                                    "id": "80028bd7-95d3-4d89-8945-6d0801b5c03e",
                                    "href": "https://api.videoplaza.com/v3/goals/80028bd7-95d3-4d89-8945-6d0801b5c03e",
                                    "entity": "goal"
                                }
                            },
                            "end": {
                                "value": "2018-09-15T22:00:00Z",
                                "origin": {
                                    "id": "80028bd7-95d3-4d89-8945-6d0801b5c03e",
                                    "href": "https://api.videoplaza.com/v3/goals/80028bd7-95d3-4d89-8945-6d0801b5c03e",
                                    "entity": "goal"
                                }
                            },
                            "externalTrackers": [
                                {
                                    "id": "7c0411b9-ef75-4c09-8ccc-e1108e2b3152",
                                    "url": "http://start-tracking.com",
                                    "event": "start"
                                },
                                {
                                    "id": "a6c6f4d4-55c3-4107-aa32-0029b9c3af50",
                                    "url": "http://pause-tracking.com",
                                    "event": "pause"
                                }
                            ],
                            "deviceContainers": [
                                {
                                    "id": "145299c6-ba02-45de-9995-c2dfaba44c8c"
                                },
                                {
                                    "id": "5aa5bfe0-985c-4144-9ab1-9f723ba81abf"
                                }
                            ],
                            "created": "2018-07-20T08:36:05Z",
                            "modified": "2018-07-20T08:36:05Z"
                        }
                    ],
                    "type": "impression",
                    "deleted": false,
                    "priority": {
                        "value": 4,
                        "origin": {
                            "id": "57e239e6-003d-4c01-804f-695d05fdd5da",
                            "href": "https://api.videoplaza.com/v3/campaigns/57e239e6-003d-4c01-804f-695d05fdd5da",
                            "entity": "campaign"
                        }
                    },
                    "customId": "Custom goal ID",
                    "adPosition": "any",
                    "goalSequence": {
                        "sequence": 2,
                        "totalAmountOfGoals": 2,
                        "sequenceScope": "lifetime"
                    },
                    "skipSettings": {
                        "value": {
                            "showWhen": "afterFirstUnique",
                            "resetAfter": 12,
                            "skipOffset": {
                                "value": 5,
                                "unit": "seconds"
                            },
                            "parentOverride": true
                        },
                        "origin": {
                            "id": "80028bd7-95d3-4d89-8945-6d0801b5c03e",
                            "href": "https://api.videoplaza.com/v3/goals/80028bd7-95d3-4d89-8945-6d0801b5c03e",
                            "entity": "goal"
                        }
                    },
                    "cap": {
                        "capType": "dailyCap",
                        "capValue": 11000
                    },
                    "frontload": {
                        "value": 30,
                        "origin": {
                            "id": "301af24d-d8bf-4ddf-985a-c94cdf254ebb",
                            "entity": "site"
                        }
                    },
                    "goalMode": "normal"
                }
            ],
            "priority": {
                "value": 4,
                "origin": {
                    "id": "57e239e6-003d-4c01-804f-695d05fdd5da",
                    "href": "https://api.videoplaza.com/v3/campaigns/57e239e6-003d-4c01-804f-695d05fdd5da",
                    "entity": "campaign"
                }
            },
            "frontload": {
                "value": 30,
                "origin": {
                    "id": "301af24d-d8bf-4ddf-985a-c94cdf254ebb",
                    "entity": "site"
                }
            },
            "metrics": {
                "impression": 0,
                "complete": 0
            }
        }
    ],
    "pagination": {
        "totalCount": 2,
        "pageSize": 10,
        "pageNumber": 1
    }
}

Query for One Campaign

This endpoint enables you to get one campaign associated with your account. You can expand goals and ads associated with the campaign, which results in a nested structure representing the hierarchy between campaigns, goals, and ads. You can also embed metrics and this way quickly retrieve one, several, or all available metrics for a campaign and its goals and ads, if expanded. If you expand goals associated with the campaign, you can embed projections and this way get information on the projected delivery for the goal at the time of the request. The available query parameters are described in detail in the table below.

Method GET
URL /v3/campaigns/{campaignId}
Header Authentication header (x-o-api-key)
Content type application/json
URL params campaignId: the ID of the campaign
Query params
  • expand: add the parameter to the query string to expand either all the goals associated with the campaign (expand=goals), or all the goals associated with the campaign and all the ads associated with the listed goals (expand=goals&expand=ads). Possible values are:
    • goals
    • ads
    If the parameter is not present, a link to each goal's details is returned.
    "goals": [
                    {
                        "id": "<goal ID>",
                        "href": "https://api.videoplaza.com/v3/goals/<goal ID>"
                    }
                ]
  • embed: add the parameter to the query string to retrieve the metrics available for the campaign and its goals and ads (when expanded), and/or the projected delivery for the campaign goals at the time of the request (when expanded). Possible values are metrics and projections.
    • Add embed=metrics to the query string to retrieve all the available metrics.
    • Add embed=metrics&metrics=<value> to the query string to retrieve one or several specific metrics. Possible values are:
      • impression
      • clickThrough
      • start
      • firstQuartile
      • midpoint
      • thirdQuartile
      • complete
      • delivered (only returned on expanded goal and ad objects)
      • ctr (only returned on expanded goal objects)
      • completionRate (only returned on expanded goal objects)
      • ecpm (only returned on expanded goal objects)
    • Add embed=projections to the query string to retrieve the projected delivery for the goal at the time of the request, provided the goal object is expanded. Projected delivery is only available for goals.
  • includeDeletedGoals: add the parameter to the query string to include all associated, but deleted goals. By default, they are not listed.
Body -
Success response

HTTP status: 200 OK

Header: -

Body: see Response Body Format. The response only contains one campaign object without the pagination element.

Example - No Expanded Objects:

Request header:

GET /v3/campaigns/57e239e6-003d-4c01-804f-695d05fdd5da?embed=metrics HTTP/1.1
Host: api.videoplaza.com
Content-type: application/json
x-o-api-key="<your key>"

Request body: -

Success response:

HTTP status:
  200 (OK)

Body:
{
    "id": "57e239e6-003d-4c01-804f-695d05fdd5da",
    "name": "Ooyala summer campaign",
    "description": "Ooyala summer 2018 campaign.",
    "customId": "Custom campaign ID",
    "start": "2018-07-19T22:00:00Z",
    "end": "2018-09-15T22:00:00Z",
    "brand": {
        "id": "5fc003be-a09f-4fc6-8d88-a8200b24f70d"
    },
    "agency": {
        "id": "efab6d70-855d-425e-abff-d5edcd36afc1"
    },
    "advertiser": {
        "id": "2c3364bb-5fb6-4bab-b327-ecaddc08a0ae"
    },
    "state": "enabled",
    "ignoreGlobalExternalTrackers": false,
    "includedInForecast": true,
    "exclusive": false,
    "deleted": false,
    "sequenceScope": "session",
    "goals": [
        {
            "id": "e26d57f8-ba36-422e-8730-8b7e44311d9f",
            "href": "https://api.videoplaza.com/v3/goals/e26d57f8-ba36-422e-8730-8b7e44311d9f"
        },
        {
            "id": "80028bd7-95d3-4d89-8945-6d0801b5c03e",
            "href": "https://api.videoplaza.com/v3/goals/80028bd7-95d3-4d89-8945-6d0801b5c03e"
        }
    ],
    "priority": {
        "value": 4,
        "origin": {
            "id": "57e239e6-003d-4c01-804f-695d05fdd5da",
            "href": "https://api.videoplaza.com/v3/campaigns/57e239e6-003d-4c01-804f-695d05fdd5da",
            "entity": "campaign"
        }
    },
    "frontload": {
        "value": 30,
        "origin": {
            "id": "301af24d-d8bf-4ddf-985a-c94cdf254ebb",
            "entity": "site"
        }
    },
    "metrics": {
        "impression": 0,
        "clickThrough": 0,
        "start": 0,
        "firstQuartile": 0,
        "midpoint": 0,
        "thirdQuartile": 0,
        "complete": 0
    }
}

Example - Expanded Objects:

Request header:

GET /v3/campaigns/57e239e6-003d-4c01-804f-695d05fdd5da?expand=goals&expand=ads&embed=metrics&embed=projections HTTP/1.1
Host: api.videoplaza.com
Content-type: application/json
x-o-api-key="<your key>"

Request body: -

Success response:

HTTP status:
  200 (OK)

Body:
{
    "id": "57e239e6-003d-4c01-804f-695d05fdd5da",
    "name": "Ooyala summer campaign",
    "description": "Ooyala summer 2018 campaign.",
    "customId": "Custom campaign ID",
    "start": "2018-07-19T22:00:00Z",
    "end": "2018-09-15T22:00:00Z",
    "brand": {
        "id": "5fc003be-a09f-4fc6-8d88-a8200b24f70d"
    },
    "agency": {
        "id": "efab6d70-855d-425e-abff-d5edcd36afc1"
    },
    "advertiser": {
        "id": "2c3364bb-5fb6-4bab-b327-ecaddc08a0ae"
    },
    "state": "enabled",
    "ignoreGlobalExternalTrackers": false,
    "includedInForecast": true,
    "exclusive": false,
    "deleted": false,
    "sequenceScope": "session",
    "goals": [
        {
            "id": "e26d57f8-ba36-422e-8730-8b7e44311d9f",
            "name": "Ooyala summer goal I/II",
            "description": "Ooyala summer goal I/II",
            "target": {
                "value": 250000,
                "unit": "impression"
            },
            "start": "2018-07-19T22:00:00Z",
            "end": "2018-08-27T22:00:00Z",
            "pricing": {
                "value": 10,
                "pricingModel": "cpm"
            },
            "ads": [
                {
                    "id": "b15b100d-6c2b-4daf-94c4-7a53ea0da0f7",
                    "name": "Ooyala pre-roll ad",
                    "creative": {
                        "insertionPoint": "preroll",
                        "asset": {
                            "id": "1a55837f-ed05-4abe-bbfd-3ac098e9bf7d",
                            "href": "https://api.videoplaza.com/v1/assets/1a55837f-ed05-4abe-bbfd-3ac098e9bf7d"
                        },
                        "clickDestinationUri": "http://ooyala.com",
                        "type": "standard"
                    },
                    "enabled": true,
                    "metrics": {
                        "impression": 0,
                        "clickThrough": 0,
                        "start": 0,
                        "firstQuartile": 0,
                        "midpoint": 0,
                        "thirdQuartile": 0,
                        "complete": 0,
                        "delivered": 0
                    },
                    "description": "Ooyala pre-roll ad",
                    "weight": {
                        "proportional": true,
                        "totalOverridden": 0,
                        "value": 1
                    },
                    "customId": "Custom ad ID",
                    "start": {
                        "value": "2018-07-19T22:00:00Z",
                        "origin": {
                            "id": "e26d57f8-ba36-422e-8730-8b7e44311d9f",
                            "href": "https://api.videoplaza.com/v3/goals/e26d57f8-ba36-422e-8730-8b7e44311d9f",
                            "entity": "goal"
                        }
                    },
                    "end": {
                        "value": "2018-08-27T22:00:00Z",
                        "origin": {
                            "id": "e26d57f8-ba36-422e-8730-8b7e44311d9f",
                            "href": "https://api.videoplaza.com/v3/goals/e26d57f8-ba36-422e-8730-8b7e44311d9f",
                            "entity": "goal"
                        }
                    },
                    "externalTrackers": [
                        {
                            "id": "2a632119-56cf-48dc-bbf8-222c19efc862",
                            "url": "http://click-tracking.com",
                            "event": "clickThrough"
                        },
                        {
                            "id": "51003782-c591-4ebe-9eb5-fad45e862345",
                            "url": "http://tracking.com",
                            "event": "impression"
                        }
                    ],
                    "deviceContainers": [
                        {
                            "id": "27375d12-e3ad-46ce-ad78-eece92928c90"
                        },
                        {
                            "id": "a6b5b571-c517-4597-861b-24d2d190d642"
                        }
                    ],
                    "created": "2018-07-20T08:29:49Z",
                    "modified": "2018-07-23T15:00:51Z"
                }
            ],
            "type": "impression",
            "deleted": false,
            "priority": {
                "value": 4,
                "origin": {
                    "id": "57e239e6-003d-4c01-804f-695d05fdd5da",
                    "href": "https://api.videoplaza.com/v3/campaigns/57e239e6-003d-4c01-804f-695d05fdd5da",
                    "entity": "campaign"
                }
            },
            "metrics": {
                "impression": 0,
                "clickThrough": 0,
                "start": 0,
                "firstQuartile": 0,
                "midpoint": 0,
                "thirdQuartile": 0,
                "complete": 0,
                "delivered": 0,
                "ctr": 0,
                "completionRate": 0,
                "ecpm": 10
            },
            "customId": "Custom goal ID",
            "adPosition": "any",
            "goalSequence": {
                "sequence": 1,
                "totalAmountOfGoals": 2,
                "sequenceScope": "lifetime"
            },
            "projectedDelivery": 0,
            "skipSettings": {
                "value": {
                    "showWhen": "afterFirstUnique",
                    "resetAfter": 12,
                    "skipOffset": {
                        "value": 5,
                        "unit": "seconds"
                    },
                    "parentOverride": true
                },
                "origin": {
                    "id": "e26d57f8-ba36-422e-8730-8b7e44311d9f",
                    "href": "https://api.videoplaza.com/v3/goals/e26d57f8-ba36-422e-8730-8b7e44311d9f",
                    "entity": "goal"
                }
            },
            "cap": {
                "capType": "dailyCap",
                "capValue": 11000
            },
            "frontload": {
                "value": 30,
                "origin": {
                    "id": "301af24d-d8bf-4ddf-985a-c94cdf254ebb",
                    "entity": "site"
                }
            },
            "goalMode": "normal"
        },
        {
            "id": "80028bd7-95d3-4d89-8945-6d0801b5c03e",
            "name": "Ooyala summer goal II/II",
            "description": "Ooyala summer goal II/II",
            "target": {
                "value": 250000,
                "unit": "impression"
            },
            "start": "2018-08-15T22:00:00Z",
            "end": "2018-09-15T22:00:00Z",
            "pricing": {
                "value": 10,
                "pricingModel": "cpm"
            },
            "ads": [
                {
                    "id": "e9fc0519-b807-42fe-a101-bd7c65eea957",
                    "name": "Ooyala mid-roll ad",
                    "creative": {
                        "insertionPoint": "midroll",
                        "asset": {
                            "id": "f24ce53c-f714-4820-9dbf-aa1bc578facb",
                            "href": "https://api.videoplaza.com/v1/assets/f24ce53c-f714-4820-9dbf-aa1bc578facb"
                        },
                        "clickDestinationUri": "http://ooyala.com",
                        "type": "standard"
                    },
                    "enabled": true,
                    "metrics": {
                        "impression": 0,
                        "clickThrough": 0,
                        "start": 0,
                        "firstQuartile": 0,
                        "midpoint": 0,
                        "thirdQuartile": 0,
                        "complete": 0,
                        "delivered": 0
                    },
                    "description": "Ooyala mid-roll ad",
                    "weight": {
                        "proportional": true,
                        "totalOverridden": 0,
                        "value": 1
                    },
                    "customId": "Custom ad ID",
                    "start": {
                        "value": "2018-08-15T22:00:00Z",
                        "origin": {
                            "id": "80028bd7-95d3-4d89-8945-6d0801b5c03e",
                            "href": "https://api.videoplaza.com/v3/goals/80028bd7-95d3-4d89-8945-6d0801b5c03e",
                            "entity": "goal"
                        }
                    },
                    "end": {
                        "value": "2018-09-15T22:00:00Z",
                        "origin": {
                            "id": "80028bd7-95d3-4d89-8945-6d0801b5c03e",
                            "href": "https://api.videoplaza.com/v3/goals/80028bd7-95d3-4d89-8945-6d0801b5c03e",
                            "entity": "goal"
                        }
                    },
                    "externalTrackers": [
                        {
                            "id": "7c0411b9-ef75-4c09-8ccc-e1108e2b3152",
                            "url": "http://start-tracking.com",
                            "event": "start"
                        },
                        {
                            "id": "a6c6f4d4-55c3-4107-aa32-0029b9c3af50",
                            "url": "http://pause-tracking.com",
                            "event": "pause"
                        }
                    ],
                    "deviceContainers": [
                        {
                            "id": "145299c6-ba02-45de-9995-c2dfaba44c8c"
                        },
                        {
                            "id": "5aa5bfe0-985c-4144-9ab1-9f723ba81abf"
                        }
                    ],
                    "created": "2018-07-20T08:36:05Z",
                    "modified": "2018-07-20T08:36:05Z"
                }
            ],
            "type": "impression",
            "deleted": false,
            "priority": {
                "value": 4,
                "origin": {
                    "id": "57e239e6-003d-4c01-804f-695d05fdd5da",
                    "href": "https://api.videoplaza.com/v3/campaigns/57e239e6-003d-4c01-804f-695d05fdd5da",
                    "entity": "campaign"
                }
            },
            "metrics": {
                "impression": 0,
                "clickThrough": 0,
                "start": 0,
                "firstQuartile": 0,
                "midpoint": 0,
                "thirdQuartile": 0,
                "complete": 0,
                "delivered": 0,
                "ctr": 0,
                "completionRate": 0,
                "ecpm": 10
            },
            "customId": "Custom goal ID",
            "adPosition": "any",
            "goalSequence": {
                "sequence": 2,
                "totalAmountOfGoals": 2,
                "sequenceScope": "lifetime"
            },
            "projectedDelivery": 0,
            "skipSettings": {
                "value": {
                    "showWhen": "afterFirstUnique",
                    "resetAfter": 12,
                    "skipOffset": {
                        "value": 5,
                        "unit": "seconds"
                    },
                    "parentOverride": true
                },
                "origin": {
                    "id": "80028bd7-95d3-4d89-8945-6d0801b5c03e",
                    "href": "https://api.videoplaza.com/v3/goals/80028bd7-95d3-4d89-8945-6d0801b5c03e",
                    "entity": "goal"
                }
            },
            "cap": {
                "capType": "dailyCap",
                "capValue": 11000
            },
            "frontload": {
                "value": 30,
                "origin": {
                    "id": "301af24d-d8bf-4ddf-985a-c94cdf254ebb",
                    "entity": "site"
                }
            },
            "goalMode": "normal"
        }
    ],
    "priority": {
        "value": 4,
        "origin": {
            "id": "57e239e6-003d-4c01-804f-695d05fdd5da",
            "href": "https://api.videoplaza.com/v3/campaigns/57e239e6-003d-4c01-804f-695d05fdd5da",
            "entity": "campaign"
        }
    },
    "frontload": {
        "value": 30,
        "origin": {
            "id": "301af24d-d8bf-4ddf-985a-c94cdf254ebb",
            "entity": "site"
        }
    },
    "metrics": {
        "impression": 0,
        "clickThrough": 0,
        "start": 0,
        "firstQuartile": 0,
        "midpoint": 0,
        "thirdQuartile": 0,
        "complete": 0
    }
}
https://help.ooyala.com/sites/all/libraries/dita/en/video-advertising/oadtech/ad_serving/dg/rest_campaign_query.html

Was this article helpful?