# Change a content plan

`PATCH /workspace/content/plans/{id}` · Rivier · content

Change a content plan.

- Scope: content:write
- Graphql: Mutation.contentPlanUpdate
- Sdk: content.plan.update
- Cli: content plan update

## Parameters

- `id` (path, required), string

## Request body

`application/json`

```json
{
  "type": "object",
  "properties": {
    "name": {
      "type": "string",
      "minLength": 1,
      "maxLength": 120
    },
    "topic": {
      "type": "string",
      "maxLength": 2000
    },
    "channels": {
      "type": "array",
      "items": {
        "type": "string",
        "enum": [
          "linkedin",
          "facebook",
          "instagram",
          "x",
          "tiktok",
          "threads",
          "mastodon",
          "discord",
          "telegram",
          "youtube",
          "snapchat",
          "medium"
        ]
      },
      "minItems": 1,
      "maxItems": 7
    },
    "agentId": {
      "anyOf": [
        {
          "type": "string",
          "format": "uuid"
        },
        {
          "type": "null"
        }
      ]
    },
    "days": {
      "type": "array",
      "items": {
        "type": "integer",
        "minimum": 0,
        "maximum": 6
      },
      "maxItems": 7
    },
    "atHour": {
      "type": "integer",
      "minimum": 0,
      "maximum": 23
    },
    "atMinute": {
      "type": "integer",
      "minimum": 0,
      "maximum": 59
    },
    "timezone": {
      "type": "string",
      "maxLength": 64
    },
    "autopublish": {
      "type": "boolean"
    }
  },
  "additionalProperties": false
}
```

## Responses

- `200`: Success
- `400`: The request was malformed
- `401`: No valid credential
- `403`: The credential lacks the scope, origin or address
- `429`: Over the key's rate limit; see Retry-After

## Example

```sh
curl -X PATCH 'https://api.rivier.ai/workspace/content/plans/{id}' \
  -H 'Authorization: Bearer $KEY' \
  -H 'Content-Type: application/json' \
  -d '{
  "name": "string",
  "topic": "string",
  "channels": [
    "linkedin"
  ],
  "agentId": "string",
  "days": [
    0
  ],
  "atHour": 0,
  "atMinute": 0,
  "timezone": "string"
}'
```
