Records
Update a record (compare-and-set with expected_version)
PATCH
header
AuthorizationBearer <token>Your space key (om_...). Create one with POST /v1/spaces.
collection*stringCollection name, e.g. commitments, goals, routines.
Match
^[A-Za-z0-9][A-Za-z0-9_.-]*$Length
1 <= length <= 64id*stringLength
1 <= length <= 64application/json- body
status?stringLength
length <= 50due_at?|Format
date-timedata?Shallow-merged into the existing data. Set a field to null to clear it.
expected_version?integerFail with 409 unless the record is at this version.
Range
1 <= valueUpdated
application/json- response
id*stringcollection*stringkey*string|nullstatus*stringdue_at*string|nulldata*origin*OriginValue in
"user""agent""dream"version*integercreated_at*stringupdated_at*stringcurl -X PATCH 'https://api.openmemory.sh/v1/collections/string/records/string' \ -H 'Content-Type: application/json' \ -d '{}'Example Response
{ "id": "string", "collection": "string", "key": "string", "status": "string", "due_at": "string", "data": { "property1": null, "property2": null }, "origin": "user", "version": 0, "created_at": "string", "updated_at": "string"}Query records by status, key, or due date GET
Ordered by due date (undated last), then creation. Page with next_cursor.
Remove your OpenAI key DELETE
Deletes the encrypted key for good and goes back to the server's default embeddings. Your facts are re-embedded. Also revoke the key at OpenAI if you think it leaked.