-
Notifications
You must be signed in to change notification settings - Fork 7
Description
Have you read a contributing guide?
- I have read CONTRIBUTING.md
- I have searched the existing requests and didn't find any that were similar
- I have considered creating a pull request instead and want to proceed
Clear and concise description of the problem
Currently, the PATCH /objects/{id}
endpoint only allows updating object metadata (name, properties, etc.) but does not support updating the object's content body. This creates an inconsistency with the create endpoint and limits programmatic content management.
See relevent docs for create and update
Current Behavior
POST /objects
(create) supportsbody
parameter ✅PATCH /objects/{id}
(update) does NOT supportbody
parameter ❌- To update object content, users must manually edit within the Anytype application
Expected Behavior
The update endpoint should support a body
parameter to modify object content, similar to the create endpoint.
Use Case
Programmatic workflows need to update object content via API, such as:
- Automated content generation
- Content synchronization from external systems
- Developer logs and documentation updates
- Integration with content management systems
Suggested solution
Add body
parameter support to the PATCH /objects/{id}
endpoint, consistent with the create endpoint:
PATCH /objects/{object_id}
{
"space_id": "xxx",
"name": "Updated Title",
"body": "### Updated Content\nNew content here."
}
Alternative
Create a dedicated content update endpoint like PATCH /objects/{id}/content
if adding body support to the main update endpoint is complex.
Additional context
This feature is essential for automated workflows like content generation, external system synchronization, and developer tooling. Currently users must manually edit content in the Anytype app, breaking automation pipelines.