---
updatedAt: 2025-03-20T20:41:40.000Z
agentTools:
  projectIndex: https://developer.sovrn.com/llms.txt
---

# Getting Started

<HTMLBlock>{`
<body class="container">
  <header class="header">
    <h2 class="h2">Advertising Reporting API Documentation</h2>
    <div class="border"></div>
  </header>
  <section>
    <article class="article">
      <h3>Initial Setup</h3>
      <p>
        Before you begin using the Sovrn Advertising API you will need to <a href="https://platform.sovrn.com/account/api-keys" target="_blank">create an API Key</a> on your account where you will be provided with your Publisher ID and the API Key value. The API Key is used for <a href="https://developer.sovrn.com/reference/authorization-1">authorization</a> to give access to your account’s data. The following sections will provide you with more information about the Reporting API.
      </p>
    </article>
    <div class="divider">
      ⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼
    </div>
    <article class="article">
      <h3>Data Retention</h3>
      <p>The data in the Reporting API is broken up into three levels of aggregation, with different retention periods:</p>
      <ul>
        <li>Hourly (10 days)</li>
        <li>Daily (2 years)</li>
        <li>Monthly (indefinite)</li>
      </ul>
      <p>
        However, as some of the data provided is new, we are unable to backfill to fill up the retention periods. Data will be available starting from 10/01/2021.
        The <b>Daily</b> and <b>Monthly</b> aggregations are only available in UTC.
      </p>
    </article>
    <div class="divider">
      ⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼
    </div>
    <article class="article">
      <h3>API Endpoints</h3>
      <h4 class="h4">Account Level Reporting</h4>
      <p>
        For account level information, replace the <b>:publisherId</b> with your publisher ID.
      </p>
      <ul>
        <li><a class="link" href="https://api.sovrn.com/reporting/advertising/publishers/:publisherId/account">https://api.sovrn.com/reporting/advertising/publishers/:publisherId/account</a></li>
        <li><a class="link" href="https://api.sovrn.com/reporting/advertising/publishers/:publisherId/bid"> https://api.sovrn.com/reporting/advertising/publishers/:publisherId/bid</a></li>
        <li><a class="link" href="https://api.sovrn.com/reporting/advertising/publishers/:publisherId/breakout">https://api.sovrn.com/reporting/advertising/publishers/:publisherId/breakout</a></li>
      </ul>
		  <h4 class="h4">Domain Level Reporting</h4>
      <p>
        For Domain level information,  replace the <b>:publisherId</b> with your publisher ID and the <b>:domainName</b> with the domain you are wanting reports from.
      </p>
      <ul>
        <li><a class="link" href="https://api.sovrn.com/reporting/advertising/publishers/:publisherId/domains/:domainName/account">https://api.sovrn.com/reporting/advertising/publishers/:publisherId/domains/:domainName/account</a></li>
        <li><a class="link" href="https://api.sovrn.com/reporting/advertising/publishers/:publisherId/domains/:domainName/bid">https://api.sovrn.com/reporting/advertising/publishers/:publisherId/domains/:domainName/bid</a></li>
      </ul>
    </article>
    <div class="divider">
      ⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼
    </div>
     <article class="article">
      <h3>How to Provide the API Key to Pass Authentication</h3>
      <p>
        The API Key is provided as part of the request header, as a key/value pair (find detailed instructions <a class="link" href="https://developer.sovrn.com/docs/sovrn-advertising-reporting-api">here</a>). 
The header name is ‘x-api-key’ and the value is the API Key that you have received. It will be a 7 character sequence followed by a ‘.’ and then a 32 character UUID. It will look like the following:
      </p>
      <div class="code_block">
        <code>
          1234567.a34d7eb0-abfc-44fea-9fcc-7es42be45663
        </code>
      </div>
    </article>
    <div class="divider">
      ⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼
    </div>
    <article class="article">
      <h3>Example Request</h3>
      <p>
        Below is an example CURL request that you can run to verify everything
        is working correctly:
      </p>
      <div class="code_block">
        <code>
          curl --request GET \ --url
          'https://api.sovrn.com/reporting/advertising/publishers/262681/domains/sovrntest.com/account?start=2021-08-01T00%3A00%3A00Z&end=2021-09-02T00%3A00%3A00Z&metrics=publisherRevenue&dimensions=domain%2CzoneId'
          \ --header 'x-api-key: prefix1.XXXXXXXX-YYYY-ZZZZ-AAAA-BBBBBBBBBBBB'
        </code>
      </div>
    </article>
    <div class="divider">
      ⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼
    </div>
     <article class="article">
      <h3>Rate Limit Quotas</h3>
      <h4 class="h4">How to View Response Header Information About Rate Limiting</h4>
      <p>
        A Publisher can make up to 15 requests every 1 minute, based on API key. If you go over that number you will receive an error, with a message telling you you have gone over the amount.
      </p>
      <p>
          In addition, we are limiting overall requests per IP address to 2000 requests every 5 minutes. 
      </p>
    </article>
    <div class="divider">
      ⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼
    </div>
     <article class="article">
      <h3>Contact</h3>
      <p>
        If you have any questions or feedback about this documentation and the Advertising Reporting API, please <a class="link" href="https://knowledge.sovrn.com/contact-us" target="_blank">contact support</a>.
      </p>
    </article>   
  </section>
</body>

<style>
  .container {
    margin: 16px 32px;
    font-family: Arial, Helvetica, sans-serif;
  }
  .header {
    padding-bottom: 16px
  }
  .h2 {
    font-weight: bolder;
  }
  .h4 {
    color: #A9A9A9 !important;
  }
  .border {
    border-bottom: 8px solid rgb(255, 212, 43);
    width: 10%;
  }
  .article {
    width: 100%;
  }
  .divider {
    color: rgb(255, 212, 43);
  }
  .code_block {
    border: 1px solid #000;
    padding: 16px;
  }
  .example {
    background-color: #e0e0e0;
    width: max-content;
  }
  .link {
    color: rgb(60, 76, 252);
    text-decoration: underline rgba(60, 76, 252, 0.4);
  }
  a.link:hover  {
    color: rgb(60, 76, 252) !important;
    text-decoration: underline rgba(60, 76, 252, 0.4) !important;
  }
</style>
`}</HTMLBlock>