create_resource_hub_document
Endpoint#
| Property | Value |
|---|---|
| Type | mutation |
| Method | POST |
| Path | /api/external/v1/create_resource_hub_document |
| Handler | OperatelyWeb.Api.Mutations.CreateResourceHubDocument |
Authentication#
- Requires a valid API token.
- Requires a write-enabled token.
- Read-only tokens return
403.
Inputs#
| Field | Type | Required | Nullable | Default |
|---|---|---|---|---|
resource_hub_id | id primitive (encoded as string) | No | Yes | - |
folder_id | id primitive (encoded as string) | No | Yes | - |
name | string | No | Yes | - |
content | string | No | Yes | - |
post_as_draft | boolean | No | Yes | - |
send_notifications_to_everyone | boolean | No | Yes | - |
subscriber_ids | array of id primitive (encoded as string) | No | Yes | - |
copied_document_id | id primitive (encoded as string) | No | Yes | - |
Outputs#
| Field | Type | Required | Nullable |
|---|---|---|---|
document | document | No | Yes |
cURL Example#
Copied
curl --request POST \
--url "https://app.operately.com/api/external/v1/create_resource_hub_document" \
--header "Authorization: Bearer ${OPERATELY_API_TOKEN}" \
--header "Content-Type: application/json" \
--data '{"content":"value", "copied_document_id":"value", "folder_id":"value", "name":"value", "post_as_draft":true, "resource_hub_id":"value", "send_notifications_to_everyone":true, "subscriber_ids":["value"]}'Response Example#
{
"document": "<document>"
}