Get All Policies

Retrieves all of your policies.

Request

Retrieve your policies via the following request:

HTTP Method Request URI

GET

https://api.vdms.io/rules-engine/v1.1/policies?platform_id=PlatformID&page=PageNumber&page_size=PageSize&state=State&search=Phrase

Define the following variables when submitting the above request:

VariableA variable represents a value that must be replaced. A variable consists of either a URL segment (e.g., "0001" in /0001/) or a query string value (e.g., "3" in mediaTypes=3). Description
PlatformID

Filter the response by a delivery platform. Replace this variable with one of the following IDs: Valid values are:

  • http_large
  • http_small
  • adn

PageNumber

Filter the response by a specific page. Replace this variable with the desired page.

Use the navigation links within the @links object to navigate between pages.

Default Value:

1

PageSize

Limit the response to only include the specified number of results.

Default Value:

100

State

Filter the response by policy state. Valid values are:

  • draft: Policies in this state may be modified.
  • locked: Most of a locked policy's properties are read-only.

Phrase

Filter the response to only include policies whose name or message contains the specified phrase.

Request Headers

This endpointIdentifies a request's connection point to our REST API service. only takes advantage of common request headers.

Unlike requests to api.edgecast.com, requests to our API gateway (api.vdms.io) require an access token (OAuth).

Request Body

Request body parameters are not required by this endpoint.

Response

The response to the above request includes an HTTP status code, response headers, and a response body.

Status Code

A status code indicates whether the request was successfully performed.

Response Headers

The response for this endpoint only includes standard HTTP response headers.

View common response headers.

Response Body

The response body for a successful request contains the following response elements:

Name Data Type Description
@id String Indicates the relative path to the requested endpoint.

@type

String

Returns Collection.

@links

Object

Contains navigation links for the first, next, previous, and last page.

items

Array

Contains a list of policies that satisfied the request.

@id

String

items array

Indicates the relative path to an endpoint through which you may retrieve the current policy.

@type

String

items array

Returns Policy.

id

String

items array

Identifies the policy by its system-defined ID.

name

String

items array

Identifies the policy by its name.

policy_type

String

items array

Returns customer.

state

String

items array

Indicates the policy's state. Valid values are:

  • draft: Policies in this state may be modified.
  • locked: A locked policy cannot be modified.

customer_id

String

items array

Indicates your customer account number.

platform_id

String

items array

Indicates the delivery platform corresponding to the policy. Valid values are:

  • http_large
  • http_small
  • adn

created_at

String

items array

Indicates the date and time (UTC) at which the policy was created.

Syntax:

YYYY-MM-DDThh:mm:ss

Example:

2024-01-08T20:31:06Z

updated_at

String

items array

Indicates the date and time (UTC) at which the policy was last updated.

Syntax:

YYYY-MM-DDThh:mm:ss

total_items

Integer

Indicates the total number of policies.

Errors

The response body for an unsuccessful request will contain an error response that provides additional information.

Sample Request and Response

A sample JSON request is shown below.

A sample JSON response is shown below.

HTTP/1.1 200 OK

Cache-Control: no-cache

Content-Type: application/json; charset=utf-8

Date: Thu, 15 Apr 2021 12:00:00 GMT

Content-Length: 3554

