Account Holistic Optimization Setting Association API (UAS)

Document created by pubmatic-archivist on Mar 27, 2017Last modified by catherine.racette on Aug 28, 2017
Version 7Show Document
  • View in full screen mode

Overview

This API enables you to configure settings for holistic optimization at an account level to control cross-channel optimization for inventory. You can find the supported holistic optimization settings details using the Holistic Optimization API.

For more information about UAS Account & Admin Services APIs, refer to Account & Admin Services (UAS) 

Supported Operations

Service Name: /accountholisticoptimizationsettingassociations/

                           

Method PathHTTP Method TypeDescriptionLink to Definition

/accountholisticoptimizationsettingassociations/accounts/{accountId}/configure/
accounts/{accountId}
GETRetrieves the details of account level optimization. Setting configured for account id.Retrieve Account Level Optimization Setting
/accountholisticoptimizationsettingassociationsGETRetrieves the Holistic Optimization Settings for all accounts for which you are authorized access.Retrieve Settings for All Accounts
/accountholisticoptimizationsettingassociations/accounts/{accountId}/configurePOSTConfigure the Optimization Setting at an Account LevelConfigure Holistic Optimization Setting for an Account

 

 

Retrieve Account Level Optimization Setting

 

Overview

This API enables you to retrieve the details of account level optimization settings configured for an account ID. 

Request

           

Request Headers

                        

Header nameType ValueRequiredDescription
Content-TypeStringapplication/jsonYesMedia type for request.
pubTokenString${access_token}Yes

Publisher Token to authenticate and authorize the user calling the Unified Ad Server API. Send the access token generated for authentication at the place of ${access_token} in the request.

 

For more information about access tokens, refer to Getting Started with PubMatic APIs.

Sample Request URL

 

https://api.pubmatic.com/v1/uas/accountholisticoptimizationsettingassociations/accounts/1

Response

Sample Response JSON

    

[

  {

    "account": {

      "id": 118385,

      "url": "http://$URI_PREFIX/phoenix/accounts/118385"

    },

    "holisticOptimizationSetting": {

      "id": 5,

      "name": "Optimize for revenue- high risk.",

      "url": "http://$URI_PREFIX/phoenix/holisticoptimizationsettings/5"

    }

  }

]

 

Retrieve Settings for All Accounts

 

Overview

This API enables you to retrieve the Holistic Optimization Setting for all accounts for which you are authorized to access.

In the query, you can also apply supported dimensions, filters and sorting options to retrieve a list of Ad Units with a specific set of details according to your requirements.

Refer to Common Request Query Parameters for more information about using dimensions, filters and sorting, 
Using this API, you can apply dimensions, filter criteria and sorting option to retrieve a list of records.

 

Request

           

Request Headers

                        

Header nameType ValueRequiredDescription
Content-TypeStringapplication/jsonYesMedia type for request.
pubTokenString${access_token}Yes

Publisher Token to authenticate and authorize the user calling the Unified Ad Server API. Send the access token generated for authentication at the place of ${access_token} in the request.

 

For more information about access tokens, refer to Getting Started with PubMatic APIs.

Sample Request URL

https://api.pubmatic.com/v1/uas/accountholisticoptimizationsettingassociations 

Response

Sample Response JSON

    

{

  "metaData": {

    "startIndex": 1,

    "totalRecords": 2,

    "pageNumber": 1,

    "endIndex": 2,

    "pageSize": 100

  },

  "items": [

    {

      "account": {

        "id": 118385,

        "url": "http://$URI_PREFIX/phoenix/accounts/118385"

      },

      "holisticOptimizationSetting": {

        "id": 4,

        "name": "Optimize for revenue- medium risk.",

        "url": "http://$URI_PREFIX/phoenix/holisticoptimizationsettings/4"

      }

    },

    {

      "account": {

        "id": 118386,

        "name": "PubMatic Inc.",

        "url": "http://$URI_PREFIX/phoenix/accounts/118385"

      },

      "holisticOptimizationSetting": {

        "id": 5,

        "name": "Optimize for revenue- high risk.",

        "url": "http://$URI_PREFIX/phoenix/holisticoptimizationsettings/5"

      }

    }

  ]

}

 

Configure Holistic Optimization Setting for an Account

 

Overview

This API enables you to configure the Optimization setting at an account level.

Request

           

Request Headers

                        

Header nameType ValueRequiredDescription
Content-TypeStringapplication/jsonYesMedia type for request.
pubTokenString${access_token}Yes

Publisher Token to authenticate and authorize the user calling the Unified Ad Server API. Send the access token generated for authentication at the place of ${access_token} in the request.

 

For more information about access tokens, refer to Getting Started with PubMatic APIs.

Request Body Parameters

                               

Parameter NameTypeRequiredValidationsDescriptions
accountObjectYesValid Account (account should already exist in the system)Your account identifier
holisticOptimizationSettingObjectYesValid Setting (setting should already exist in the system)Setting supported by the Unified Ad Server. Details can be found in the Holistic Optimization API.
riskPercentageIntegerNoBetween 1 to 100.

This parameter is for future use only. You will be use this parameter to customize risk percentage per your business needs.

Currently, you will receive the risk percentage for respective holistic optimization setting. 

Sample Request URL

https://api.pubmatic.com/v1/uas/accountholisticoptimizationsettingassociations 

Sample Request JSON

    

{
   "account": {
     "id": 118385,
     "url": "http://$URI_PREFIX/phoenix/accounts/118385"
   },
   "holisticOptimizationSetting": {
     "id": 5,
     "name": "Optimize for revenue- high risk.",
     "url": "http://$URI_PREFIX/phoenix/holisticoptimizationsettings/5"
   },
   "riskPercentage": 20
}

Response

Sample Response JSON

    

[

  {

    "account": {

      "id": 118385,

      "url": "http://$URI_PREFIX/phoenix/accounts/118385"

    },

    "holisticOptimizationSetting": {

      "id": 5,

      "name": "Optimize for revenue- high risk.",

      "url": "http://$URI_PREFIX/phoenix/holisticoptimizationsettings/5"

    }

  }

]

 

 

Error Codes for Account Holistic Optimization Setting Association API

 

                  

Sr. No

Error Codes

Description

1.

 

PH_MISSING_OR_INVALID_PARAMETER

This error will occur when a mandatory parameter is missing or invalid in the request. 

This can occur for the following:

  • Account 

  • ‰ÛÜHolistic Optimization Setting

2.

PH_ENTITY_RANGE_INCLUSIVE

This error message occurs when riskPercentage value is not in the required range.

 

 

Unified Ad Server References

Common Request Query Parameters for Web Services

Supported Operations for Filters

HTTP Status Codes

Unified Ad Server Specific Error Codes

 

 

Version 0.2

Attachments

    Outcomes