---
title: /v2/publishers/{publisherId}/reports/spa/ad-groups
slug: campaign-reporting-apis/v2publisherspublisheridreportsspaad-groups
docTags: 
createdAt: 2026-03-25T10:57:30.256Z
---

{
  "id": "Y3AyUmlCAAr4oW0hVz3nw",
  "type": "api-oas-v2",
  "data": {
    "method": "GET",
    "url": "https://<pcm-domain>/v2/publishers/{publisherId}/reports/spa/ad-groups",
    "servers": [
      {
        "url": "https://<pcm-domain>/v2/publishers/{publisherId}/reports/spa/ad-groups",
        "description": "Generated server url"
      }
    ],
    "name": "",
    "description": "<p>Retrieves a paginated ad-group performance report for the publisher specified by id. Both the startDate\nand endDate are inclusive.</p>",
    "contentType": "application/json",
    "request": {
      "pathParameters": [
        {
          "kind": "required",
          "name": "publisherId",
          "type": "integer<int32>",
          "description": "",
          "format": "int32"
        }
      ],
      "headerParameters": [],
      "queryParameters": [
        {
          "kind": "required",
          "name": "orderBy",
          "type": "string",
          "description": "",
          "enum": [
            "ADVERTISER_ID",
            "ADVERTISER_NAME",
            "AD_GROUP_ID",
            "AD_GROUP_NAME",
            "DATE"
          ]
        },
        {
          "kind": "optional",
          "name": "sortType",
          "type": "string",
          "description": "",
          "enum": [
            "ASC",
            "DESC"
          ]
        },
        {
          "kind": "optional",
          "name": "dateBreakdown",
          "type": "boolean",
          "description": "<p>\"Sorting by date along with 'dateBreakdown = false' will result in 422 error</p>"
        },
        {
          "kind": "required",
          "name": "startAt",
          "type": "string<date>",
          "description": "<p>The start date in the UTC timezone. Format for date: YYYY-MM-DD</p>",
          "format": "date"
        },
        {
          "kind": "required",
          "name": "endAt",
          "type": "string<date>",
          "description": "<p>The end date in the UTC timezone. Format for date: YYYY-MM-DD</p>",
          "format": "date"
        },
        {
          "kind": "required",
          "name": "page",
          "type": "integer<int32>",
          "description": "",
          "format": "int32",
          "minimum": 0,
          "maximum": 1000
        },
        {
          "kind": "required",
          "name": "limit",
          "type": "integer<int32>",
          "description": "",
          "format": "int32",
          "minimum": 100,
          "maximum": 10000
        }
      ],
      "bodyDataParameters": [],
      "formDataParameters": [],
      "oAuthParameters": []
    },
    "responses": [
      {
        "statusCode": "200",
        "description": "OK",
        "jsonExample": "",
        "isExpanded": true,
        "schema": [
          {
            "kind": "optional",
            "type": "object",
            "description": "",
            "customType": "ExternalV2PublisherAdGroupReport",
            "schema": [
              {
                "name": "detailed",
                "kind": "optional",
                "type": "array",
                "description": "",
                "modelRef": "#/components/schemas/V2PublisherSpaAdGroupReportRow",
                "customType": "V2PublisherSpaAdGroupReportRow[]",
                "schema": [
                  {
                    "name": "impressions",
                    "kind": "optional",
                    "type": "integer<int64>",
                    "description": "",
                    "example": 0,
                    "format": "int64"
                  },
                  {
                    "name": "clicks",
                    "kind": "optional",
                    "type": "integer<int64>",
                    "description": "",
                    "example": 0,
                    "format": "int64"
                  },
                  {
                    "name": "conversions",
                    "kind": "optional",
                    "type": "integer<int64>",
                    "description": "",
                    "example": 0,
                    "format": "int64"
                  },
                  {
                    "name": "unitsSold",
                    "kind": "optional",
                    "type": "integer<int64>",
                    "description": "",
                    "example": 0,
                    "format": "int64"
                  },
                  {
                    "name": "clickThroughRate",
                    "kind": "optional",
                    "type": "number<double>",
                    "description": "",
                    "example": "",
                    "format": "double"
                  },
                  {
                    "name": "conversionRate",
                    "kind": "optional",
                    "type": "number<double>",
                    "description": "",
                    "example": "",
                    "format": "double"
                  },
                  {
                    "name": "conversionValue",
                    "kind": "optional",
                    "type": "number<double>",
                    "description": "",
                    "example": "",
                    "format": "double"
                  },
                  {
                    "name": "costPerClick",
                    "kind": "optional",
                    "type": "number<double>",
                    "description": "",
                    "example": "",
                    "format": "double"
                  },
                  {
                    "name": "returnOnAdSpend",
                    "kind": "optional",
                    "type": "number<double>",
                    "description": "",
                    "example": "",
                    "format": "double"
                  },
                  {
                    "name": "adSpendRevenue",
                    "kind": "optional",
                    "type": "number<double>",
                    "description": "",
                    "example": "",
                    "format": "double"
                  },
                  {
                    "name": "loads",
                    "kind": "optional",
                    "type": "integer<int64>",
                    "description": "",
                    "example": 0,
                    "format": "int64"
                  },
                  {
                    "name": "advertiserId",
                    "kind": "optional",
                    "type": "string",
                    "description": "",
                    "example": ""
                  },
                  {
                    "name": "advertiserName",
                    "kind": "optional",
                    "type": "string",
                    "description": "",
                    "example": ""
                  },
                  {
                    "name": "adGroupId",
                    "kind": "optional",
                    "type": "string",
                    "description": "",
                    "example": ""
                  },
                  {
                    "name": "adGroupName",
                    "kind": "optional",
                    "type": "string",
                    "description": "",
                    "example": ""
                  },
                  {
                    "name": "date",
                    "kind": "optional",
                    "type": "string",
                    "description": "",
                    "example": ""
                  }
                ]
              },
              {
                "name": "aggregated",
                "kind": "optional",
                "type": "object",
                "description": "",
                "modelRef": "#/components/schemas/AggregatedV2SpaReportRow",
                "customType": "AggregatedV2SpaReportRow",
                "schema": [
                  {
                    "name": "count",
                    "kind": "optional",
                    "type": "integer<int64>",
                    "description": "",
                    "example": 0,
                    "format": "int64"
                  },
                  {
                    "name": "metrics",
                    "kind": "optional",
                    "type": "object",
                    "description": "",
                    "modelRef": "#/components/schemas/V2SpaReportRow",
                    "customType": "V2SpaReportRow",
                    "schema": [
                      {
                        "name": "impressions",
                        "kind": "optional",
                        "type": "integer<int64>",
                        "description": "",
                        "example": 0,
                        "format": "int64"
                      },
                      {
                        "name": "clicks",
                        "kind": "optional",
                        "type": "integer<int64>",
                        "description": "",
                        "example": 0,
                        "format": "int64"
                      },
                      {
                        "name": "conversions",
                        "kind": "optional",
                        "type": "integer<int64>",
                        "description": "",
                        "example": 0,
                        "format": "int64"
                      },
                      {
                        "name": "unitsSold",
                        "kind": "optional",
                        "type": "integer<int64>",
                        "description": "",
                        "example": 0,
                        "format": "int64"
                      },
                      {
                        "name": "clickThroughRate",
                        "kind": "optional",
                        "type": "number<double>",
                        "description": "",
                        "example": "",
                        "format": "double"
                      },
                      {
                        "name": "conversionRate",
                        "kind": "optional",
                        "type": "number<double>",
                        "description": "",
                        "example": "",
                        "format": "double"
                      },
                      {
                        "name": "conversionValue",
                        "kind": "optional",
                        "type": "number<double>",
                        "description": "",
                        "example": "",
                        "format": "double"
                      },
                      {
                        "name": "costPerClick",
                        "kind": "optional",
                        "type": "number<double>",
                        "description": "",
                        "example": "",
                        "format": "double"
                      },
                      {
                        "name": "returnOnAdSpend",
                        "kind": "optional",
                        "type": "number<double>",
                        "description": "",
                        "example": "",
                        "format": "double"
                      },
                      {
                        "name": "adSpendRevenue",
                        "kind": "optional",
                        "type": "number<double>",
                        "description": "",
                        "example": "",
                        "format": "double"
                      },
                      {
                        "name": "loads",
                        "kind": "optional",
                        "type": "integer<int64>",
                        "description": "",
                        "example": 0,
                        "format": "int64"
                      }
                    ]
                  }
                ]
              }
            ],
            "modelRef": "#/components/schemas/ExternalV2PublisherAdGroupReport",
            "isExpanded": true
          }
        ]
      },
      {
        "statusCode": "401",
        "description": "Unauthorized",
        "jsonExample": "",
        "isExpanded": true
      },
      {
        "statusCode": "403",
        "description": "Forbidden",
        "jsonExample": "",
        "isExpanded": true
      },
      {
        "statusCode": "404",
        "description": "Not Found",
        "jsonExample": "",
        "isExpanded": true,
        "schema": [
          {
            "kind": "optional",
            "type": "object",
            "description": "",
            "customType": "ExceptionResponse",
            "schema": [
              {
                "name": "messages",
                "kind": "optional",
                "type": "array",
                "description": "",
                "example": "",
                "itemType": "string",
                "customType": "string[]",
                "itemExample": "",
                "itemDefault": ""
              }
            ],
            "modelRef": "#/components/schemas/ExceptionResponse",
            "isExpanded": true
          }
        ]
      }
    ],
    "hasXCodeSamples": false,
    "examples": {
      "languages": [
        {
          "id": "BQCt7VkZ7HeCNlNqeB5Cu",
          "language": "curl",
          "label": "cURL",
          "code": "curl --request GET \\\n     --url 'https://<pcm-domain>/v2/publishers/{publisherId}/reports/spa/ad-groups?orderBy=ADVERTISER_ID&startAt=string%3Cdate%3E&endAt=string%3Cdate%3E&page=integer%3Cint32%3E&limit=integer%3Cint32%3E' \\\n     --header 'accept: application/json'"
        },
        {
          "id": "8CzeygV5Szq9TKK8SeO7I",
          "language": "javascript",
          "label": "javascript",
          "code": "var myHeaders = new Headers();\nmyHeaders.append(\"accept\", \"application/json\");\nmyHeaders.append(\"content-type\", \"application/json\");\n\nvar requestOptions = {\n   method: 'GET',\n   headers: myHeaders,\n   redirect: 'follow'\n};\n\nfetch(\"https://<pcm-domain>/v2/publishers/{publisherId}/reports/spa/ad-groups?orderBy=ADVERTISER_ID&startAt=string<date>&endAt=string<date>&page=integer<int32>&limit=integer<int32>\", requestOptions)\n   .then(response => response.text())\n   .then(result => console.log(result))\n   .catch(error => console.log('error', error));"
        },
        {
          "id": "_tqtprKiJBqYhNpuYxvYB",
          "language": "ruby",
          "label": "Ruby",
          "code": "require \"uri\"\nrequire \"json\"\nrequire \"net/http\"\n\nurl = URI(\"https://<pcm-domain>/v2/publishers/{publisherId}/reports/spa/ad-groups?orderBy=ADVERTISER_ID&startAt=string<date>&endAt=string<date>&page=integer<int32>&limit=integer<int32>\")\n\nhttps = Net::HTTP.new(url.host, url.port)\nhttps.use_ssl = true\n\nrequest = Net::HTTP::Get.new(url)\nrequest[\"accept\"] = \"application/json\"\nrequest[\"content-type\"] = \"application/json\"\n\nresponse = https.request(request)\nputs response.read_body\n"
        },
        {
          "id": "93gevD6faaRvKDtLAdDjO",
          "language": "python",
          "label": "Python",
          "code": "import requests\nimport json\n\nurl = \"https://<pcm-domain>/v2/publishers/{publisherId}/reports/spa/ad-groups?orderBy=ADVERTISER_ID&startAt=string<date>&endAt=string<date>&page=integer<int32>&limit=integer<int32>\"\n\npayload = {}\nheaders = {\n   'accept': 'application/json',\n   'content-type': 'application/json'\n}\n\nresponse = requests.request(\"GET\", url, headers=headers, data=payload)\n\nprint(response.text)\n"
        }
      ],
      "selectedLanguageId": "BQCt7VkZ7HeCNlNqeB5Cu"
    },
    "results": {
      "languages": [
        {
          "id": "npKrQHCm30P4t__hy4LoP",
          "language": "200",
          "code": "// OK\n{\n  \"detailed\": [\n    {\n      \"impressions\": \"\",\n      \"clicks\": \"\",\n      \"conversions\": \"\",\n      \"unitsSold\": \"\",\n      \"clickThroughRate\": \"\",\n      \"conversionRate\": \"\",\n      \"conversionValue\": \"\",\n      \"costPerClick\": \"\",\n      \"returnOnAdSpend\": \"\",\n      \"adSpendRevenue\": \"\",\n      \"loads\": \"\",\n      \"advertiserId\": \"\",\n      \"advertiserName\": \"\",\n      \"adGroupId\": \"\",\n      \"adGroupName\": \"\",\n      \"date\": \"\"\n    }\n  ],\n  \"aggregated\": {\n    \"count\": \"\",\n    \"metrics\": {\n      \"impressions\": \"\",\n      \"clicks\": \"\",\n      \"conversions\": \"\",\n      \"unitsSold\": \"\",\n      \"clickThroughRate\": \"\",\n      \"conversionRate\": \"\",\n      \"conversionValue\": \"\",\n      \"costPerClick\": \"\",\n      \"returnOnAdSpend\": \"\",\n      \"adSpendRevenue\": \"\",\n      \"loads\": \"\"\n    }\n  }\n}"
        },
        {
          "id": "muiV1reMiGZzHck4C5GTu",
          "language": "401",
          "code": "// Unauthorized\n"
        },
        {
          "id": "BoY1P8hkrUQU3sZLHL4ru",
          "language": "403",
          "code": "// Forbidden\n"
        },
        {
          "id": "j6pzZrUu2tfgC8eVJzbju",
          "language": "404",
          "code": "// Not Found\n{\n  \"messages\": [\n    \"\"\n  ]\n}"
        }
      ],
      "selectedLanguageId": "npKrQHCm30P4t__hy4LoP"
    }
  },
  "children": [
    {
      "text": ""
    }
  ]
}