Skip to content

Docs

request_review

Ask a person to review a content item, with an optional `note` for the reviewer (what to look at, what changed). The content's owner gets an Update and a notification, and decides how it is reviewed: they create the review link and send it (review links are made by people, not agents), or review it themselves. The request stays open until a review link is created or a verdict or approval is recorded; asking again while it is open returns it (`alreadyRequested: true`) and notifies no one again. It shares, approves, schedules and publishes nothing. Approval is a state: when the content requires approval, nothing on it can be scheduled or posted until a reviewer approves the current text. `recipients` names who was told; `url` is the content page to give the person. Pass `approverAccountId` (an owner, editor or approver, from list_members) to ask one teammate to approve it instead of the owner.

Ask a person to review a content item, with an optional note for the reviewer (what to look at, what changed). The content's owner gets an Update and a notification, and decides how it is reviewed: they create the review link and send it (review links are made by people, not agents), or review it themselves. The request stays open until a review link is created or a verdict or approval is recorded; asking again while it is open returns it (alreadyRequested: true) and notifies no one again. It shares, approves, schedules and publishes nothing. Approval is a state: when the content requires approval, nothing on it can be scheduled or posted until a reviewer approves the current text. recipients names who was told; url is the content page to give the person. Pass approverAccountId (an owner, editor or approver, from list_members) to ask one teammate to approve it instead of the owner.

Access and cost

  • Kind: mutation
  • Scope: workspace
  • Actors: member, agent
  • Credits: Free
  • Requires confirmation: false
  • Accepts idempotency key: false

Input schema

{
  "properties": {
    "workspaceId": {
      "format": "uuid",
      "type": "string"
    },
    "pieceId": {
      "format": "uuid",
      "type": "string"
    },
    "note": {
      "maxLength": 1000,
      "minLength": 1,
      "type": "string"
    },
    "approverAccountId": {
      "format": "uuid",
      "type": "string"
    }
  },
  "required": [
    "workspaceId",
    "pieceId"
  ],
  "type": "object"
}

Output schema

{
  "additionalProperties": false,
  "properties": {
    "reviewRequest": {
      "additionalProperties": false,
      "properties": {
        "id": {
          "format": "uuid",
          "type": "string"
        },
        "pieceId": {
          "format": "uuid",
          "type": "string"
        },
        "note": {
          "type": [
            "string",
            "null"
          ]
        },
        "requestedBy": {
          "additionalProperties": false,
          "properties": {
            "kind": {
              "enum": [
                "member",
                "guest",
                "agent",
                "system"
              ],
              "type": "string"
            },
            "accountId": {
              "anyOf": [
                {
                  "format": "uuid",
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ]
            },
            "agentClientId": {
              "anyOf": [
                {
                  "format": "uuid",
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ]
            },
            "guestId": {
              "anyOf": [
                {
                  "format": "uuid",
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ]
            },
            "name": {
              "type": "string"
            }
          },
          "required": [
            "kind",
            "accountId",
            "agentClientId",
            "guestId",
            "name"
          ],
          "type": "object"
        },
        "createdAt": {
          "format": "date-time",
          "type": "string"
        }
      },
      "required": [
        "id",
        "pieceId",
        "note",
        "requestedBy",
        "createdAt"
      ],
      "type": "object"
    },
    "alreadyRequested": {
      "type": "boolean"
    },
    "recipients": {
      "items": {
        "additionalProperties": false,
        "properties": {
          "kind": {
            "enum": [
              "member",
              "guest",
              "agent",
              "system"
            ],
            "type": "string"
          },
          "accountId": {
            "anyOf": [
              {
                "format": "uuid",
                "type": "string"
              },
              {
                "type": "null"
              }
            ]
          },
          "agentClientId": {
            "anyOf": [
              {
                "format": "uuid",
                "type": "string"
              },
              {
                "type": "null"
              }
            ]
          },
          "guestId": {
            "anyOf": [
              {
                "format": "uuid",
                "type": "string"
              },
              {
                "type": "null"
              }
            ]
          },
          "name": {
            "type": "string"
          }
        },
        "required": [
          "kind",
          "accountId",
          "agentClientId",
          "guestId",
          "name"
        ],
        "type": "object"
      },
      "type": "array"
    },
    "url": {
      "description": "The content page in heyeveryone. Give it to the person so they can open the draft.",
      "type": "string"
    }
  },
  "required": [
    "reviewRequest",
    "alreadyRequested",
    "recipients",
    "url"
  ],
  "type": "object"
}

Errors

[]

Annotations

{
  "destructiveHint": false,
  "idempotentHint": true,
  "openWorldHint": false,
  "readOnlyHint": false,
  "title": "Ask for a review"
}