Page Widgets

Upload a file to a page widget

Uploads a file to an Image or File widget on a draft page revision. Replaces the existing file, if any.

Accepts multipart form data (field file) or JSON with base64-encoded content (field fileBase64). Maximum file size: 20 MB for multipart, 10 MB for base64. You can also send JSON { "fileUploadId": "..." } to attach a file you uploaded with createFileUpload; the fileUploadId is single-use. For Image widgets, only image/* content types are accepted.

post/pages/{pageId}/revisions/{revisionId}/widgets/{widgetId}/upload

Request

  • Base URL
    https://public-api.process.st/api/v1.1
  • URL
    https://public-api.process.st/api/v1.1/pages/{pageId}/revisions/{revisionId}/widgets/{widgetId}/upload
  • Auth
    • API key in header X-API-Key
    • or HTTP bearer

Path parameters

pageIdstring required

The ID of the Page

revisionIdstring required

The ID of the Revision

widgetIdstring required

The ID of the Widget

Request body

filestring binary

Uploaded file reference. Use the upload endpoint to attach content.

fileUploadIdstring

Response

Example response

{
  "data": {
    "id": "qB2llZ1xDP0BoZxtcpJ9iw",
    "taskId": "qB2llZ1xDP0BoZxtcpJ9iw",
    "createdBy": {
      "id": "paiZa0_oyxEBoZxtatp33g",
      "email": "jane.doe@example.com",
      "username": "Jane Doe"
    },
    "updatedBy": {
      "id": "paiZa0_oyxEBoZxtatp33g",
      "email": "jane.doe@example.com",
      "username": "Jane Doe"
    },
    "links": [
      {
        "href": "https://api.process.st/api/v1.1/resource/XXX"
      }
    ]
  },
  "links": [
    {
      "href": "https://api.process.st/api/v1.1/resource/XXX"
    }
  ]
}

Changes

No recorded changes to this operation across all 16 revisions of this API.