NAV Navbar
shell
  • Introduction
  • Authentication
  • Account
  • Organizations
  • Roles
  • Organization Users
  • Sites
  • Site Users
  • Landing Paths
  • Integrations
  • Data
  • Errors
  • Rate Limits
  • Versions
  • Changelog
  • Introduction

    Welcome to the 37x API! You can use our API to automate anything you do manually through the Dashboard

    Authentication

    Getting API Token

    You can see, generate or revoke your API Tokens on https://37x.com/account/api-tokens

    Making a Request

    curl "https://api.37x.com/v1.1/..."
      -H "Authorization: Token 13349a8b-9bcf-4e25-b4f6-86f7a4990b21_b73ce2ec-..." 
    

    You need to provide your API Access Token prefixed with a "Token " string in the Authorization header with each request. See example on the right.

    Account

    Get your Account

    curl "https://api.37x.com/v1.1/me"
      -H "Authorization: Token 08ad3c6d-840b-4d21-aaa2-7c75b2a3fffc..." 
    

    Response:

    {
      "id": "bac8e88d-fc2f-478c-8443-742b2d180a43",
      "email": "[email protected]",
      "name": "Alice",
      "gmtOffset": 0,
      "lastLogin": "2018-01-15T09:56:54.000Z",
      "isEmailValid": true,
      "isArchived": false,
      "createdAt": "2018-01-15T09:56:53.000Z",
      "updatedAt": "2018-01-15T09:59:00.000Z"
    }
    

    Get your User Account JSON

    Update your Account

    curl "https://api.37x.com/v1.1/me"
      -X POST 
      -H "Authorization: Token 08ad3c6d-840b-4d21-aaa2-7c75b2a3fffc..." 
      -H "Content-Type: application/json" 
      -d '{
            "name":"Bob",
            "email": "[email protected]",
            "gmtOffset": -2
          }'
    

    Response:

    {
      "id": "bac8e88d-fc2f-478c-8443-742b2d180a43",
      "email": "[email protected]",
      "name": "Bob",
      "gmtOffset": -2,
      "lastLogin": "2018-01-15T09:56:54.000Z",
      "isEmailValid": false,
      "isArchived": false,
      "createdAt": "2018-01-15T09:56:53.000Z",
      "updatedAt": "2018-01-15T10:59:00.000Z"
    }
    

    Update your account. Currently can change these parameters:

    Parameter Description
    name (Optional) Your Name (must only contain letters)
    gmtOffset (Optional) GMT Offset from Greenwich for Reporting
    email (Optional) Valid email (need to provide your current password when changing this)
    newPassword (Optional) Your new password (need to provide your current password when changing this)
    password (Conditional) Your current password. Provide this if you are changing you password or email.

    Resend Validation Email

    curl "https://api.37x.com/v1.1/me/validation-email"
      -H "Authorization: Token 08ad3c6d-840b-4d21-aaa2-7c75b2a3fffc..." 
    

    Response:

    {
      "status": "New validation Email has been sent out."
    }
    

    Resend the validation email.

    Organizations

    Get all Organizations

    curl "https://api.37x.com/v1.1/organizations"
      -H "Authorization: Token 08ad3c6d-840b-4d21-aaa2-7c75b2a3fffc..." 
    

    Response:

    [
      {
        "id": "50259c4c-c13a-4ec3-8d28-ce2dc6194077",
        "name": "37x",
        "isArchived": false,
        "createdAt": "2018-01-17T15:43:55.000Z",
        "updatedAt": "2018-01-18T13:22:48.000Z",
        "ownerUserId": "12ffe77a-46e2-4745-86a1-0ef8a15cde40",
        "roleId": 4
      },
      {
        "id": "731af1de-b780-4bf6-b84a-96667c5a7f10",
        "name": "My new Organization",
        "isArchived": false,
        "createdAt": "2018-01-17T15:11:30.000Z",
        "updatedAt": "2018-01-17T15:11:30.000Z",
        "ownerUserId": "12ffe77a-46e2-4745-86a1-0ef8a15cde40",
        "roleId": 2
      }
    ]
    

    Get all the organizations user has access too

    Create an Organization

    curl "https://api.37x.com/v1.1/organizations"
      -X POST
      -H "Authorization: Token 08ad3c6d-840b-4d21-aaa2-7c75b2a3fffc..." 
      -H "Content-Type: application/json"
      -d '{
            "name": "37x"
          }'
    

    Response:

    {
      "id": "50259c4c-c13a-4ec3-8d28-ce2dc6194077",
      "name": "37x",
      "isArchived": false,
      "createdAt": "2018-01-17T15:43:55.000Z",
      "updatedAt": "2018-01-18T13:22:48.000Z",
      "ownerUserId": "12ffe77a-46e2-4745-86a1-0ef8a15cde40"
    }
    

    Use this endpoint to create a new Organization.

    Parameter Description
    name Your new organization name (Any character and letter combination)

    Update an Organization

    curl "https://api.37x.com/v1.1/organizations/:organizationId"
      -X POST
      -H "Authorization: Token 08ad3c6d-840b-4d21-aaa2-7c75b2a3fffc..." 
      -H "Content-Type: application/json"
      -d '{
            "name": "My new Organization"
          }'
    

    Response:

    {
      "id": "50259c4c-c13a-4ec3-8d28-ce2dc6194077",
      "name": "My new Organization",
      "isArchived": false,
      "createdAt": "2018-01-17T15:43:55.000Z",
      "updatedAt": "2018-01-18T13:22:48.000Z",
      "ownerUserId": "12ffe77a-46e2-4745-86a1-0ef8a15cde40"
    }
    

    Use this endpoint to update an existing Organization you are an owner of.

    Parameter Description
    name Your organization name (Any character and letter combination)

    Roles

    Get Roles

    curl "https://api.37x.com/v1.1/rbac/roles"
      -H "Authorization: Token 08ad3c6d-840b-4d21-aaa2-7c75b2a3fffc..." 
    

    Response:

    [
        {
            "id": 1,
            "name": "Viewer",
            "permissions": [
                "VIEW_INTEGRATIONS"
            ]
        },
        {
            "id": 2,
            "name": "Editor",
            "permissions": [
                "VIEW_INTEGRATIONS"
            ]
        },
        {
            "id": 3,
            "name": "Admin",
            "permissions": [
                "VIEW_BILLING",
                "INVITE_USERS",
                "UPDATE_USERS",
                "DELETE_USERS",
                "CREATE_SITES",
                "UPDATE_SITES",
                "VIEW_INTEGRATIONS",
                "UPDATE_INTEGRATIONS"
            ]
        },
        {
            "id": 4,
            "name": "Owner",
            "permissions": [
                "UPDATE_ORGANIZATION",
                "VIEW_BILLING",
                "INVITE_USERS",
                "UPDATE_USERS",
                "DELETE_USERS",
                "CREATE_SITES",
                "UPDATE_SITES",
                "VIEW_INTEGRATIONS",
                "UPDATE_INTEGRATIONS"
            ]
        }
    ]
    

    Get all the Roles that are available

    Get Permissions

    curl "https://api.37x.com/v1.1/rbac/permissions"
      -H "Authorization: Token 08ad3c6d-840b-4d21-aaa2-7c75b2a3fffc..." 
    

    Response:

    [
        {
            "id": "UPDATE_ORGANIZATION",
            "name": "Update Organization",
            "description": "Allows changing organization details"
        },
        {
            "id": "ARCHIVE_ORGANIZATION",
            "name": "Archive Organization",
            "description": "Allows archiving an organization"
        },
        {
            "id": "VIEW_BILLING",
            "name": "View Billing",
            "description": "Allows to view organization billing information"
        },
        {
            "id": "INVITE_USERS",
            "name": "Invite Users",
            "description": "Allows to invite users to collaborate on the organization"
        },
        {
            "id": "UPDATE_USERS",
            "name": "Update Users",
            "description": "Allows to update users (roles, site access) on your organization"
        },
        {
            "id": "DELETE_USERS",
            "name": "Delete Users",
            "description": "Allows to delete users from collaborating on the organization"
        },
        {
            "id": "CREATE_SITES",
            "name": "Create Sites",
            "description": "Allows to create sites on this organization"
        },
        {
            "id": "UPDATE_SITES",
            "name": "Update Sites",
            "description": "Allow to update sites on this organization"
        },
        {
            "id": "ARCHIVE_SITES",
            "name": "Archive Sites",
            "description": "Allows archiving of sites"
        },
        {
            "id": "VIEW_INTEGRATIONS",
            "name": "View Integrations",
            "description": "Allows to view site integrations on this organization"
        },
        {
            "id": "UPDATE_INTEGRATIONS",
            "name": "Update Integrations",
            "description": "Allows to update site integrations on this organization"
        },
        {
            "id": "TRANSFER_OWNERSHIP",
            "name": "Transfer Ownership",
            "description": "Allows to transfer organization ownership to another user"
        }
    ]
    

    Get all the Permissions that are available

    Get Role Permissions

    curl "https://api.37x.com/v1.1/rbac/roles/:roleId/permissions"
      -H "Authorization: Token 08ad3c6d-840b-4d21-aaa2-7c75b2a3fffc..." 
    

    Response:

    [
        {
            "id": "VIEW_INTEGRATIONS",
            "name": "View Integrations",
            "description": "Allows to view site integrations on this organization"
        }
    ]
    

    Get specifig Role Permissions

    Organization Users

    Get Users

    curl "https://api.37x.com/v1.1/organizations/:organizationId/users"
      -H "Authorization: Token 08ad3c6d-840b-4d21-aaa2-7c75b2a3fffc..." 
    

    Response

    [
        {
            "id": "12ffe77a-46e2-4745-86a1-0ef8a15cde40",
            "email": "[email protected]",
            "name": "Alice",
            "lastLogin": "2018-01-19T14:41:53.000Z",
            "isArchived": false,
            "avatarUrl": null,
            "roleId": 4
        },
        {
            "id": "dbf5e5c6-a53f-4992-b978-d1f47aaea1ee",
            "email": "[email protected]",
            "name": "Bob",
            "lastLogin": "2018-01-19T15:06:59.000Z",
            "isArchived": false,
            "avatarUrl": null,
            "roleId": 3
        }
    ]
    

    Get all Users that participate in this Organization

    Invite User

    curl "https://api.37x.com/v1.1/organizations/:organizationId/users"
      -X POST
      -H "Authorization: Token 08ad3c6d-840b-4d21-aaa2-7c75b2a3fffc..." 
      -H "Content-Type: application/json" 
      -d '{
            "email": "[email protected]",
            "roleId": 2
          }'
    

    Response:

    {
      "status": "Invitation has been sent out."
    }
    

    Use this endpoint to Invite users to participate in your Organization

    Parameter Description
    email Valid email of the User you want to invite (Must not be a part of the organization already)
    roleId Valid Role ID (Must be weaker than the Role of the user inviting)

    Get Invites

    curl "https://api.37x.com/v1.1/organizations/:organizationId/users/invites"
      -H "Authorization: Token 08ad3c6d-840b-4d21-aaa2-7c75b2a3fffc..." 
    

    Response:

    [
        {
            "id": "69bb6329-a552-42dd-975b-d6054cec61c4",
            "email": "[email protected]",
            "createdAt": "2018-01-26T14:44:33.000Z",
            "updatedAt": "2018-01-26T14:44:33.000Z",
            "organizationId": "VPJNfa4GJBT",
            "roleId": 1
        }
    ]
    

    Use this endpoint to get the Invites you sent out to the users that don't have an account with 37x.

    Remove Invite

    curl "https://api.37x.com/v1.1/organizations/:organizationId/users/invites/:inviteId"
      -X DELETE
      -H "Authorization: Token 08ad3c6d-840b-4d21-aaa2-7c75b2a3fffc..." 
    

    Response:

    {
      "status": "Invitation revoked."
    }
    

    Use this endpoint to revoke Invitations you sent out to users that don't have an account with 37x

    Update User

    curl "https://api.37x.com/v1.1/organizations/:organizationId/users/:userId"
      -X POST
      -H "Authorization: Token 08ad3c6d-840b-4d21-aaa2-7c75b2a3fffc..." 
      -H "Content-Type: application/json" 
      -d '{
            "roleId": 1
          }'
    

    Response:

    {
      "id": "bac8e88d-fc2f-478c-8443-742b2d180a43",
      "email": "[email protected]",
      "name": "Bob",
      "gmtOffset": -2,
      "lastLogin": "2018-01-15T09:56:54.000Z",
      "isArchived": false,
      "roleId": 1
    }
    

    Use this endpoint update Users in your Organization

    Parameter Description
    roleId Valid Role ID (Must be weaker than the Role of the user requesting the change)

    Remove User

    curl "https://api.37x.com/v1.1/organizations/:organizationId/users/:userId"
      -X DELETE
      -H "Authorization: Token 08ad3c6d-840b-4d21-aaa2-7c75b2a3fffc..." 
    

    Response:

    {
      "status": "User removed"
    }
    

    Use this endpoint remove a User from an Organization

    Sites

    Get Organization Sites

    curl "https://api.37x.com/v1.1/organizations/:organizationId/sites"
      -H "Authorization: Token 08ad3c6d-840b-4d21-aaa2-7c75b2a3fffc..." 
    

    Response

    [
        {
            "id": "08ad3c6d-840b-4d21-aaa2-7c75b2a3fffc",
            "domain": "37.com",
            "isArchived": false,
            "createdAt": "2018-01-22T11:42:17.000Z",
            "updatedAt": "2018-01-22T14:35:06.000Z",
            "organizationId": "50259c4c-c13a-4ec3-8d28-ce2dc6194077"
        },
        {
            "id": "259c9eed-7d8e-445c-96ee-7a77102d14e2",
            "domain": "example.com",
            "isArchived": false,
            "createdAt": "2018-01-22T11:43:52.000Z",
            "updatedAt": "2018-01-22T11:43:52.000Z",
            "organizationId": "50259c4c-c13a-4ec3-8d28-ce2dc6194077"
        },
        {
            "id": "bcc1c3b6-d564-45eb-a1ec-286242fbe71b",
            "domain": "second.example.com",
            "isArchived": false,
            "createdAt": "2018-01-22T11:44:40.000Z",
            "updatedAt": "2018-01-22T11:44:40.000Z",
            "organizationId": "50259c4c-c13a-4ec3-8d28-ce2dc6194077"
        }
    ]
    

    Get all Sites belonging to an Organization

    Add a new Site

    curl "https://api.37x.com/v1.1/organizations/:organizationId/sites"
      -X POST
      -H "Authorization: Token 08ad3c6d-840b-4d21-aaa2-7c75b2a3fffc..." 
      -H "Content-Type: application/json" 
      -d '{
            "domain": "third.example.com"
          }'
    

    Response:

    {
        "id": "bac8e88d-fc2f-478c-8443-742b2d180a43",
        "domain": "third.example.com",
        "isArchived": false,
        "createdAt": "2018-01-22T11:44:40.000Z",
        "updatedAt": "2018-01-22T11:44:40.000Z",
        "organizationId": "50259c4c-c13a-4ec3-8d28-ce2dc6194077"
    }
    
    Parameter Description
    domain Valid site Domain name. You can pass any url, we will strip away the unnecessary bits.

    Update Site

    curl "https://api.37x.com/v1.1/organizations/:organizationId/sites/:siteId"
      -X POST
      -H "Authorization: Token 08ad3c6d-840b-4d21-aaa2-7c75b2a3fffc..." 
      -H "Content-Type: application/json" 
      -d '{
            "domain": "fourth.example.com"
          }'
    

    Response:

    {
        "id": "bac8e88d-fc2f-478c-8443-742b2d180a43",
        "domain": "fourth.example.com",
        "isArchived": false,
        "createdAt": "2018-01-22T11:44:40.000Z",
        "updatedAt": "2018-01-22T12:44:40.000Z",
        "organizationId": "50259c4c-c13a-4ec3-8d28-ce2dc6194077"
    }
    
    Parameter Description
    domain Valid site Domain name. You can pass any url, we will strip away the unnecessary bits.

    Site Users

    Get Users

    curl "https://api.37x.com/v1.1/organizations/:organizationId/sites/:siteId/users"
      -H "Authorization: Token 08ad3c6d-840b-4d21-aaa2-7c75b2a3fffc..." 
    

    Response

    [
        {
            "id": "12ffe77a-46e2-4745-86a1-0ef8a15cde40",
            "email": "[email protected]",
            "name": "Alice",
            "lastLogin": "2018-01-19T14:41:53.000Z",
            "isArchived": false,
            "avatarUrl": null
        }
    ]
    

    Get all Users that can access this Site

    Add User

    curl "https://api.37x.com/v1.1/organizations/:organizationId/sites/:siteId/users/:userId"
      -X POST
      -H "Authorization: Token 08ad3c6d-840b-4d21-aaa2-7c75b2a3fffc..." 
      -H "Content-Type: application/json"
    

    Response:

    [
        {
            "id": "12ffe77a-46e2-4745-86a1-0ef8a15cde40",
            "email": "[email protected]",
            "name": "Alice",
            "lastLogin": "2018-01-19T14:41:53.000Z",
            "isArchived": false,
            "avatarUrl": null
        },
        {
            "id": "dbf5e5c6-a53f-4992-b978-d1f47aaea1ee",
            "email": "[email protected]",
            "name": "Bob",
            "lastLogin": "2018-01-19T15:06:59.000Z",
            "isArchived": false,
            "avatarUrl": null
        }
    ]
    

    Use this endpoint to give users access to a Site

    Parameter Description
    userId Valid ID of the User you want to add (Must not be a part of the organization already)

    Remove User

    curl "https://api.37x.com/v1.1/organizations/:organizationId/sites/:siteId/users/:userId"
      -X DELETE
      -H "Authorization: Token 08ad3c6d-840b-4d21-aaa2-7c75b2a3fffc..." 
    

    Response:

    [
        {
            "id": "12ffe77a-46e2-4745-86a1-0ef8a15cde40",
            "email": "[email protected]",
            "name": "Alice",
            "lastLogin": "2018-01-19T14:41:53.000Z",
            "isArchived": false,
            "avatarUrl": null
        }
    ]
    

    Use this endpoint to remove users access to the site.

    Parameter Description
    userId Valid ID of the User you want to remove

    Landing Paths

    Get Site Landing Paths

    curl "https://api.37x.com/v1.1/organizations/:organizationId/sites/:siteId/landing-paths"
      -H "Authorization: Token 08ad3c6d-840b-4d21-aaa2-7c75b2a3fffc..." 
    

    Response

    [
        {
            "id": "007cfa0c-f325-4146-bfc1-f3e670b1fecf",
            "landingPath": "/2018/02/21/whatever-happened-winter-olympics-rivals-nancy-kerrigan-tonya-harding/19/",
            "createdAt": "2018-02-22T22:50:40.000Z",
            "updatedAt": "2018-02-22T22:50:40.000Z",
            "siteId": "hJrApexiAfd"
        },
        {
            "id": "0700eb8f-bc36-4c79-b8e0-cb8ace86aaba",
            "landingPath": "/2017/10/03/thought-18-year-old-dog-never-leave-shelter-guy-motorbike-showed-changed-everything/8/",
            "createdAt": "2018-02-20T19:43:43.000Z",
            "updatedAt": "2018-02-20T19:43:43.000Z",
            "siteId": "hJrApexiAfd"
        },
        {
            "id": "0b574d61-1fbe-4e52-970d-a5ba06329a6a",
            "landingPath": "/2017/11/06/22-secrets-producers-love-lucy-hid/9/",
            "createdAt": "2018-02-21T12:29:38.000Z",
            "updatedAt": "2018-02-21T12:29:38.000Z",
            "siteId": "hJrApexiAfd"
        }
    ]
    

    Get the Sites sessions Landing Paths we have recorded.

    Integrations

    Get all Integrations

    curl "https://api.37x.com/v1.1/organizations/:organizationId/sites/:siteId/integrations"
      -H "Authorization: Token 08ad3c6d-840b-4d21-aaa2-7c75b2a3fffc..." 
    

    Response:

    [
        {
            "id": "amazon-a9",
            "name": "Amazon A9",
            "shortName": "A9",
            "guidelinesUrl": "",
            "thumbnailUrl": "https://static.37x.com/logos/pngs/amazon-a9.png",
            "smallThumbnailUrl": "https://static.37x.com/logos/pngs/amazon-a9-small.png",
            "description": "Collect realtime revenue statistics for Amazon A9 Ad Network",
            "category": "adserver-analytics",
            "type": "selling",
            "authType": "oauth2",
            "isConfigValid": true,
            "isAuthorized": true,
            "isEnabled": true
        },
        {
            "id": "revcontent-campaign-analytics",
            "name": "Revcontent Boost Analytics",
            "shortName": "Revcontent",
            "guidelinesUrl": "https://docs.google.com/document/d/e/2PACX-1vRhcBv-HJXgSCo9O_oTtu_Pi928LRrFlwAu5Pm56vk2Fdix3HMi4UjqJJWsCtfN9GR4z4r1ZW3m9XWf/pub?embedded=true",
            "thumbnailUrl": "https://static.37x.com/logos/pngs/revcontent.png",
            "smallThumbnailUrl": "https://static.37x.com/logos/pngs/revcontent-small.png",
            "description": "Collect Boost Analytics for Revcontent Native Ad Network Platform",
            "category": "campaign-analytics",
            "type": "buying",
            "authType": "credentials",
            "isConfigValid": true,
            "isAuthorized": true,
            "isEnabled": true
        },
        {
            "id": "revcontent-widget-analytics",
            "name": "Revcontent Widget Analytics",
            "shortName": "Revcontent",
            "guidelinesUrl": "https://docs.google.com/document/d/e/2PACX-1vRXjvMxY3RAv2J_cZtcnvv0Uu7q5246FfG_uAwWCtuHQF4GUkH-hzZVyAs1l68MWlxsCUiMqGVQrkWg/pub?embedded=true",
            "thumbnailUrl": "https://static.37x.com/logos/pngs/revcontent.png",
            "smallThumbnailUrl": "https://static.37x.com/logos/pngs/revcontent-small.png",
            "description": "Collect Widget Analytics for Revcontent Native Ad Network Platform",
            "category": "widget-analytics",
            "type": "selling",
            "authType": "credentials",
            "isConfigValid": true,
            "isAuthorized": true,
            "isEnabled": true
        }
    ]
    

    Get all available Integrations

    Get specific Integration

    curl "https://api.37x.com/v1.1/organizations/:organizationId/sites/:siteId/integrations/:integrationId"
      -H "Authorization: Token 08ad3c6d-840b-4d21-aaa2-7c75b2a3fffc..." 
    

    Response:

    {
        "id": "revcontent-widget-analytics",
        "name": "Revcontent Widget Analytics",
        "shortName": "Revcontent",
        "guidelinesUrl": "https://docs.google.com/document/d/e/2PACX-1vRXjvMxY3RAv2J_cZtcnvv0Uu7q5246FfG_uAwWCtuHQF4GUkH-hzZVyAs1l68MWlxsCUiMqGVQrkWg/pub?embedded=true",
        "thumbnailUrl": "https://static.37x.com/logos/pngs/revcontent.png",
        "smallThumbnailUrl": "https://static.37x.com/logos/pngs/revcontent-small.png",
        "description": "Collect Widget Analytics for Revcontent Native Ad Network Platform",
        "category": "widget-analytics",
        "type": "selling",
        "authType": "credentials",
        "isConfigValid": true,
        "isAuthorized": true,
        "isEnabled": true
    }
    

    Get a specific Integration

    Get Auth Config

    curl "https://api.37x.com/v1.1/organizations/:organizationId/sites/:siteId/integrations/:integrationId/auth"
      -H "Authorization: Token 08ad3c6d-840b-4d21-aaa2-7c75b2a3fffc..." 
    

    Response:

    {
        "clientId": "**********",
        "clientSecret": "**********"
    }
    

    Get Integration Auth Configuration

    Get Auth Config Parameters

    curl "https://api.37x.com/v1.1/organizations/:organizationId/sites/:siteId/integrations/:integrationId/auth/params"
      -H "Authorization: Token 08ad3c6d-840b-4d21-aaa2-7c75b2a3fffc..." 
    

    Response:

    [
        {
            "param": "clientId",
            "type": "string",
            "name": "Client ID",
            "description": "API Client ID. Go to <a href=\"https://www.revcontent.com/account/settings\" target=\"_blank\">Revcontent account settings</a>.",
            "isRequired": true,
            "isSecret": true
        },
        {
            "param": "clientSecret",
            "type": "string",
            "name": "Client Secret",
            "description": "API Client Secret. Go to <a href=\"https://www.revcontent.com/account/settings\" target=\"_blank\">Revcontent account settings</a>.",
            "isRequired": true,
            "isSecret": true
        }
    ]
    

    Update Auth Config

    curl "https://api.37x.com/v1.1/organizations/:organizationId/sites/:siteId/integrations/:integrationId/auth"
      -X POST
      -H "Authorization: Token 08ad3c6d-840b-4d21-aaa2-7c75b2a3fffc..."
      -H "Content-Type: application/json" 
      -d '{
            "clientId": "new_client_id",
            "clientSecret": "new_client_secret"
      }'
    

    Response:

    {
        "clientId": "**********",
        "clientSecret": "**********"
    }
    

    Update the Integration Auth Configuration.

    Get Config

    curl "https://api.37x.com/v1.1/organizations/:organizationId/sites/:siteId/integrations/:integrationId/config"
      -H "Authorization: Token 08ad3c6d-840b-4d21-aaa2-7c75b2a3fffc..." 
    

    Response:

    {
        "networkCode": "123123123"
    }
    

    Get Integration Configuration

    Get Config Parameters

    curl "https://api.37x.com/v1.1/organizations/:organizationId/sites/:siteId/integrations/:integrationId/config/params"
      -H "Authorization: Token 08ad3c6d-840b-4d21-aaa2-7c75b2a3fffc..." 
    

    Response:

    [
        {
            "param": "networkCode",
            "type": "integer",
            "name": "Network",
            "description": "Ad Manager (DFP) Network.",
            "isRequired": false,
            "isSecret": false,
            "optionsAvailable": true
        }
    ]
    

    Update Config

    curl "https://api.37x.com/v1.1/organizations/:organizationId/sites/:siteId/integrations/:integrationId/config"
      -X POST
      -H "Authorization: Token 08ad3c6d-840b-4d21-aaa2-7c75b2a3fffc..."
      -H "Content-Type: application/json" 
      -d '{
            "networkCode": "321321321"
      }'
    

    Response:

    {
        "networkCode": "321321321"
    }
    

    Update the Integration Configuration.

    Data

    Get Dimensions

    curl "https://api.37x.com/v1.1/dimensions"
      -H "Authorization: Token 08ad3c6d-840b-4d21-aaa2-7c75b2a3fffc..." 
    

    Response

    [
        {
            "label": "Source",
            "key": "group.source",
            "description": "",
            "type": "String",
            "category": "group"
        },
        {
            "label": "Landing Page",
            "key": "landingPath",
            "description": "URL at which the user began a session",
            "type": "String",
            "category": "group"
        },
        {
            "label": "Targeting",
            "key": [
                "group.country",
                "group.device"
            ],
            "description": "",
            "type": "Array",
            "category": "group"
        },
        {
            "label": "Sessions",
            "key": "sessions",
            "description": "Total number of sessions",
            "type": "Number",
            "format": "0.[00]a",
            "category": "selling"
        },
        {
            "label": "Revenue ($)",
            "key": "revenue",
            "description": "Total revenue generated",
            "type": "Number",
            "format": "0,0.[00]",
            "category": "selling"
        },
        {
            "label": "Revenue Per Session ($)",
            "key": "revenuePerSession",
            "description": "Average revenue generated per session",
            "type": "Number",
            "format": "0,0.[0000]",
            "category": "selling"
        },
        {
            "label": "Pageviews",
            "key": "pageviews",
            "description": "Total number of pages visited",
            "type": "Number",
            "format": "0.[00]a",
            "category": "selling"
        },
        {
            "label": "Impressions",
            "key": "impressions",
            "description": "Total number of sessions",
            "type": "Number",
            "format": "0.[00]a",
            "category": "selling"
        },
        {
            "label": "Pageviews Per Session",
            "key": "pageviewsPerSession",
            "description": "Average number of pageviews per session",
            "type": "Number",
            "format": "0,0.[00]",
            "category": "selling"
        },
        {
            "label": "Impressions Per Session",
            "key": "impressionsPerSession",
            "description": "Average number of ad unit renders per session",
            "type": "Number",
            "format": "0,0.00",
            "category": "selling"
        },
        {
            "label": "Impressions Per Pageview",
            "key": "impressionsPerPageview",
            "description": "Average number of ad unit renders per pageview",
            "type": "Number",
            "format": "0,0.000",
            "category": "selling"
        },
        {
            "label": "CPM ($)",
            "key": "cpm",
            "description": "Average Cost per mille per ad unit render",
            "type": "Number",
            "format": "0,0.0000",
            "category": "selling"
        },
        {
            "label": "Spend ($)",
            "key": "spend",
            "description": "Total spend across all platforms",
            "type": "Number",
            "format": "0.[00]a",
            "category": "buying"
        },
        {
            "label": "Clicks",
            "key": "clicks",
            "description": "Total clicks across all platforms",
            "type": "Number",
            "format": "0.[00]a",
            "category": "buying"
        },
        {
            "label": "CPC ($)",
            "key": "cpc",
            "description": "Spend per click across all platforms",
            "type": "Number",
            "format": "0.[0000]a",
            "category": "buying"
        },
        {
            "label": "ROI (%)",
            "key": "roi",
            "description": "Return on investment (revenue/spend%)",
            "type": "Number",
            "format": "0.00%",
            "category": "buying"
        }
    ]
    

    Get available metric dimensions and some meta about them (type, format etc.)

    Get All Filters

    curl "https://api.37x.com/v1.1/filters"
      -H "Authorization: Token 08ad3c6d-840b-4d21-aaa2-7c75b2a3fffc..." 
    

    Response

    [
        {
            "id": "device",
            "plural": "devices",
            "label": "Devices",
            "options": [
                {
                    "key": "mobile",
                    "label": "Mobile"
                },
                {
                    "key": "tablet",
                    "label": "Tablet"
                },
                {
                    "key": "desktop",
                    "label": "Desktop"
                },
                {
                    "key": "other",
                    "label": "Other"
                }
            ],
            "type": "Array"
        },
        {
            "id": "country",
            "plural": "countries",
            "label": "Countries",
            "type": "Array"
        },
        {
            "id": "source",
            "plural": "sources",
            "label": "Sources",
            "type": "Array"
        },
        {
            "id": "adblock",
            "plural": "adblock",
            "label": "Adblock",
            "type": "Boolean",
            "options": [
                {
                    "key": true,
                    "label": "Yes"
                },
                {
                    "key": false,
                    "label": "No"
                }
            ]
        },
        {
            "id": "utm_medium",
            "plural": "utm_mediums",
            "label": "UTM Mediums",
            "type": "Array",
            "nullable": true
        },
        {
            "id": "utm_term",
            "plural": "utm_terms",
            "label": "UTM Terms",
            "type": "Array",
            "nullable": true
        },
        {
            "id": "utm_content",
            "plural": "utm_contents",
            "label": "UTM Contents",
            "type": "Array",
            "nullable": true
        },
        {
            "id": "utm_campaign",
            "plural": "utm_campaigns",
            "label": "UTM Campaigns",
            "type": "Array",
            "nullable": true
        }
    ]
    

    Get available filters by which you can narrow down on the data queries

    Get Available Entity Filters

    curl "https://api.37x.com/v1.1/organizations/:organizationId/filters/:filterPluralId"
      -H "Authorization: Token 08ad3c6d-840b-4d21-aaa2-7c75b2a3fffc..." 
    

    Response

    [
        {
            "sessions": "3481",
            "key": "desktop"
        },
        {
            "sessions": "3240",
            "key": "mobile"
        },
        {
            "sessions": "248",
            "key": "tablet"
        },
        {
            "sessions": "1",
            "key": "other"
        }
    ]
    

    Use this to get available filters a single Organization, Site or Landing Path.
    You can use either POST or GET HTTP Methods. With GET you will have to encode the Body JSON in the query string parameters.
    Please use encoding conventions described in HERE
    Available endpoints:
    /v1.1/organizations/:organizationId/filters/:filterPluralId
    /v1.1/organizations/:organizationId/sites/:siteId/filters/:filterPluralId
    /v1.1/organizations/:organizationId/sites/:siteId/landing-paths/:landingPathId/filters/:filterPluralId

    Parameters

    Parameter Type Required Description
    from Integer No Epoch millisecond start timestamp of your query. Must not be further than 72 hours from current time. Defaults to Current DateTime minus 72 hours (3 days)
    to Integer No Epoch millisecond end timestamp of your query. Defaults to current timestamp
    filters[device] String[] No List of Devices you want to filter your query by. Currently these are availabe: desktop, mobile, tablet, other. Default to all devices.
    filters[source] String[] No List of Traffic Sources you want to filter your query by. Source is collected from ?utm_source= query parameter on your website, or the document.referrer. Defaults to all traffic sources.
    filters[country] String[] No List of ISO Alpha-2 Country Codes you want to filter your query by. Defaults to all countries.
    filters[adblock] Boolean No Whether to include only AdBlocked traffic or only Not AdBlocked traffic. Defaults to neither.
    filters[utm_medium] String[] No List of UTM Mediums you want to filter your query by. It is collected from ?utm_medium= query parameter on your website. Defaults to all.
    filters[utm_term] String[] No List of UTM Terms you want to filter your query by. It is collected from ?utm_term= query parameter on your website. Defaults to all.
    filters[utm_content] String[] No List of UTM Content you want to filter your query by. It is collected from ?utm_content= query parameter on your website. Defaults to all.
    filters[utm_campaign] String[] No List of UTM Campaign you want to filter your query by. It is collected from ?utm_campaign= query parameter on your website. Defaults to all.

    Get Entity Data

    curl "https://api.37x.com/v1.1/organizations/:organizationId/data"
      -H "Authorization: Token 08ad3c6d-840b-4d21-aaa2-7c75b2a3fffc..." 
    

    Response

    {
        "stats": {
            "revenue": {
                "total": 90.5824,
                "breakdowns": {
                    "headerBidding": 21.4717,
                    "adserver": 38.7841,
                    "integrations": {
                        "revcontent-widget-analytics": 30.3267
                    }
                }
            },
            "impressions": {
                "total": 125782,
                "breakdowns": {
                    "headerBidding": 21883,
                    "adserver": 59143,
                    "integrations": {
                        "revcontent-widget-analytics": 44756
                    }
                }
            },
            "sessions": {
                "total": 2440
            },
            "pageviews": {
                "total": 18158
            },
            "revenuePerSession": {
                "total": 0.037124,
                "breakdowns": {
                    "headerBidding": 0.0088,
                    "adserver": 0.015895,
                    "integrations": {
                        "revcontent-widget-analytics": 0.012429
                    }
                }
            },
            "pageviewsPerSession": {
                "total": 7.441803
            },
            "cpm": {
                "total": 1.00892,
                "breakdowns": {
                    "headerBidding": 1.593438,
                    "adserver": 1.121548,
                    "integrations": {
                        "revcontent-widget-analytics": 0.574294
                    }
                }
            },
            "impressionsPerSession": {
                "total": 51.55,
                "breakdowns": {
                    "headerBidding": 8.968443,
                    "adserver": 24.238934,
                    "integrations": {
                        "revcontent-widget-analytics": 18.342623
                    }
                }
            },
            "impressionsPerPageview": {
                "total": 6.927084,
                "breakdowns": {
                    "headerBidding": 1.205144,
                    "adserver": 3.257132,
                    "integrations": {
                        "revcontent-widget-analytics": 2.464809
                    }
                }
            },
            "cpc": {
                "total": 0.043887,
                "breakdowns": {
                    "integrations": {
                        "revcontent-campaign-analytics": 0.043887
                    }
                }
            },
            "spend": {
                "total": 107.084,
                "breakdowns": {
                    "integrations": {
                        "revcontent-campaign-analytics": 107.084
                    }
                }
            },
            "roi": {
                "total": 0.845899,
                "breakdowns": {
                    "integrations": {
                        "revcontent-campaign-analytics": 0.845899
                    }
                }
            },
            "clicks": {
                "total": 2062,
                "breakdowns": {
                    "integrations": {
                        "revcontent-campaign-analytics": 2062
                    }
                }
            }
        }
    }
    

    Use this to get data for a single Organization, Site or Landing Path.
    You can use either POST or GET HTTP Methods. With GET you will have to encode the Body JSON in the query string parameters.
    Please use encoding conventions described in HERE
    Available endpoints:
    /v1.1/organizations/:organizationId/data
    /v1.1/organizations/:organizationId/sites/:siteId/data
    /v1.1/organizations/:organizationId/sites/:siteId/landing-paths/:landingPathId/data

    Parameters

    Parameter Type Required Description
    from Integer No Epoch millisecond start timestamp of your query. Must not be further than 72 hours from current time. Defaults to Current DateTime minus 72 hours (3 days)
    to Integer No Epoch millisecond end timestamp of your query. Defaults to current timestamp
    filters[device] String[] No List of Devices you want to filter your query by. Currently these are availabe: desktop, mobile, tablet, other. Default to all devices.
    filters[source] String[] No List of Traffic Sources you want to filter your query by. Source is collected from ?utm_source= query parameter on your website, or the document.referrer. Defaults to all traffic sources.
    filters[country] String[] No List of ISO Alpha-2 Country Codes you want to filter your query by. Defaults to all countries.
    filters[adblock] Boolean No Whether to include only AdBlocked traffic or only Not AdBlocked traffic. Defaults to neither.
    filters[utm_medium] String[] No List of UTM Mediums you want to filter your query by. It is collected from ?utm_medium= query parameter on your website. Defaults to all.
    filters[utm_term] String[] No List of UTM Terms you want to filter your query by. It is collected from ?utm_term= query parameter on your website. Defaults to all.
    filters[utm_content] String[] No List of UTM Content you want to filter your query by. It is collected from ?utm_content= query parameter on your website. Defaults to all.
    filters[utm_campaign] String[] No List of UTM Campaign you want to filter your query by. It is collected from ?utm_campaign= query parameter on your website. Defaults to all.

    Get Entities Data

    {
        "data": [
            {
                "stats": {
                    "revenue": {
                        "total": 87.4398,
                        "breakdowns": {
                            "headerBidding": 20.9627,
                            "adserver": 37.4611,
                            "integrations": {
                                "revcontent-widget-analytics": 29.0161
                            }
                        }
                    },
                    "impressions": {
                        "total": 121501,
                        "breakdowns": {
                            "headerBidding": 21511,
                            "adserver": 56842,
                            "integrations": {
                                "revcontent-widget-analytics": 43148
                            }
                        }
                    },
                    "sessions": {
                        "total": 2416
                    },
                    "pageviews": {
                        "total": 17559
                    },
                    "revenuePerSession": {
                        "total": 0.036192,
                        "breakdowns": {
                            "headerBidding": 0.008677,
                            "adserver": 0.015505,
                            "integrations": {
                                "revcontent-widget-analytics": 0.01201
                            }
                        }
                    },
                    "pageviewsPerSession": {
                        "total": 7.267798
                    },
                    "cpm": {
                        "total": 1.016283,
                        "breakdowns": {
                            "headerBidding": 1.605901,
                            "adserver": 1.129398,
                            "integrations": {
                                "revcontent-widget-analytics": 0.57332
                            }
                        }
                    },
                    "impressionsPerSession": {
                        "total": 50.290149,
                        "breakdowns": {
                            "headerBidding": 8.90356,
                            "adserver": 23.527318,
                            "integrations": {
                                "revcontent-widget-analytics": 17.859272
                            }
                        }
                    },
                    "impressionsPerPageview": {
                        "total": 6.919585,
                        "breakdowns": {
                            "headerBidding": 1.22507,
                            "adserver": 3.2372,
                            "integrations": {
                                "revcontent-widget-analytics": 2.457315
                            }
                        }
                    },
                    "cpc": {
                        "total": 0.043056,
                        "breakdowns": {
                            "integrations": {
                                "revcontent-campaign-analytics": 0.043056
                            }
                        }
                    },
                    "spend": {
                        "total": 104.023,
                        "breakdowns": {
                            "integrations": {
                                "revcontent-campaign-analytics": 104.023
                            }
                        }
                    },
                    "roi": {
                        "total": 0.840583,
                        "breakdowns": {
                            "integrations": {
                                "revcontent-campaign-analytics": 0.840583
                            }
                        }
                    },
                    "clicks": {
                        "total": 1998,
                        "breakdowns": {
                            "integrations": {
                                "revcontent-campaign-analytics": 1998
                            }
                        }
                    }
                },
                "id": "Jas8FGds8sw",
                "name": "My Company Name"
            },
            {
                "stats": {
                    "revenue": {
                        "total": 32.9054,
                        "breakdowns": {
                            "headerBidding": 12.7419,
                            "adserver": 11.4604,
                            "integrations": {
                                "revcontent-widget-analytics": 8.70315
                            }
                        }
                    },
                    "impressions": {
                        "total": 47048,
                        "breakdowns": {
                            "headerBidding": 11413,
                            "adserver": 16531,
                            "integrations": {
                                "revcontent-widget-analytics": 19104
                            }
                        }
                    },
                    "sessions": {
                        "total": 892
                    },
                    "pageviews": {
                        "total": 5287
                    },
                    "revenuePerSession": {
                        "total": 0.036889,
                        "breakdowns": {
                            "headerBidding": 0.014285,
                            "adserver": 0.012848,
                            "integrations": {
                                "revcontent-widget-analytics": 0.009757
                            }
                        }
                    },
                    "pageviewsPerSession": {
                        "total": 5.92713
                    },
                    "cpm": {
                        "total": 0.861142,
                        "breakdowns": {
                            "headerBidding": 1.577626,
                            "adserver": 0.855291,
                            "integrations": {
                                "revcontent-widget-analytics": 0.438168
                            }
                        }
                    },
                    "impressionsPerSession": {
                        "total": 52.744395,
                        "breakdowns": {
                            "headerBidding": 12.794843,
                            "adserver": 18.532511,
                            "integrations": {
                                "revcontent-widget-analytics": 21.41704
                            }
                        }
                    },
                    "impressionsPerPageview": {
                        "total": 8.898808,
                        "breakdowns": {
                            "headerBidding": 2.158691,
                            "adserver": 3.126726,
                            "integrations": {
                                "revcontent-widget-analytics": 3.613391
                            }
                        }
                    },
                    "cpc": {
                        "total": 0.054179,
                        "breakdowns": {
                            "integrations": {
                                "revcontent-campaign-analytics": 0.054179
                            }
                        }
                    },
                    "spend": {
                        "total": 48.3281,
                        "breakdowns": {
                            "integrations": {
                                "revcontent-campaign-analytics": 48.3281
                            }
                        }
                    },
                    "roi": {
                        "total": 0.680877,
                        "breakdowns": {
                            "integrations": {
                                "revcontent-campaign-analytics": 0.680877
                            }
                        }
                    },
                    "clicks": {
                        "total": 794,
                        "breakdowns": {
                            "integrations": {
                                "revcontent-campaign-analytics": 794
                            }
                        }
                    }
                },
                "id": "Na8H0Y9AkdA",
                "name": "37x"
            }
        ],
        "meta": {
            "page": 1,
            "pagesCount": 1,
            "limit": 10,
            "total": 2
        }
    }
    

    Use this to get data for a set of Organizations, Sites or Landing Paths.
    You can use either POST or GET HTTP Methods. With GET you will have to encode the Body JSON in the query string parameters.
    Please use encoding conventions described in HERE
    Available endpoints:
    /v1.1/organizations/data
    /v1.1/organizations/:organizationId/sites/data
    /v1.1/organizations/:organizationId/sites/:siteId/landing-paths/data

    Parameters

    Parameter Type Required Description
    from Integer No Epoch millisecond start timestamp of your query. Must not be further than 72 hours from current time. Defaults to Current DateTime minus 72 hours (3 days)
    to Integer No Epoch millisecond end timestamp of your query. Defaults to current timestamp
    filters[device] String[] No List of Devices you want to filter your query by. Currently these are availabe: desktop, mobile, tablet, other. Default to all devices.
    filters[source] String[] No List of Traffic Sources you want to filter your query by. Source is collected from ?utm_source= query parameter on your website, or the document.referrer. Defaults to all traffic sources.
    filters[country] String[] No List of ISO Alpha-2 Country Codes you want to filter your query by. Defaults to all countries.
    filters[adblock] Boolean No Whether to include only AdBlocked traffic or only Not AdBlocked traffic. Defaults to neither.
    filters[utm_medium] String[] No List of UTM Mediums you want to filter your query by. It is collected from ?utm_medium= query parameter on your website. Defaults to all.
    filters[utm_term] String[] No List of UTM Terms you want to filter your query by. It is collected from ?utm_term= query parameter on your website. Defaults to all.
    filters[utm_content] String[] No List of UTM Content you want to filter your query by. It is collected from ?utm_content= query parameter on your website. Defaults to all.
    filters[utm_campaign] String[] No List of UTM Campaign you want to filter your query by. It is collected from ?utm_campaign= query parameter on your website. Defaults to all.
    groupBy String[] No Aggregate the results by any combination of these groups: source, device, country. Defaults to none
    orderBy String No Order the results by any Metric. Append a - symbol in front of the metric to use descending order (revenue - Ascending
    limit Number No How many records you want to get from a single query data set.
    page Number No Get a certain page of the data set.

    Get Entity Filter Breakdown Data

    curl "https://api.37x.com/v1.1/organizations/:organizationId/data/filters/:filterPluralId"
      -H "Authorization: Token 08ad3c6d-840b-4d21-aaa2-7c75b2a3fffc..." 
    

    Response:

    {
        "data": [
            {
                "stats": {
                    "revenue": {
                        "total": 162.845,
                        "breakdowns": {
                            "headerBidding": 38.8269,
                            "adserver": 65.0997,
                            "integrations": {
                                "revcontent-widget-analytics": 58.9184
                            }
                        }
                    },
                    "impressions": {
                        "total": 263170,
                        "breakdowns": {
                            "headerBidding": 47878,
                            "adserver": 116094,
                            "integrations": {
                                "revcontent-widget-analytics": 99198
                            }
                        }
                    },
                    "sessions": {
                        "total": 3473
                    },
                    "pageviews": {
                        "total": 30343
                    },
                    "revenuePerSession": {
                        "total": 0.046889,
                        "breakdowns": {
                            "headerBidding": 0.01118,
                            "adserver": 0.018745,
                            "integrations": {
                                "revcontent-widget-analytics": 0.016965
                            }
                        }
                    },
                    "pageviewsPerSession": {
                        "total": 8.736827
                    },
                    "cpm": {
                        "total": 0.803143,
                        "breakdowns": {
                            "headerBidding": 1.252305,
                            "adserver": 0.795274,
                            "integrations": {
                                "revcontent-widget-analytics": 0.595564
                            }
                        }
                    },
                    "impressionsPerSession": {
                        "total": 75.775986,
                        "breakdowns": {
                            "headerBidding": 13.785776,
                            "adserver": 33.427584,
                            "integrations": {
                                "revcontent-widget-analytics": 28.562626
                            }
                        }
                    },
                    "impressionsPerPageview": {
                        "total": 8.67317,
                        "breakdowns": {
                            "headerBidding": 1.577893,
                            "adserver": 3.826055,
                            "integrations": {
                                "revcontent-widget-analytics": 3.269222
                            }
                        }
                    },
                    "cpc": {
                        "total": 0.06577,
                        "breakdowns": {
                            "integrations": {
                                "revcontent-campaign-analytics": 0.06577
                            }
                        }
                    },
                    "spend": {
                        "total": 228.42,
                        "breakdowns": {
                            "integrations": {
                                "revcontent-campaign-analytics": 228.42
                            }
                        }
                    },
                    "roi": {
                        "total": 0.712925,
                        "breakdowns": {
                            "integrations": {
                                "revcontent-campaign-analytics": 0.712925
                            }
                        }
                    },
                    "clicks": {
                        "total": 3336,
                        "breakdowns": {
                            "integrations": {
                                "revcontent-campaign-analytics": 3336
                            }
                        }
                    }
                },
                "key": "desktop"
            },
            {
                "stats": {
                    "revenue": {
                        "total": 34.9541,
                        "breakdowns": {
                            "headerBidding": 4.07117,
                            "adserver": 22.9441,
                            "integrations": {
                                "revcontent-widget-analytics": 7.93888
                            }
                        }
                    },
                    "impressions": {
                        "total": 42608,
                        "breakdowns": {
                            "headerBidding": 2113,
                            "adserver": 23069,
                            "integrations": {
                                "revcontent-widget-analytics": 17426
                            }
                        }
                    },
                    "sessions": {
                        "total": 3459
                    },
                    "pageviews": {
                        "total": 13188
                    },
                    "revenuePerSession": {
                        "total": 0.010105,
                        "breakdowns": {
                            "headerBidding": 0.001177,
                            "adserver": 0.006633,
                            "integrations": {
                                "revcontent-widget-analytics": 0.002295
                            }
                        }
                    },
                    "pageviewsPerSession": {
                        "total": 3.812663
                    },
                    "cpm": {
                        "total": 1.041029,
                        "breakdowns": {
                            "headerBidding": 2.488468,
                            "adserver": 1.386802,
                            "integrations": {
                                "revcontent-widget-analytics": 0.407777
                            }
                        }
                    },
                    "impressionsPerSession": {
                        "total": 12.318011,
                        "breakdowns": {
                            "headerBidding": 0.61087,
                            "adserver": 6.669269,
                            "integrations": {
                                "revcontent-widget-analytics": 5.037872
                            }
                        }
                    },
                    "impressionsPerPageview": {
                        "total": 3.230816,
                        "breakdowns": {
                            "headerBidding": 0.160221,
                            "adserver": 1.749242,
                            "integrations": {
                                "revcontent-widget-analytics": 1.321353
                            }
                        }
                    },
                    "cpc": {
                        "total": 0.025397,
                        "breakdowns": {
                            "integrations": {
                                "revcontent-campaign-analytics": 0.025397
                            }
                        }
                    },
                    "spend": {
                        "total": 87.8468,
                        "breakdowns": {
                            "integrations": {
                                "revcontent-campaign-analytics": 87.8468
                            }
                        }
                    },
                    "roi": {
                        "total": 0.397895,
                        "breakdowns": {
                            "integrations": {
                                "revcontent-campaign-analytics": 0.397895
                            }
                        }
                    },
                    "clicks": {
                        "total": 3760,
                        "breakdowns": {
                            "integrations": {
                                "revcontent-campaign-analytics": 3760
                            }
                        }
                    }
                },
                "key": "mobile"
            },
            {
                "stats": {
                    "revenue": {
                        "total": 8.52436,
                        "breakdowns": {
                            "headerBidding": 0.311797,
                            "adserver": 6.72987,
                            "integrations": {
                                "revcontent-widget-analytics": 1.4827
                            }
                        }
                    },
                    "impressions": {
                        "total": 12854,
                        "breakdowns": {
                            "headerBidding": 219,
                            "adserver": 7115,
                            "integrations": {
                                "revcontent-widget-analytics": 5520
                            }
                        }
                    },
                    "sessions": {
                        "total": 236
                    },
                    "pageviews": {
                        "total": 1639
                    },
                    "revenuePerSession": {
                        "total": 0.03612,
                        "breakdowns": {
                            "headerBidding": 0.001321,
                            "adserver": 0.028516,
                            "integrations": {
                                "revcontent-widget-analytics": 0.006283
                            }
                        }
                    },
                    "pageviewsPerSession": {
                        "total": 6.944915
                    },
                    "cpm": {
                        "total": 0.9179,
                        "breakdowns": {
                            "headerBidding": 1.885392,
                            "adserver": 1.236775,
                            "integrations": {
                                "revcontent-widget-analytics": 0.468501
                            }
                        }
                    },
                    "impressionsPerSession": {
                        "total": 54.466102,
                        "breakdowns": {
                            "headerBidding": 0.927966,
                            "adserver": 30.148305,
                            "integrations": {
                                "revcontent-widget-analytics": 23.389831
                            }
                        }
                    },
                    "impressionsPerPageview": {
                        "total": 7.842587,
                        "breakdowns": {
                            "headerBidding": 0.133618,
                            "adserver": 4.341062,
                            "integrations": {
                                "revcontent-widget-analytics": 3.367907
                            }
                        }
                    },
                    "cpc": {
                        "total": 0.023863,
                        "breakdowns": {
                            "integrations": {
                                "revcontent-campaign-analytics": 0.023863
                            }
                        }
                    },
                    "spend": {
                        "total": 5.63164,
                        "breakdowns": {
                            "integrations": {
                                "revcontent-campaign-analytics": 5.63164
                            }
                        }
                    },
                    "roi": {
                        "total": 1.513655,
                        "breakdowns": {
                            "integrations": {
                                "revcontent-campaign-analytics": 1.513655
                            }
                        }
                    },
                    "clicks": {
                        "total": 204,
                        "breakdowns": {
                            "integrations": {
                                "revcontent-campaign-analytics": 204
                            }
                        }
                    }
                },
                "key": "tablet"
            },
            {
                "stats": {
                    "revenue": {
                        "total": 0,
                        "breakdowns": {
                            "headerBidding": 0,
                            "adserver": 0,
                            "integrations": {
                                "revcontent-widget-analytics": 0
                            }
                        }
                    },
                    "impressions": {
                        "total": 6,
                        "breakdowns": {
                            "headerBidding": 0,
                            "adserver": 6,
                            "integrations": {
                                "revcontent-widget-analytics": 0
                            }
                        }
                    },
                    "sessions": {
                        "total": 1
                    },
                    "pageviews": {
                        "total": 1
                    },
                    "revenuePerSession": {
                        "total": 0,
                        "breakdowns": {
                            "headerBidding": 0,
                            "adserver": 0,
                            "integrations": {
                                "revcontent-widget-analytics": 0
                            }
                        }
                    },
                    "pageviewsPerSession": {
                        "total": 1
                    },
                    "cpm": {
                        "total": 0,
                        "breakdowns": {
                            "headerBidding": 0,
                            "adserver": 0,
                            "integrations": {
                                "revcontent-widget-analytics": 0
                            }
                        }
                    },
                    "impressionsPerSession": {
                        "total": 6,
                        "breakdowns": {
                            "headerBidding": 0,
                            "adserver": 6,
                            "integrations": {
                                "revcontent-widget-analytics": 0
                            }
                        }
                    },
                    "impressionsPerPageview": {
                        "total": 6,
                        "breakdowns": {
                            "headerBidding": 0,
                            "adserver": 6,
                            "integrations": {
                                "revcontent-widget-analytics": 0
                            }
                        }
                    },
                    "cpc": {
                        "total": 0.08,
                        "breakdowns": {
                            "integrations": {
                                "revcontent-campaign-analytics": 0.08
                            }
                        }
                    },
                    "spend": {
                        "total": 0.08,
                        "breakdowns": {
                            "integrations": {
                                "revcontent-campaign-analytics": 0.08
                            }
                        }
                    },
                    "roi": {
                        "total": 0,
                        "breakdowns": {
                            "integrations": {
                                "revcontent-campaign-analytics": 0
                            }
                        }
                    },
                    "clicks": {
                        "total": 1,
                        "breakdowns": {
                            "integrations": {
                                "revcontent-campaign-analytics": 1
                            }
                        }
                    }
                },
                "key": "other"
            }
        ],
        "meta": {
            "page": 1,
            "pagesCount": 1,
            "limit": 10,
            "total": 4
        }
    }
    

    Use this to get a filter data breakdown for a single Organization, Site or Landing Path.
    You can use either POST or GET HTTP Methods. With GET you will have to encode the Body JSON in the query string parameters.
    Please use encoding conventions described in HERE
    Available endpoints:
    /v1.1/organizations/:organizationId/data/filters/:filterPluralId
    /v1.1/organizations/:organizationId/sites/:siteId/data/filters/:filterPluralId
    /v1.1/organizations/:organizationId/sites/:siteId/landing-paths/:landingPathId/data/filters/:filterPluralId

    Parameters

    Parameter Type Required Description
    from Integer No Epoch millisecond start timestamp of your query. Must not be further than 72 hours from current time. Defaults to Current DateTime minus 72 hours (3 days)
    to Integer No Epoch millisecond end timestamp of your query. Defaults to current timestamp
    filters[device] String[] No List of Devices you want to filter your query by. Currently these are availabe: desktop, mobile, tablet, other. Default to all devices.
    filters[source] String[] No List of Traffic Sources you want to filter your query by. Source is collected from ?utm_source= query parameter on your website, or the document.referrer. Defaults to all traffic sources.
    filters[country] String[] No List of ISO Alpha-2 Country Codes you want to filter your query by. Defaults to all countries.
    filters[adblock] Boolean No Whether to include only AdBlocked traffic or only Not AdBlocked traffic. Defaults to neither.
    filters[utm_medium] String[] No List of UTM Mediums you want to filter your query by. It is collected from ?utm_medium= query parameter on your website. Defaults to all.
    filters[utm_term] String[] No List of UTM Terms you want to filter your query by. It is collected from ?utm_term= query parameter on your website. Defaults to all.
    filters[utm_content] String[] No List of UTM Content you want to filter your query by. It is collected from ?utm_content= query parameter on your website. Defaults to all.
    filters[utm_campaign] String[] No List of UTM Campaign you want to filter your query by. It is collected from ?utm_campaign= query parameter on your website. Defaults to all.
    orderBy String No Order the results by any Metric. Append a - symbol in front of the metric to use descending order (revenue - Ascending
    limit Number No How many records you want to get from a single query data set.
    page Number No Get a certain page of the data set.

    Errors

    The 37x API uses the following error codes:

    Error Code Meaning
    400 Bad Request -- Your request is incorrect
    401 Unauthorized -- Your API key is wrong
    403 Forbidden -- You don't have access to this resource
    404 Not Found -- The requested entity could not be found
    406 Not Acceptable -- You requested a format that isn't json
    429 Too Many Requests -- You're making too many requests! Slow down!
    500 Internal Server Error -- We had a problem with our server. Try again later.
    503 Service Unavailable -- We're temporarially offline for maintanance. Please try again later.

    Rate Limits

    Our API is rate limited to avoid overloading our servers.
    At the moment you are allowed to do 100 requests per 1 minute window
    If you have hit the Limit you will start getting Error responses with status 429
    This limit will probably decrease as the time goes on.

    Versions

    Latest
    v1.0

    Changelog