Update an item in a package
const url = 'https://example.com/api/items/example/_package/example/example';const options = { method: 'PUT', headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'}, body: '{"name":"My Updated Document","description":"example","slug":"my-document","status":"draft","taxonomies":[{"id":"example","name":"example","categories":[]}],"parent":"example","readPerm":["example"],"writePerm":["example"],"deletePerm":["example"],"fields":{"additionalProperty":"example"},"makeCurrent":true,"publish":true,"archive":true,"skipWorkflow":false}'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request PUT \ --url https://example.com/api/items/example/_package/example/example \ --header 'Authorization: Bearer <token>' \ --header 'Content-Type: application/json' \ --data '{ "name": "My Updated Document", "description": "example", "slug": "my-document", "status": "draft", "taxonomies": [ { "id": "example", "name": "example", "categories": [] } ], "parent": "example", "readPerm": [ "example" ], "writePerm": [ "example" ], "deletePerm": [ "example" ], "fields": { "additionalProperty": "example" }, "makeCurrent": true, "publish": true, "archive": true, "skipWorkflow": false }'Updates a content item within an update package. Supports JSON and multipart/form-data.
Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”Repository configuration ID
Package name
Item ID
Request Body
Section titled “Request Body”object
Item name
Example
My Updated DocumentItem description
URL slug
Example
my-documentPublication status
Taxonomy/category assignments
object
Taxonomy ID
Taxonomy name
Selected categories within this taxonomy
object
Category ID
Category name
Parent folder ID
Roles with read permission
Roles with write permission
Roles with delete permission
Custom field values defined by the content type
object
Whether to make this item the current version
Whether to publish the item
Archive the item
Bypass strict auto-package rules and save directly to the main repository. Requires the content.skip_workflow permission for the item’s type.
Example
falseResponses
Section titled “Responses”Item updated successfully
object
Unique item identifier
Item name
Content type name
Item description
URL-friendly slug
Searchable slug variant
Publication status
Assigned taxonomies and categories
object
Taxonomy ID
Taxonomy name
Selected categories within this taxonomy
object
Category ID
Category name
Current version number
Latest available version
Whether item is archived
Whether item is published
Whether this is a preview version
Whether this is the latest version
Whether this is the latest published version
Primary file extension
Creation timestamp (Unix ms)
Last update timestamp (Unix ms)
Publication timestamp (Unix ms)
Roles with read permission
Roles with write permission
Roles with delete permission
object
User’s username/login
User’s display name
User’s email address
object
User’s username/login
User’s display name
User’s email address
Parent folder ID
HTML preview for card display
Available renditions/files
object
Rendition name
Rendition type
File format/extension
URL to access the rendition
Storage details
object
Storage object name
Storage version ID
Object storage name
MIME type
File size in bytes
Original file name
Version history
object
object
User’s username/login
User’s display name
User’s email address
Example
{ "id": "CONT_ABC123", "name": "My Document", "type": "Article", "slug": "my-document", "status": "draft", "taxonomies": [], "currentVersion": "0.1", "latestVersion": "1.0", "fileExtension": "pdf", "createdDate": 1704067200000, "updatedDate": 1704153600000, "readPerm": [], "writePerm": [], "deletePerm": [], "createdByUser": { "userName": "user@example.com", "displayName": "John Doe", "email": "user@example.com" }, "updatedByUser": { "userName": "user@example.com", "displayName": "John Doe", "email": "user@example.com" }, "renditions": [ { "name": "native", "type": "native", "format": "jpg", "url": "/api/assets/repo/item123/native", "mimeType": "image/jpeg", "size": 1024, "fileName": "image.jpg" } ], "versionHistory": [ { "updatedByUser": { "userName": "user@example.com", "displayName": "John Doe", "email": "user@example.com" } } ]}Invalid request