Posts: update

This method is in a pilot phase with access limited to select launch partners (approved Google Cloud projects). Broader public API access is planned for General Availability in 2027.

Updates the text of a post. You can't add, remove, or replace a post's images.

Quota impact: A call to this method has a quota cost of 1 unit. The cost counts against the Post Modifications and Image Uploads quota, which is separate from the default YouTube Data API quota.

Request

HTTP request

PUT https://www.googleapis.com/youtube/v3/posts

Authorization

This request requires authorization with at least one of the following scopes (read more about authentication and authorization).

Scope
https://www.googleapis.com/auth/youtubepartner
https://www.googleapis.com/auth/youtube
https://www.googleapis.com/auth/youtube.force-ssl

The authorized user must own the channel that published the post or have permission to edit its posts.

Parameters

The following table lists the parameters that this query supports. All of the parameters listed are query parameters.

Parameters
Required parameters
part string
The part parameter serves two purposes in this operation. It identifies the properties that the write operation sets as well as the properties that the API response includes.

Set the parameter value to snippet. You can also include id, attachments, and status to add those properties to the response.

Request body

Provide a post resource in the request body. For that resource, you must specify a value for these properties:

  • id
  • snippet.textDisplay

The API updates only the snippet.textDisplay property.

Response

If successful, this method returns a post resource in the response body.

Errors

The following table identifies error messages that the API could return in response to a call to this method. For more detail, see the error message documentation.

Error type Error detail Description
invalidValue (400) invalidMetadata The request contains invalid metadata values.
forbidden (403) forbidden The request is not properly authorized.
rateLimitExceeded (403) rateLimitExceeded The request cannot be completed because you have exceeded your rate limit.
notFound (404) postNotFound The specified post was not found.