PRODUCT
Follow

Overview

You can use the geo endpoint to retrieve the following information for targeting:

  • Countries, states, or cities, and their IDs

  • Countries or states that support DMA targeting, or DMAs available for a specific state

  • Countries or states that support area code targeting, or area codes available for a specific state

  • Countries that support postal code targeting

  • Countries that support ISP targeting

  • ISPs available for a specific country

Resource URL

https://adapi.sizmek.com/sas/csb/strategies/targetingData

Objects Used by This Resource

HTTP Method and URI List

HTTP Method

URI

Description

GET

rest/csb/strategies/targetingData/countries

Retrieves all available countries and their IDs for targeting.

GET

rest/csb/strategies/targetingData/states?countryId=840&from=0&max=250&order=asc&sort=name

Retrieves all available states and their IDs for targeting.

GET

rest/csb/strategies/targetingData/cities?from=0&max=250&order=asc&sort=name&stateId=33

Retrieves all available cities and their IDs for targeting.

GET

rest/csb/strategies/targetingData/countries?from=0&max=250&order=asc&sort=name&type=dma

Retrieves all available countries that support DMA targeting.

GET

rest/csb/strategies/targetingData/states?countryId=840&from=0&max=250&order=asc&sort=name&type=dma

Retrieves all available states that support DMA targeting.

GET

rest/csb/strategies/targetingData/dmas?from=0&max=250&order=asc&sort=name&stateId=33

Retrieves all DMAs available for targeting for a specific state.

GET

rest/csb/strategies/targetingData/countries?from=0&max=250&order=asc&sort=name&type=areaCode

Retrieves all available countries that support area code targeting.

GET

rest/csb/strategies/targetingData/states?countryId=840&from=0&max=250&order=asc&sort=name&type=areaCode

Retrieves all available states that support area code targeting.

GET

rest/csb/strategies/targetingData/areaCodes?from=0&max=250&order=asc&sort=name&stateId=33

Retrieves all area codes available for targeting for a specific state.

GET

rest/csb/strategies/targetingData/countries?from=0&max=250&order=asc&sort=name&type=postalCode

Retrieves all available countries that suppport postal code targeting.

GET

rest/csb/strategies/targetingData/countries?from=0&max=250&order=asc&sort=name&type=isp

Retrieves all available countries that support ISP targeting.

GET

rest/csb/strategies/targetingData/isps?countryId=840&from=0&max=250&order=asc&sort=name

Retrieves all ISPs availabe for targeting for a specific country.

Method Examples and Request Parameters

Important

Important:

  • For PUT calls, do the following:

    • For any PUT method that updates an object, make sure that you include the entire "result": object from the GET response in the request body. If there is missing information, even if it is read-only, the request might fail or override the existing fields with the new values.

    • You must also change the "result": to "entities": and make the entities contents into an array. For example, here is the output from the GET request:

       { "result": { "type": "Advertiser", ... } }      

      You should make the following modifications, including your specific modifications, to the json object that you submit for the request.

       { "entities": [{ "type": "Advertiser", ... }] }   
      
  • For POST calls, do the following:

    • Include the fields marked as Required, as indicated in the corresponding Object article.

    • Format the JSON object as follows:

       { "entities": [{ "type": "Advertiser", ... }] }   

Get All Countries

Retrieves all available countries and their IDs for targeting.

Request Format

GET https://adapi.sizmek.com/sas/csb/strategies/targetingData/countriesadvertisers?from=0&max=250

Response Format

A successful request returns the HTTP 200 OK status code and a JSON response body that shows all available countries and IDs.

Get All States for a Country (GET)

Retrieves all available states and their IDs for targeting.

Request Format

GET https://adapi.sizmek.com/sas/csb/strategies/targetingData/states?countryId=840&from=0&max=250&order=asc&sort=name

Response Format

A successful request returns the HTTP 200 OK status code and a JSON response body that shows all available states and IDs.

Get All Cities for a State (GET)

