Get All Publishing Locations

Retrieves all publishing locations.

Request

Request syntax:

GET /syndication-regions

Response

The response for a successful request contains the following properties:

NameData TypeDescription
@idStringIndicates the relative path to the requested endpoint.
@typeStringReturns Collection.
itemsList of dictionariesContains a list of publishing locations.
total_itemsIntegerIndicates the total number of publishing locations.

items List

The items list describes each publishing location via the following properties:

NameData TypeDescription
idStringIdentifies this publishing location by its system-defined ID.
nameStringIdentifies this publishing location by its name.

Sample Request/Response

The code below (Python 3) shows how to retrieve all publishing locations.

This code imports names from the api_auth module for V4 APIs (see below).

import requests
from api_auth import APICredentials, APIParams

class PublishingLocation:
    def __init__(self):
        self.host = "https://services.uplynk.com"

    def run(self):
        self._get_publishing_locations()

    def _get_publishing_locations(self):
        url = "{}{}".format(self.host, "/api/v4/syndication-regions")

        headers = {'Content-Type': 'application/json'}

        response = requests.get(
            url, params=APIParams(APICredentials()).get_params({}), headers=headers
        )

        print(response.json())

PublishingLocation().run()

Response:

{
	"@id": "/api/v4/syndication-regions",
	"@type": "Collection",
	"items": [{
			"id": "us-east-1",
			"name": "AWS - USA - East - N. Virginia"
		}, {
			"id": "us-east-2",
			"name": "AWS - USA - East - Ohio"
		}, {
			"id": "us-west-2",
			"name": "AWS - USA - West - Oregon"
		}, {
			"id": "sa-east-1",
			"name": "AWS - South America - East - Sao Paulo"
		}, {
			"id": "eu-central-1",
			"name": "AWS - Europe - Central - Frankfurt"
		}, {
			"id": "eu-west-1",
			"name": "AWS - Europe - West - Ireland"
		}, {
			"id": "ap-south-1",
			"name": "AWS - Asia Pacific - South - Mumbai"
		}, {
			"id": "ap-southeast-1",
			"name": "AWS - Asia Pacific - South East - Singapore"
		}
	],
	"total_items": 9
}