Method: package.insert

Inserts a metadata-only package.

HTTP request

POST https://youtubepartner.googleapis.com/youtube/partner/v1/package

The URL uses gRPC Transcoding syntax.

Query parameters

Parameters
onBehalfOfContentOwner

string

The onBehalfOfContentOwner parameter identifies the content owner that the user is acting on behalf of. This parameter supports users whose accounts are associated with multiple content owners.

Request body

The request body contains an instance of Package.

Response body

A package resource and possible errors or warnings returned in response to package.insertrequest.

If successful, the response body contains data with the following structure:

JSON representation
{
  "status": string,
  "errors": [
    {
      object (ValidateError)
    }
  ],
  "kind": string,
  "resource": {
    object (Package)
  }
}
Fields
status

string

The package insert status. Indicates whether the insert operation completed successfully or identifies the general cause of failure. For most cases where the insert operation failed, the errors are described in the API response's errors object. However, if the operation failed because the package contained non-metadata files, the errors object is not included in the response.

errors[]

object (ValidateError)

The list of errors and/or warnings.

kind

string

The type of the API response. For this operation, the value is youtubePartner#packageInsert.

resource

object (Package)

The package resource.

Authorization scopes

Requires the following OAuth scope:

  • https://www.googleapis.com/auth/youtubepartner

For more information, see the OAuth 2.0 Overview.