Conversation
There was a problem hiding this comment.
Pull request overview
Documents the new POST /v2/attachments/copy_all endpoint for copying reference files between forms, adding the OpenAPI schema/operation definitions and a new Attachments docs page.
Changes:
- Added
AttachmentCopyAllRequest/AttachmentCopyAllResponseschemas to the OpenAPI spec. - Defined
POST /v2/attachments/copy_allinreference/rest-api.json. - Added a new docs page and updated Attachments docs ordering to include it.
Reviewed changes
Copilot reviewed 6 out of 6 changed files in this pull request and generated 3 comments.
| File | Description |
|---|---|
| reference/rest-api.json | Adds request/response schemas and the copy_all endpoint definition. |
| reference/ATTACHMENTS/copy-all-attachments.md | New documentation page describing the endpoint and its limits. |
| reference/ATTACHMENTS/_order.yaml | Adds the new page to the Attachments docs navigation order. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| "parameters": [ | ||
| { | ||
| "name": "X-ApiToken", | ||
| "in": "header", | ||
| "description": "API Token. Required to authenticate the request.", | ||
| "required": true, | ||
| "schema": { | ||
| "type": "string" | ||
| } | ||
| } | ||
| ], |
There was a problem hiding this comment.
The auth header parameter name here uses X-ApiToken (and is marked required: true), but the other Attachments endpoints in this same spec use x-apitoken and omit required. To keep the generated docs consistent, align this endpoint with the existing Attachments header parameter convention (or omit the explicit header parameter entirely and rely on the global ApiToken security scheme).
| "$ref": "#/components/schemas/AttachmentCopyAllResponse" | ||
| } | ||
| } | ||
| } |
There was a problem hiding this comment.
This new endpoint only documents a 200 response. Other Attachments endpoints also document 401 Unauthorized; adding a 401 response here would make the OpenAPI spec more complete and consistent for API consumers.
| } | |
| } | |
| }, | |
| "401": { | |
| "description": "401", | |
| "content": { | |
| "application/json": { | |
| "examples": { | |
| "Result": { | |
| "value": "{\n \"error\": \"Unauthorized\"\n}" | |
| } | |
| }, | |
| "schema": { | |
| "type": "object", | |
| "properties": { | |
| "error": { | |
| "type": "string", | |
| "example": "Unauthorized" | |
| } | |
| } | |
| } | |
| } | |
| } |
| title: "" | ||
| description: "" | ||
| robots: noindex | ||
| next: | ||
| description: "" |
There was a problem hiding this comment.
Frontmatter in other Attachments docs uses single quotes for empty strings (e.g., title: ''), but this page uses double quotes (""). Consider switching to single quotes for consistency with the rest of the docs and to avoid potential formatting/linting differences.
| title: "" | |
| description: "" | |
| robots: noindex | |
| next: | |
| description: "" | |
| title: '' | |
| description: '' | |
| robots: noindex | |
| next: | |
| description: '' |
Description
This PR documents the new
copy_allAPI endpoint for copying reference files between forms, as requested in FLCRM-19499.Changes:
AttachmentCopyAllRequestandAttachmentCopyAllResponseschemas torest-api.json.POST /v2/attachments/copy_allendpoint inrest-api.json.copy-all-attachments.mddetails the endpoint and its current limits (100 files / form, 1GB / form)._order.yamlto include the new endpoint in the Attachments API documentation.Limits: