Page Summary
-
This webpage details how to retrieve a list of a content owner's saved policies via the YouTube Partner API's
policies.listmethod. -
The HTTP request is a
GETmethod to the specified URL, and requires an empty request body. -
You can retrieve specific policies by providing a comma-separated list of policy IDs in the
idquery parameter and specify the content owner in theonBehalfOfContentOwnerquery parameter if needed. -
The response body will include a list of policies in JSON format with the
kindanditemsfields and also supports sorting by update time in ascending or descending order. -
To utilize this method, you will need the
https://www.googleapis.com/auth/youtubepartnerOAuth scope for authorization.
Retrieves a list of the content owner's saved policies.
HTTP request
GET https://youtubepartner.googleapis.com/youtube/partner/v1/policies
The URL uses gRPC Transcoding syntax.
Query parameters
| Parameters | |
|---|---|
id |
The |
onBehalfOfContentOwner |
The |
sort |
The |
Request body
The request body must be empty.
Response body
A list of policies returned in response to a policies.list call.
If successful, the response body contains data with the following structure:
| JSON representation |
|---|
{
"kind": string,
"items": [
{
object ( |
| Fields | |
|---|---|
kind |
The type of the API response. For this operation, the value is |
items[] |
A list of saved policies. |
Authorization scopes
Requires the following OAuth scope:
https://www.googleapis.com/auth/youtubepartner
For more information, see the OAuth 2.0 Overview.
Sort
Supported sorting orders.
| Enums | |
|---|---|
SORT_UNSPECIFIED |
Default value. |
TIME_UPDATED_ASC |
Sort by the update time ascending. |
TIME_UPDATED_DESC |
Sort by the update time descending. |