Retrieves all available cities and their IDs for targeting.

Request Format

GET https://adapi.sizmek.com/sas/csb/strategies/targetingData/cities?from=0&max=250&order=asc&sort=name&stateId=33

Response Format

A successful request returns the HTTP 200 OK status code and a JSON response body that shows all available cities and IDs.

Get All Countries with DMA (GET)

Retrieves all countries that support DMA targeting.

Request Format

GET https://adapi.sizmek.com/sas/csb/strategies/targetingData/countries?from=0&max=250&order=asc&sort=name&type=dma

Response Format

A successful request returns the HTTP 200 OK status code and a JSON response body that shows all available countries that support DMA targeting.

Get All States with DMA (GET)

Retrieves all states that support DMA targeting.

Request Format

GET https://adapi.sizmek.com/sas/csb/strategies/targetingData/states?countryId=840&from=0&max=250&order=asc&sort=name&type=dma

Response Format

A successful request returns the HTTP 200 OK status code and a JSON response body that shows all available states with DMA.

Get DMAs by State (GET)

Retrieves DMAs available for targeting for a specific state.

Request Format

GET https://adapi.sizmek.com/sas/csb/strategies/targetingData/dmas?from=0&max=250&order=asc&sort=name&stateId=33

Response Format

A successful request returns the HTTP 200 OK status code and a JSON response body that shows all available DMAs for a specific state.

Get All Countries with Area Codes (GET)

Retrieves all available countries that support area code targeting.

Request Format

GET https://adapi.sizmek.com/sas/csb/strategies/targetingData/countries?from=0&max=250&order=asc&sort=name&type=areaCodeDepending on the API user that was created for you, use one of the following request formats:

Response Format

A successful request returns the HTTP 200 OK status code and a JSON response body that shows all countries with area codes.

Get All States with Area Codes (GET)

Retrieves all available states that support area code targeting.

Request Format

GET https://adapi.sizmek.com/sas/csb/strategies/targetingData/states?countryId=840&from=0&max=250&order=asc&sort=namecsb/strategies/targetingData/countriesadvertisers?from=0&max=250

Request Format

GET https://api.sizmek.com/rest/csb/strategies/targetingData/states?countryId=840&from=0&max=250&order=asc&sort=name&type=areaCode

Response Format

A successful request returns the HTTP 200 OK status code and a JSON response body that shows all states with area codes.

Get All Area Codes by State (GET)

Retrieves all area codes available for targeting for a specific state.

Request Format

GET https://adapi.sizmek.com/sas/csb/strategies/targetingData/areaCodes?from=0&max=250&order=asc&sort=name&stateId=33

Response Format

A successful request returns the HTTP 200 OK status code and a JSON response body that shows all area codes for a specific state.

Get All Countries with Postal Codes (GET)

Retrieves all available countries that support postal code targeting.

Request Format

GET https://adapi.sizmek.com/sas/csb/strategies/targetingData/countries?from=0&max=250&order=asc&sort=name&type=postalCode

Response Format

A successful request returns the HTTP 200 OK status code and a JSON response body that shows all available countries with postal code support.

Get All Countries with ISP (GET)

Retrieves all available countries that support ISP targeting.

Request Format

GET https://adapi.sizmek.com/sas/csb/strategies/targetingData/countries?&from=0&max=250&order=asc&sort=name&type=isp

Response Format

A successful request returns the HTTP 200 OK status code and a JSON response body that shows all countries with ISP support.

Get ISPs by Country (GET)

Retrieves all ISPs availabe for targeting for a specific country.

Request Format

GET https://adapi.sizmek.com/sas/csb/strategies/targetingData/isps?countryId=840&from=0&max=250&order=asc&sort=name

Response Format

A successful request returns the HTTP 200 OK status code and a JSON response body that shows all ISPs for a specific country.

Was this article helpful?
0 out of 0 found this helpful
Have more questions? Submit a request

Comments

Powered by Zendesk