{
	"@id": "/rules-engine/v1.1/policies?page=3&page_size=10",
	"@type": "Collection",
	"@links": {
		"first": {
			"href": "/rules-engine/v1.1/policies?page=1&page_size=10"
		},
		"next": {
			"href": "/rules-engine/v1.1/policies?page=4&page_size=10"
		},
		"previous": {
			"href": "/rules-engine/v1.1/policies?page=2&page_size=10"
		},
		"last": {
			"href": "/rules-engine/v1.1/policies?page=11&page_size=10"
		}
	},
	"items": [{
			"@id": "/rules-engine/v1.1/policies/15066",
			"@type": "Policy",
			"id": "15066",
			"name": "My Rules v1.0",
			"policy_type": "customer",
			"state": "locked",
			"customer_id": "0001",
			"platform_id": "adn",
			"created_at": "2018-10-01T23:58:48Z",
			"updated_at": "2018-10-02T00:11:53Z"
		}, {
			"@id": "/rules-engine/v1.1/policies/15213",
			"@type": "Policy",
			"id": "15213",
			"name": "My Rules v1.1",
			"policy_type": "customer",
			"state": "locked",
			"customer_id": "0001",
			"platform_id": "adn",
			"created_at": "2018-10-04T17:57:31Z",
			"updated_at": "2018-10-04T18:00:41Z"
		}, {
			"@id": "/rules-engine/v1.1/policies/15214",
			"@type": "Policy",
			"id": "15214",
			"name": "My Rules v1.2",
			"policy_type": "customer",
			"state": "locked",
			"customer_id": "0001",
			"platform_id": "adn",
			"created_at": "2018-10-04T18:01:13Z",
			"updated_at": "2018-10-04T18:01:50Z"
		}, {
			"@id": "/rules-engine/v1.1/policies/15280",
			"@type": "Policy",
			"id": "15280",
			"name": "My Rules v1.3",
			"policy_type": "customer",
			"state": "locked",
			"customer_id": "0001",
			"platform_id": "adn",
			"created_at": "2018-10-05T17:12:34Z",
			"updated_at": "2018-10-05T17:17:06Z"
		}, {
			"@id": "/rules-engine/v1.1/policies/15282",
			"@type": "Policy",
			"id": "15282",
			"name": "My Rules v1.4",
			"policy_type": "customer",
			"state": "locked",
			"customer_id": "0001",
			"platform_id": "adn",
			"created_at": "2018-10-05T17:18:10Z",
			"updated_at": "2018-10-05T17:20:17Z"
		}, {
			"@id": "/rules-engine/v1.1/policies/15283",
			"@type": "Policy",
			"id": "15283",
			"name": "My Rules v1.5",
			"policy_type": "customer",
			"state": "locked",
			"customer_id": "0001",
			"platform_id": "adn",
			"created_at": "2018-10-05T17:20:52Z",
			"updated_at": "2018-10-05T17:21:23Z"
		}, {
			"@id": "/rules-engine/v1.1/policies/15407",
			"@type": "Policy",
			"id": "15407",
			"name": "My Rules v1.6",
			"policy_type": "customer",
			"state": "locked",
			"customer_id": "0001",
			"platform_id": "adn",
			"created_at": "2018-10-09T15:52:33Z",
			"updated_at": "2018-10-09T16:00:44Z"
		}, {
			"@id": "/rules-engine/v1.1/policies/15409",
			"@type": "Policy",
			"id": "15409",
			"name": "My Rules v1.7",
			"policy_type": "customer",
			"state": "locked",
			"customer_id": "0001",
			"platform_id": "adn",
			"created_at": "2018-10-09T16:02:11Z",
			"updated_at": "2018-10-09T16:31:25Z"
		}, {
			"@id": "/rules-engine/v1.1/policies/15414",
			"@type": "Policy",
			"id": "15414",
			"name": "My Rules v1.8",
			"policy_type": "customer",
			"state": "locked",
			"customer_id": "0001",
			"platform_id": "adn",
			"created_at": "2018-10-09T16:50:32Z",
			"updated_at": "2018-10-09T16:51:21Z"
		}, {
			"@id": "/rules-engine/v1.1/policies/15415",
			"@type": "Policy",
			"id": "15415",
			"name": "My Rules v1.9",
			"policy_type": "customer",
			"state": "locked",
			"customer_id": "0001",
			"platform_id": "adn",
			"created_at": "2018-10-09T16:55:07Z",
			"updated_at": "2018-10-09T16:56:12Z"
		}
	],
	"total_items": 102
}