{"openapi":"3.1.0","info":{"title":"SDK Reference","version":"1.0.0"},"paths":{"/threads":{"get":{"operationId":"thread_getThreads","summary":"Get threads","description":"Returns all threads.","tags":["thread"],"parameters":[{"name":"page_number","in":"query","description":"Page number for pagination, starting from 1","required":false,"schema":{"type":"integer"}},{"name":"page_size","in":"query","description":"Number of threads to retrieve per page.","required":false,"schema":{"type":"integer"}},{"name":"order_by","in":"query","description":"Field to order the results by: created_at, updated_at, user_id, thread_id.","required":false,"schema":{"type":"string"}},{"name":"asc","in":"query","description":"Order direction: true for ascending, false for descending.","required":false,"schema":{"type":"boolean"}}],"responses":{"200":{"description":"List of threads","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.ThreadListResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}}},"post":{"operationId":"thread_startANewThread","summary":"Start a new thread.","description":"Start a new thread.","tags":["thread"],"responses":{"201":{"description":"The thread object.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.Thread"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}},"requestBody":{"description":"Thread","content":{"application/json":{"schema":{"$ref":"#/components/schemas/models.CreateThreadRequest"}}}}}},"/threads/{threadId}":{"delete":{"operationId":"thread_deleteThread","summary":"Delete thread","description":"Deletes a thread.","tags":["thread"],"parameters":[{"name":"threadId","in":"path","description":"The ID of the thread for which memory should be deleted.","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.SuccessResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}}}},"/threads/{threadId}/context":{"get":{"operationId":"thread_getUserContext","summary":"Get user context","description":"Returns most relevant context from the user graph (including memory from any/all past threads) based on the content of the past few messages of the given thread.","tags":["thread"],"parameters":[{"name":"threadId","in":"path","description":"The ID of the current thread (for which context is being retrieved).","required":true,"schema":{"type":"string"}},{"name":"template_id","in":"query","description":"Optional template ID to use for custom context rendering.","required":false,"schema":{"type":"string"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.ThreadContextResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}}}},"/threads/{threadId}/messages":{"get":{"operationId":"thread_getMessagesOfAThread","summary":"Get messages of a thread","description":"Returns messages for a thread.","tags":["thread"],"parameters":[{"name":"threadId","in":"path","description":"Thread ID","required":true,"schema":{"type":"string"}},{"name":"limit","in":"query","description":"Limit the number of results returned","required":false,"schema":{"type":"integer"}},{"name":"cursor","in":"query","description":"Cursor for pagination","required":false,"schema":{"type":"integer"}},{"name":"lastn","in":"query","description":"Number of most recent messages to return (overrides limit and cursor)","required":false,"schema":{"type":"integer"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.ThreadMessageListResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}}},"post":{"operationId":"thread_addMessagesToAThread","summary":"Add messages to a thread","description":"Add messages to a thread.","tags":["thread"],"parameters":[{"name":"threadId","in":"path","description":"The ID of the thread to which messages should be added.","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"An object, optionally containing user context retrieved for the last thread message","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.AddThreadMessagesResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}},"requestBody":{"description":"An object representing the thread messages to be added.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.AddThreadMessagesRequest"}}}}}},"/threads/{threadId}/episodes":{"get":{"operationId":"thread_getEpisodesForAThread","summary":"Get Episodes for a thread","description":"Returns graph episodes associated with a thread. Parallel to get_episodes_for_document for documents.","tags":["thread"],"parameters":[{"name":"threadId","in":"path","description":"The ID of the thread","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Episodes","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.GraphEpisodeResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}}}},"/threads/{threadId}/messages-batch":{"post":{"operationId":"thread_addMessagesToAThreadInBatch","summary":"Add messages to a thread in batch","description":"Deprecated. Use the [Batch API](/adding-batch-data) (`client.batch.*` with `type: \"thread_message\"`) instead.\n\nAdds messages to a thread in batch mode, processing messages concurrently.\n","tags":["thread"],"parameters":[{"name":"threadId","in":"path","description":"The ID of the thread to which messages should be added.","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"An object, optionally containing user context retrieved for the last thread message","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.AddThreadMessagesResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}},"deprecated":true,"requestBody":{"description":"An object representing the thread messages to be added.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.AddThreadMessagesRequest"}}}}}},"/threads/{threadId}/summary":{"get":{"operationId":"thread_getThreadSummary","summary":"Get thread summary","description":"Returns the incremental summary generated from messages in the thread. Returns 404 if no summary exists for the thread.","tags":["thread"],"parameters":[{"name":"threadId","in":"path","description":"The thread ID.","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.ThreadSummary"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}}}},"/messages/{messageUUID}":{"patch":{"operationId":"updatesAMessage","summary":"Updates a message.","description":"Updates a message.","parameters":[{"name":"messageUUID","in":"path","description":"The UUID of the message.","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"The updated message.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.ThreadMessage"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}},"requestBody":{"description":"The updates.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/models.ThreadMessageUpdate"}}}}}},"/users":{"post":{"operationId":"user_add","summary":"Add User","description":"Adds a user.","tags":["user"],"responses":{"201":{"description":"The user that was added.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.User"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}},"requestBody":{"description":"The user to add.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.CreateUserRequest"}}}}}},"/users-ordered":{"get":{"operationId":"user_listOrdered","summary":"Get Users","description":"Returns all users.","tags":["user"],"parameters":[{"name":"pageNumber","in":"query","description":"Page number for pagination, starting from 1","required":false,"schema":{"type":"integer"}},{"name":"pageSize","in":"query","description":"Number of users to retrieve per page","required":false,"schema":{"type":"integer"}},{"name":"search","in":"query","description":"Search term for filtering users by user_id, name, or email","required":false,"schema":{"type":"string"}},{"name":"order_by","in":"query","description":"Column to sort by (created_at, user_id, email)","required":false,"schema":{"type":"string"}},{"name":"asc","in":"query","description":"Sort in ascending order","required":false,"schema":{"type":"boolean"}}],"responses":{"200":{"description":"Successfully retrieved list of users","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.UserListResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}}}},"/users/{userId}":{"get":{"operationId":"user_get","summary":"Get User","description":"Returns a user.","tags":["user"],"parameters":[{"name":"userId","in":"path","description":"The user_id of the user to get.","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"The user that was retrieved.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.User"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}}},"delete":{"operationId":"user_delete","summary":"Delete User","description":"Deletes a user.","tags":["user"],"parameters":[{"name":"userId","in":"path","description":"User ID","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.SuccessResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}}},"patch":{"operationId":"user_update","summary":"Update User","description":"Updates a user.","tags":["user"],"parameters":[{"name":"userId","in":"path","description":"User ID","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"The user that was updated.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.User"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}},"requestBody":{"description":"Update User Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.UpdateUserRequest"}}}}}},"/users/{userId}/node":{"get":{"operationId":"user_getUserNode","summary":"Get User Node","description":"Returns a user's node.","tags":["user"],"parameters":[{"name":"userId","in":"path","description":"The user_id of the user to get the node for.","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Response object containing the User node.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.UserNodeResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}}}},"/users/{userId}/threads":{"get":{"operationId":"user_getUserThreads","summary":"Get User Threads","description":"Returns all threads for a user.","tags":["user"],"parameters":[{"name":"userId","in":"path","description":"User ID","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/apidata.Thread"}}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}}}},"/users/{userId}/warm":{"get":{"operationId":"user_warmUserCache","summary":"Warm User Cache","description":"Hints Zep to warm a user's graph for low-latency search","tags":["user"],"parameters":[{"name":"userId","in":"path","description":"User ID","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Warm hint accepted","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.SuccessResponse"}}}},"404":{"description":"User or graph not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}}}},"/user-summary-instructions":{"get":{"operationId":"user_listUserInstructions","summary":"List User Instructions","description":"Lists all user summary instructions for a project, user.","tags":["user"],"parameters":[{"name":"user_id","in":"query","description":"User ID to get user-specific instructions","required":false,"schema":{"type":"string"}}],"responses":{"200":{"description":"The list of instructions.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.ListUserInstructionsResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}}},"post":{"operationId":"user_addUserInstructions","summary":"Add User Instructions","description":"Adds new summary instructions for users graphs without removing existing ones. If user_ids is empty, adds to project-wide default instructions.","tags":["user"],"responses":{"200":{"description":"Instructions added successfully","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.SuccessResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}},"requestBody":{"description":"The instructions to add","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.AddUserInstructionsRequest"}}}}},"delete":{"operationId":"user_deleteUserInstructions","summary":"Delete User Instructions","description":"Deletes user summary/instructions for users or project wide defaults.","tags":["user"],"responses":{"200":{"description":"Instructions deleted successfully","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.SuccessResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}},"requestBody":{"description":"The instructions to delete","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.DeleteUserInstructionsRequest"}}}}}},"/user-groups":{"get":{"operationId":"userGroup_list","summary":"List UserGroups","tags":["userGroup"],"parameters":[{"name":"projectId","in":"query","description":"Project UUID","required":true,"schema":{"type":"string"}},{"name":"pageNumber","in":"query","description":"Page number","required":true,"schema":{"type":"integer"}},{"name":"pageSize","in":"query","description":"Page size","required":true,"schema":{"type":"integer"}},{"name":"search","in":"query","description":"Name search","required":false,"schema":{"type":"string"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.UserGroupListResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}},"security":[{"Api-Key":[]}]},"post":{"operationId":"userGroup_create","summary":"Create a managed UserGroup","tags":["userGroup"],"parameters":[{"name":"projectId","in":"query","description":"Project UUID","required":true,"schema":{"type":"string"}}],"responses":{"201":{"description":"Created","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.UserGroupResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"409":{"description":"Conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}},"requestBody":{"description":"Managed group","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.CreateUserGroupRequest"}}}},"security":[{"Api-Key":[]}]}},"/user-groups/users/{userUUID}":{"get":{"operationId":"userGroup_list_for_user","summary":"List effective UserGroups for a User","tags":["userGroup"],"parameters":[{"name":"userUUID","in":"path","description":"User UUID","required":true,"schema":{"type":"string"}},{"name":"projectId","in":"query","description":"Project UUID","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.UserMembershipGroupsResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}},"security":[{"Api-Key":[]}]}},"/user-groups/{groupUUID}":{"get":{"operationId":"userGroup_get","summary":"Get a UserGroup","tags":["userGroup"],"parameters":[{"name":"groupUUID","in":"path","description":"UserGroup UUID","required":true,"schema":{"type":"string"}},{"name":"projectId","in":"query","description":"Project UUID","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.UserGroupResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}},"security":[{"Api-Key":[]}]},"patch":{"operationId":"userGroup_update","summary":"Update a managed UserGroup","tags":["userGroup"],"parameters":[{"name":"groupUUID","in":"path","description":"UserGroup UUID","required":true,"schema":{"type":"string"}},{"name":"projectId","in":"query","description":"Project UUID","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.UserGroupResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"409":{"description":"Conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}},"requestBody":{"description":"Updated group","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.UpdateUserGroupRequest"}}}},"security":[{"Api-Key":[]}]},"delete":{"operationId":"userGroup_delete","summary":"Delete a managed UserGroup","tags":["userGroup"],"parameters":[{"name":"groupUUID","in":"path","description":"UserGroup UUID","required":true,"schema":{"type":"string"}},{"name":"projectId","in":"query","description":"Project UUID","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"No Content","content":{"application/json":{"schema":{"type":"object","properties":{}}}}}},"security":[{"Api-Key":[]}]}},"/user-groups/{groupUUID}/members":{"get":{"operationId":"userGroup_list_members","summary":"List UserGroup members","tags":["userGroup"],"parameters":[{"name":"groupUUID","in":"path","description":"UserGroup UUID","required":true,"schema":{"type":"string"}},{"name":"projectId","in":"query","description":"Project UUID","required":true,"schema":{"type":"string"}},{"name":"pageNumber","in":"query","description":"Page number","required":true,"schema":{"type":"integer"}},{"name":"pageSize","in":"query","description":"Page size","required":true,"schema":{"type":"integer"}},{"name":"search","in":"query","description":"User search","required":false,"schema":{"type":"string"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.UserGroupMembersResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}},"security":[{"Api-Key":[]}]},"post":{"operationId":"userGroup_add_members","summary":"Add members to a managed UserGroup","tags":["userGroup"],"parameters":[{"name":"groupUUID","in":"path","description":"UserGroup UUID","required":true,"schema":{"type":"string"}},{"name":"projectId","in":"query","description":"Project UUID","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.UserGroupMembershipResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"409":{"description":"Conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}},"requestBody":{"description":"User UUIDs","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.MutateUserGroupMembersRequest"}}}},"security":[{"Api-Key":[]}]}},"/user-groups/{groupUUID}/members/bulk-remove":{"post":{"operationId":"userGroup_remove_members","summary":"Remove members from a managed UserGroup","tags":["userGroup"],"parameters":[{"name":"groupUUID","in":"path","description":"UserGroup UUID","required":true,"schema":{"type":"string"}},{"name":"projectId","in":"query","description":"Project UUID","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.UserGroupMembershipResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"409":{"description":"Conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}},"requestBody":{"description":"User UUIDs","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.MutateUserGroupMembersRequest"}}}},"security":[{"Api-Key":[]}]}},"/user-groups/{groupUUID}/members/candidates":{"get":{"operationId":"userGroup_list_member_candidates","summary":"List Users eligible to join a UserGroup","tags":["userGroup"],"parameters":[{"name":"groupUUID","in":"path","description":"UserGroup UUID","required":true,"schema":{"type":"string"}},{"name":"projectId","in":"query","description":"Project UUID","required":true,"schema":{"type":"string"}},{"name":"pageNumber","in":"query","description":"Page number","required":true,"schema":{"type":"integer"}},{"name":"pageSize","in":"query","description":"Page size","required":true,"schema":{"type":"integer"}},{"name":"search","in":"query","description":"User search","required":false,"schema":{"type":"string"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.UserGroupMembersResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"409":{"description":"Conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}},"security":[{"Api-Key":[]}]}},"/user-groups/{groupUUID}/members/{userUUID}":{"delete":{"operationId":"userGroup_remove_member","summary":"Remove one member from a managed UserGroup","tags":["userGroup"],"parameters":[{"name":"groupUUID","in":"path","description":"UserGroup UUID","required":true,"schema":{"type":"string"}},{"name":"userUUID","in":"path","description":"User UUID","required":true,"schema":{"type":"string"}},{"name":"projectId","in":"query","description":"Project UUID","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.UserGroupMembershipResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"409":{"description":"Conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}},"security":[{"Api-Key":[]}]}},"/abac/user-groups/{groupUUID}/policy-sets":{"get":{"operationId":"userGroup_list_policy_sets","summary":"List policy sets attached to a UserGroup","tags":["userGroup"],"parameters":[{"name":"groupUUID","in":"path","description":"UserGroup UUID","required":true,"schema":{"type":"string"}},{"name":"projectId","in":"query","description":"Project UUID","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.AttachedPolicySetsResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}}},"post":{"operationId":"userGroup_attach_policy_set","summary":"Attach a policy set to a UserGroup","tags":["userGroup"],"parameters":[{"name":"groupUUID","in":"path","description":"UserGroup UUID","required":true,"schema":{"type":"string"}},{"name":"projectId","in":"query","description":"Project UUID","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.AttachedPolicySetsResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}},"requestBody":{"description":"Policy set UUID","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.AttachPolicySetRequest"}}}}}},"/abac/user-groups/{groupUUID}/policy-sets/{policySetUUID}":{"delete":{"operationId":"userGroup_detach_policy_set","summary":"Detach a policy set from a UserGroup","tags":["userGroup"],"parameters":[{"name":"groupUUID","in":"path","description":"UserGroup UUID","required":true,"schema":{"type":"string"}},{"name":"policySetUUID","in":"path","description":"Policy set UUID","required":true,"schema":{"type":"string"}},{"name":"projectId","in":"query","description":"Project UUID","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.AttachedPolicySetsResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}}}},"/context-templates":{"post":{"operationId":"context_createContextTemplate","summary":"Create Context Template","description":"Creates a new context template.","tags":["context"],"responses":{"200":{"description":"The created context template.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.ContextTemplateResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}},"requestBody":{"description":"The context template to create","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.CreateContextTemplateRequest"}}}}},"get":{"operationId":"context_listContextTemplates","summary":"List Context Templates","description":"Lists all context templates.","tags":["context"],"responses":{"200":{"description":"The list of context templates.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.ListContextTemplatesResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}}}},"/context-templates/{template_id}":{"get":{"operationId":"context_getContextTemplate","summary":"Get Context Template","description":"Retrieves a context template by template_id.","tags":["context"],"parameters":[{"name":"template_id","in":"path","description":"Template ID","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"The context template.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.ContextTemplateResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}}},"put":{"operationId":"context_updateContextTemplate","summary":"Update Context Template","description":"Updates an existing context template by template_id.","tags":["context"],"parameters":[{"name":"template_id","in":"path","description":"Template ID","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"The updated context template.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.ContextTemplateResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}},"requestBody":{"description":"The updated template content","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.UpdateContextTemplateRequest"}}}}},"delete":{"operationId":"context_deleteContextTemplate","summary":"Delete Context Template","description":"Deletes a context template by template_id.","tags":["context"],"parameters":[{"name":"template_id","in":"path","description":"Template ID","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Template deleted successfully","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.SuccessResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}}}},"/graph/set-ontology":{"put":{"operationId":"graph_set_ontology","summary":"Set graph ontology","description":"Sets custom entity and edge types for your graph. This wrapper method\nprovides a clean interface for defining your graph schema with custom\nentity and edge types.\n\nSee the [full documentation](/customizing-graph-structure#setting-entity-and-edge-types) for details.\n","tags":["graph"],"responses":{"200":{"description":"Ontology set successfully","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.SuccessResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"entities":{"$ref":"#/components/schemas/GraphSetOntologyPutRequestBodyContentApplicationJsonSchemaEntities","description":"Dictionary mapping entity type names to their definitions"},"edges":{"$ref":"#/components/schemas/GraphSetOntologyPutRequestBodyContentApplicationJsonSchemaEdges","description":"Dictionary mapping edge type names to their definitions with source/target constraints"},"user_ids":{"type":"array","items":{"type":"string"},"description":"Optional list of user IDs to apply ontology to"},"graph_ids":{"type":"array","items":{"type":"string"},"description":"Optional list of graph IDs to apply ontology to"}}}}}}}},"/graph/list-ontology":{"get":{"operationId":"graph_list_ontology","summary":"List graph ontology","description":"Retrieves the current entity and edge types configured for your graph.\n\nSee the [full documentation](/customizing-graph-structure) for details.\n","tags":["graph"],"responses":{"200":{"description":"Current ontology","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.EntityTypeResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}}}},"/graph":{"post":{"operationId":"data_addData","summary":"Add Data","description":"Add data to the graph.","tags":["data"],"responses":{"202":{"description":"Added episode","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.GraphEpisode"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}},"requestBody":{"description":"Add data request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.AddDataRequest"}}}}}},"/graph-batch":{"post":{"operationId":"data_addDataInBatchMode","summary":"Add Data in batch mode","description":"Deprecated. Use the [Batch API](/adding-batch-data) (`client.batch.*`) instead.\n\nAdds data to the graph in batch mode, processing episodes concurrently.\n","tags":["data"],"responses":{"202":{"description":"Added episodes","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/apidata.GraphEpisode"}}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}},"deprecated":true,"requestBody":{"description":"Add data request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.AddDataBatchRequest"}}}}}},"/graph/add-fact-triple":{"post":{"operationId":"entity_addFactTriple","summary":"Add Fact Triple","description":"Add a fact triple for a user or group","tags":["entity"],"responses":{"200":{"description":"Resulting triple","content":{"application/json":{"schema":{"$ref":"#/components/schemas/graphiti.AddTripleResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}},"requestBody":{"description":"Triple to add","content":{"application/json":{"schema":{"$ref":"#/components/schemas/graphiti.AddTripleRequest"}}}}}},"/graph/clone":{"post":{"operationId":"data_cloneGraph","summary":"Clone graph","description":"Clone a user or group graph.","tags":["data"],"responses":{"202":{"description":"Response object containing graph_id or user_id pointing to the new graph","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.CloneGraphResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}},"requestBody":{"description":"Clone graph request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.CloneGraphRequest"}}}}}},"/graph/create":{"post":{"operationId":"graph_createGraph","summary":"Create Graph","description":"Creates a new graph.","tags":["graph"],"responses":{"201":{"description":"The added graph","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.Graph"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}},"requestBody":{"description":"Graph","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.CreateGraphRequest"}}}}}},"/graph/list-all":{"get":{"operationId":"graph_listStandaloneGraphsInTheGraphDirectory","summary":"List standalone graphs in the graph directory","description":"Returns a paginated directory of live standalone graphs in the\nauthenticated project. Optional `search` matches `graph_id`, `name`, and\n`description` (metadata only; not graph contents).\n\nDefault `pageSize` is 50 (range 1–100). To list users, use\n`user.list_ordered` instead. See the\n[graph directory guide](/graph-directory) for pagination, relevance\nordering, and Memory MCP exposure.\n","tags":["graph"],"parameters":[{"name":"pageNumber","in":"query","description":"Page number for pagination, starting from 1.","required":false,"schema":{"type":"integer"}},{"name":"pageSize","in":"query","description":"Number of graphs to retrieve per page (default 50, range 1-100; explicit 0 is invalid).","required":false,"schema":{"type":"integer","minimum":1,"maximum":100}},{"name":"search","in":"query","description":"Search term for filtering graphs by graph_id, name, or description. Queries longer than 200 Unicode code points after whitespace normalization are invalid.","required":false,"schema":{"type":"string"}},{"name":"order_by","in":"query","description":"Column to sort by (created_at, graph_id, name).","required":false,"schema":{"type":"string"}},{"name":"asc","in":"query","description":"Sort in ascending order.","required":false,"schema":{"type":"boolean"}}],"responses":{"200":{"description":"Successfully retrieved list of graphs.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.GraphListResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}}}},"/graph/patterns":{"post":{"operationId":"graph_detectPatternsExperimental","summary":"Detect Patterns (Experimental)","description":"Deprecated. Pattern detection is not part of Public API v4.\nDetects structural patterns in a knowledge graph including relationship frequencies,\nmulti-hop paths, co-occurrences, hubs, and clusters.\nWhen a query is provided, uses hybrid search to discover seed nodes,\ndetects triple-frequency patterns, and returns resolved edges ranked by relevance.","tags":["graph"],"responses":{"200":{"description":"Detected patterns","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.DetectPatternsResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}},"deprecated":true,"requestBody":{"description":"Pattern detection request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.DetectPatternsRequest"}}}}}},"/graph/search":{"post":{"operationId":"search_graph","summary":"Search Graph","description":"Perform a graph search query.","tags":["search"],"responses":{"200":{"description":"Graph search results or auto-context block","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.GraphSearchResults"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}},"requestBody":{"description":"Graph search query","content":{"application/json":{"schema":{"$ref":"#/components/schemas/graphiti.GraphSearchQuery"}}}}}},"/graph/subgraph":{"post":{"operationId":"graph_get_subgraph","summary":"Get Subgraph","description":"Returns the bounded neighborhood of a set of seed nodes as a single {nodes, edges} payload: breadth-first expansion up to a caller-specified depth, subject to explicit budgets, with explicit truncation reporting.","tags":["graph"],"responses":{"200":{"description":"Subgraph","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.GraphSubgraphResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}},"requestBody":{"description":"Subgraph request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.GraphSubgraphRequest"}}}}}},"/graph/{graphId}":{"get":{"operationId":"graph_getGraph","summary":"Get Graph","description":"Returns a graph.","tags":["graph"],"parameters":[{"name":"graphId","in":"path","description":"The graph_id of the graph to get.","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"The graph that was retrieved.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.Graph"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}}},"delete":{"operationId":"graph_deleteGraph","summary":"Delete Graph","description":"Deletes a graph. If you would like to delete a user graph, make sure to use user.delete instead.","tags":["graph"],"parameters":[{"name":"graphId","in":"path","description":"Graph ID","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Deleted","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.SuccessResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}}},"patch":{"operationId":"graph_updateGraph","summary":"Update Graph.","description":"Updates information about a graph.","tags":["graph"],"parameters":[{"name":"graphId","in":"path","description":"Graph ID","required":true,"schema":{"type":"string"}}],"responses":{"201":{"description":"The updated graph object","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.Graph"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}},"requestBody":{"description":"Graph","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.UpdateGraphRequest"}}}}}},"/graph/{graphId}/warm":{"get":{"operationId":"graph_warmGraphCache","summary":"Warm Graph Cache","description":"Hints Zep to warm a graph for low-latency search","tags":["graph"],"parameters":[{"name":"graphId","in":"path","description":"The graph_id of the graph to warm.","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Warm hint accepted","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.SuccessResponse"}}}},"404":{"description":"Graph not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}}}},"/graph/edge/graph/{graph_id}":{"post":{"operationId":"entity_getGraphEdges","summary":"Get Graph Edges","description":"Returns all edges for a graph.","tags":["entity"],"parameters":[{"name":"graph_id","in":"path","description":"Graph ID","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Edges","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/graphiti.EntityEdge"}}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}},"requestBody":{"description":"Pagination parameters","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.GraphEdgesRequest"}}}}}},"/graph/edge/user/{user_id}":{"post":{"operationId":"entity_getUserEdges","summary":"Get User Edges","description":"Returns all edges for a user.","tags":["entity"],"parameters":[{"name":"user_id","in":"path","description":"User ID","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Edges","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/graphiti.EntityEdge"}}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}},"requestBody":{"description":"Pagination parameters","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.GraphEdgesRequest"}}}}}},"/graph/edge/{uuid}":{"get":{"operationId":"entity_getEdge","summary":"Get Edge","description":"Returns a specific edge by its UUID.","tags":["entity"],"parameters":[{"name":"uuid","in":"path","description":"Edge UUID","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Edge","content":{"application/json":{"schema":{"$ref":"#/components/schemas/graphiti.EntityEdge"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}}},"patch":{"operationId":"graph_updateEdge","summary":"Update Edge","description":"Updates an entity edge by UUID.","tags":["graph"],"parameters":[{"name":"uuid","in":"path","description":"Edge UUID","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Updated edge","content":{"application/json":{"schema":{"$ref":"#/components/schemas/graphiti.EntityEdge"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}},"requestBody":{"description":"Update edge request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.UpdateEdgeRequest"}}}}},"delete":{"operationId":"entity_deleteEdge","summary":"Delete Edge","description":"Deletes an edge by UUID.","tags":["entity"],"parameters":[{"name":"uuid","in":"path","description":"Edge UUID","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Edge deleted","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.SuccessResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}}}},"/graph/episodes/graph/{graph_id}":{"get":{"operationId":"episodes_getGraphEpisodes","summary":"Get Graph Episodes","description":"Returns episodes by graph id.","tags":["episodes"],"parameters":[{"name":"graph_id","in":"path","description":"Graph ID","required":true,"schema":{"type":"string"}},{"name":"lastn","in":"query","description":"The number of most recent episodes to retrieve.","required":false,"schema":{"type":"integer"}}],"responses":{"200":{"description":"Episodes","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.GraphEpisodeResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}}},"post":{"operationId":"graph_episode_list_by_graph_id","summary":"List Graph Episodes","description":"Returns a paginated, filterable list of episodes for a graph.","tags":["graph > episode"],"parameters":[{"name":"graph_id","in":"path","description":"Graph ID","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Episodes","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/apidata.GraphEpisode"}}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}},"requestBody":{"description":"Episode listing request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.GraphEpisodeListRequest"}}}}}},"/graph/episodes/user/{user_id}":{"get":{"operationId":"episodes_getUserEpisodes","summary":"Get User Episodes","description":"Returns episodes by user id.","tags":["episodes"],"parameters":[{"name":"user_id","in":"path","description":"User ID","required":true,"schema":{"type":"string"}},{"name":"lastn","in":"query","description":"The number of most recent episodes entries to retrieve.","required":false,"schema":{"type":"integer"}}],"responses":{"200":{"description":"Episodes","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.GraphEpisodeResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}}},"post":{"operationId":"graph_episode_list_by_user_id","summary":"List User Episodes","description":"Returns a paginated, filterable list of episodes for a user's graph.","tags":["graph > episode"],"parameters":[{"name":"user_id","in":"path","description":"User ID","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Episodes","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/apidata.GraphEpisode"}}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}},"requestBody":{"description":"Episode listing request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.GraphEpisodeListRequest"}}}}}},"/graph/episodes/{uuid}":{"get":{"operationId":"episodes_getEpisode","summary":"Get Episode","description":"Returns episodes by UUID","tags":["episodes"],"parameters":[{"name":"uuid","in":"path","description":"Episode UUID","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Episode","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.GraphEpisode"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}}},"patch":{"operationId":"episodes_updateEpisodeMetadata","summary":"Update Episode Metadata","description":"Update episode metadata with merge semantics. Supplied keys overwrite or add to existing metadata; keys set to null are removed.","tags":["episodes"],"parameters":[{"name":"uuid","in":"path","description":"Episode UUID","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Updated episode","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.GraphEpisode"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}},"requestBody":{"description":"Metadata update","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.UpdateEpisodeRequest"}}}}},"delete":{"operationId":"entity_deleteEpisode","summary":"Delete Episode","description":"Deletes an episode by its UUID.","tags":["entity"],"parameters":[{"name":"uuid","in":"path","description":"Episode UUID","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Episode deleted","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.SuccessResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}}}},"/graph/episodes/{uuid}/mentions":{"get":{"operationId":"episodes_returnAnyNodesAndEdgesMentionedInAnEpisode","summary":"Return any nodes and edges mentioned in an episode","description":"Deprecated. Use edge and node listing with `filters.episode_uuids` instead. Returns nodes and edges mentioned in an episode, subject to an internal cap; responses reduced by that cap set the Zep-Truncated header.","tags":["episodes"],"parameters":[{"name":"uuid","in":"path","description":"Episode uuid","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Edges and nodes mentioned in an episode","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.EpisodeMentions"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}},"deprecated":true}},"/graph/nodes":{"post":{"operationId":"entity_addNodes","summary":"Add Nodes","description":"Add entity nodes to a user or graph directly, without episode ingestion. Up to 100 nodes per request.","tags":["entity"],"responses":{"202":{"description":"Accepted","content":{"application/json":{"schema":{"$ref":"#/components/schemas/graphiti.AddNodesResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}},"requestBody":{"description":"Nodes to add","content":{"application/json":{"schema":{"$ref":"#/components/schemas/graphiti.AddNodesRequest"}}}}}},"/graph/node/graph/{graph_id}":{"post":{"operationId":"entity_getGraphNodes","summary":"Get Graph Nodes","description":"Returns all nodes for a graph.","tags":["entity"],"parameters":[{"name":"graph_id","in":"path","description":"Graph ID","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Nodes","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/graphiti.EntityNode"}}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}},"requestBody":{"description":"Pagination parameters","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.GraphNodesRequest"}}}}}},"/graph/node/user/{user_id}":{"post":{"operationId":"entity_getUserNodes","summary":"Get User Nodes","description":"Returns all nodes for a user","tags":["entity"],"parameters":[{"name":"user_id","in":"path","description":"User ID","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Nodes","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/graphiti.EntityNode"}}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}},"requestBody":{"description":"Pagination parameters","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.GraphNodesRequest"}}}}}},"/graph/node/{node_uuid}/entity-edges":{"get":{"operationId":"entity_getEntityEdgesForANode","summary":"Get Entity Edges for a node","description":"Deprecated. Use edge listing with `filters.connected_node_uuids`, or the neighbors endpoint (`POST /graph/node/{node_uuid}/neighbors`), instead. Returns all edges for a node, subject to an internal cap; responses reduced by that cap set the Zep-Truncated header.","tags":["entity"],"parameters":[{"name":"node_uuid","in":"path","description":"Node UUID","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Edges","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/graphiti.EntityEdge"}}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}},"deprecated":true}},"/graph/node/{node_uuid}/episodes":{"get":{"operationId":"entity_getEpisodesForANode","summary":"Get Episodes for a node","description":"Deprecated. Use episode listing with `mentioned_node_uuids` (`POST /graph/episodes/graph/{graph_id}` or `POST /graph/episodes/user/{user_id}`) instead. Returns episodes that mentioned a given node, subject to an internal cap; responses reduced by that cap set the Zep-Truncated header.","tags":["entity"],"parameters":[{"name":"node_uuid","in":"path","description":"Node UUID","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Episodes","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.GraphEpisodeResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}},"deprecated":true}},"/graph/node/{node_uuid}/neighbors":{"post":{"operationId":"graph_node_get_neighbors","summary":"Get Node Neighbors","description":"Enumerates the distinct entity nodes directly connected to a node, together with the edges connecting each to it.","tags":["graph > node"],"parameters":[{"name":"node_uuid","in":"path","description":"Node UUID","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Neighbors","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/apidata.GraphNodeNeighbor"}}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}},"requestBody":{"description":"Neighbors request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.GraphNodeNeighborsRequest"}}}}}},"/graph/node/{uuid}":{"get":{"operationId":"entity_getNode","summary":"Get Node","description":"Returns a specific node by its UUID.","tags":["entity"],"parameters":[{"name":"uuid","in":"path","description":"Node UUID","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Node","content":{"application/json":{"schema":{"$ref":"#/components/schemas/graphiti.EntityNode"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}}},"patch":{"operationId":"graph_updateNode","summary":"Update Node","description":"Updates an entity node by UUID.","tags":["graph"],"parameters":[{"name":"uuid","in":"path","description":"Node UUID","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Updated node","content":{"application/json":{"schema":{"$ref":"#/components/schemas/graphiti.EntityNode"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}},"requestBody":{"description":"Update node request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.UpdateNodeRequest"}}}}},"delete":{"operationId":"entity_deleteNode","summary":"Delete Node","description":"Deletes a node by UUID.","tags":["entity"],"parameters":[{"name":"uuid","in":"path","description":"Node UUID","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Node deleted","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.SuccessResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}}}},"/custom-instructions":{"get":{"operationId":"graph_listCustomInstructions","summary":"List Custom Instructions","description":"Lists all custom instructions for a project, user, or graph.","tags":["graph"],"parameters":[{"name":"user_id","in":"query","description":"User ID to get user-specific instructions","required":false,"schema":{"type":"string"}},{"name":"graph_id","in":"query","description":"Graph ID to get graph-specific instructions","required":false,"schema":{"type":"string"}}],"responses":{"200":{"description":"The list of instructions.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.ListCustomInstructionsResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}}},"post":{"operationId":"graph_addCustomInstructions","summary":"Add Custom Instructions","description":"Adds new custom instructions for graphs without removing existing ones. If user_ids or graph_ids is empty, adds to project-wide default instructions.","tags":["graph"],"responses":{"200":{"description":"Instructions added successfully","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.SuccessResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}},"requestBody":{"description":"The instructions to add","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.AddCustomInstructionsRequest"}}}}},"delete":{"operationId":"graph_deleteCustomInstructions","summary":"Delete Custom Instructions","description":"Deletes custom instructions for graphs or project wide defaults.","tags":["graph"],"responses":{"200":{"description":"Instructions deleted successfully","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.SuccessResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}},"requestBody":{"description":"The instructions to delete","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.DeleteCustomInstructionsRequest"}}}}}},"/graph/observation/graph/{graph_id}":{"post":{"operationId":"observation_getGraphObservations","summary":"Get Graph Observations","description":"Returns read-only observation nodes for a graph.","tags":["observation"],"parameters":[{"name":"graph_id","in":"path","description":"Graph ID","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Observations","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/graphiti.DerivedNode"}}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}},"requestBody":{"description":"Pagination parameters","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.GraphObservationsRequest"}}}}}},"/graph/observation/user/{user_id}":{"post":{"operationId":"observation_getUserObservations","summary":"Get User Observations","description":"Returns read-only observation nodes for a user's graph.","tags":["observation"],"parameters":[{"name":"user_id","in":"path","description":"User ID","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Observations","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/graphiti.DerivedNode"}}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}},"requestBody":{"description":"Pagination parameters","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.GraphObservationsRequest"}}}}}},"/graph/observation/{uuid}":{"get":{"operationId":"observation_getObservation","summary":"Get Observation","description":"Returns a specific observation node by UUID. Observation nodes are read-only.","tags":["observation"],"parameters":[{"name":"uuid","in":"path","description":"Observation UUID","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Observation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/graphiti.DerivedNode"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}}}},"/graph/thread-summary/graph/{graph_id}":{"post":{"operationId":"threadSummary_getGraphThreadSummaries","summary":"Get Graph Thread Summaries","description":"Returns incremental thread summaries associated with the graph.","tags":["thread-summary"],"parameters":[{"name":"graph_id","in":"path","description":"Graph ID","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Thread summaries","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/apidata.ThreadSummary"}}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}},"requestBody":{"description":"Pagination parameters","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.GraphThreadSummariesRequest"}}}}}},"/graph/thread-summary/user/{user_id}":{"post":{"operationId":"threadSummary_getUserThreadSummaries","summary":"Get User Thread Summaries","description":"Returns incremental thread summaries generated from messages in each thread associated with the user's graph.","tags":["thread-summary"],"parameters":[{"name":"user_id","in":"path","description":"User ID","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Thread summaries","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/apidata.ThreadSummary"}}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}},"requestBody":{"description":"Pagination parameters","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.GraphThreadSummariesRequest"}}}}}},"/graph/documents/{document_id}/episodes":{"get":{"operationId":"document_getEpisodesForADocument","summary":"Get Episodes for a document","description":"Returns episodes associated with a document on a graph. Documents group episodes as chunks, parallel to how threads group messages.","tags":["document"],"parameters":[{"name":"document_id","in":"path","description":"Document ID","required":true,"schema":{"type":"string"}},{"name":"graph_id","in":"query","description":"Graph ID","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Episodes","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.GraphEpisodeResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}}}},"/graph/document-summary/graph/{graph_id}":{"post":{"operationId":"documentSummary_getGraphDocumentSummaries","summary":"Get Graph Document Summaries","description":"Returns incremental document summaries associated with the graph. Document summaries are derived similarly to thread summaries.","tags":["document-summary"],"parameters":[{"name":"graph_id","in":"path","description":"Graph ID","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Document summaries","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/apidata.DocumentSummary"}}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}},"requestBody":{"description":"Pagination parameters","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.GraphDocumentSummariesRequest"}}}}}},"/projects/info":{"get":{"operationId":"project_retrievesProjectInformation","summary":"Retrieves project information","description":"Retrieve project info based on the provided api key.","tags":["project"],"responses":{"200":{"description":"Retrieved","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.ProjectInfoResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}}},"patch":{"operationId":"project_updatesProjectTimeZoneInformation","summary":"Updates project time-zone information","description":"Sets or clears the project-level fallback time zone for the API key's project.","tags":["project"],"responses":{"200":{"description":"Updated","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.ProjectInfoResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}},"requestBody":{"description":"Project time-zone update","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.UpdateProjectInfoRequest"}}}}}},"/projects/observation-steering":{"get":{"operationId":"project_retrievesObservationSteeringConfigurationExperimental","summary":"Retrieves observation steering configuration (Experimental)","description":"Returns project steering or the effective user/graph steering with project fallback. This API is experimental and may change in future releases.","tags":["project"],"parameters":[{"name":"user_id","in":"query","description":"User ID for user-specific steering","required":false,"schema":{"type":"string"}},{"name":"graph_id","in":"query","description":"Graph ID for graph-specific steering","required":false,"schema":{"type":"string"}}],"responses":{"200":{"description":"Retrieved","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.ObservationSteeringConfig"}}}},"400":{"description":"Not entitled","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}}},"put":{"operationId":"project_replacesObservationSteeringConfigurationExperimental","summary":"Replaces observation steering configuration (Experimental)","description":"Replaces project, user, or graph steering. An empty configuration clears the project default or removes the user/graph override. Changes affect later materializer runs only. This API is experimental and may change in future releases.","tags":["project"],"parameters":[{"name":"user_id","in":"query","description":"User ID for user-specific steering","required":false,"schema":{"type":"string"}},{"name":"graph_id","in":"query","description":"Graph ID for graph-specific steering","required":false,"schema":{"type":"string"}}],"responses":{"200":{"description":"Updated","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.ObservationSteeringConfig"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}},"requestBody":{"description":"Observation steering configuration","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.ObservationSteeringConfig"}}}}}},"/tasks/{task_id}":{"get":{"operationId":"task_getTask","summary":"Get Task","description":"Gets a task by its ID","tags":["task"],"parameters":[{"name":"task_id","in":"path","description":"Task ID","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Task","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.GetTaskResponse"}}}},"404":{"description":"Task not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}}}},"/batches":{"post":{"operationId":"batch_createBatch","summary":"Create Batch","description":"Create a draft batch that can be filled with graph episodes and thread messages.","tags":["batch"],"responses":{"200":{"description":"Created batch","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.BatchSummary"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}},"requestBody":{"description":"Create batch request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.CreateBatchRequest"}}}}},"get":{"operationId":"batch_listBatches","summary":"List Batches","description":"List batches for the current project, optionally filtered by batch status.","tags":["batch"],"parameters":[{"name":"limit","in":"query","description":"Maximum number of batches to return.","required":false,"schema":{"type":"integer"}},{"name":"cursor","in":"query","description":"Pagination cursor from a previous response.","required":false,"schema":{"type":"integer"}},{"name":"status","in":"query","description":"Batch status filter.","required":false,"schema":{"type":"string"}}],"responses":{"200":{"description":"Batch list","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.BatchListResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}}}},"/batches/{batchId}/items":{"post":{"operationId":"batch_addBatchItems","summary":"Add Batch Items","description":"Add graph episodes and thread messages to a draft batch. Items are appended in request order.","tags":["batch"],"parameters":[{"name":"batchId","in":"path","description":"The batch ID.","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Added batch items","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/apidata.BatchItemDetail"}}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"409":{"description":"Conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}},"requestBody":{"description":"Batch items to add","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.AddBatchItemsRequest"}}}}},"get":{"operationId":"batch_listBatchItems","summary":"List Batch Items","description":"List items in a batch, including derived runtime status when the batch has been processed.","tags":["batch"],"parameters":[{"name":"batchId","in":"path","description":"The batch ID.","required":true,"schema":{"type":"string"}},{"name":"limit","in":"query","description":"Maximum number of batch items to return.","required":false,"schema":{"type":"integer"}},{"name":"cursor","in":"query","description":"Pagination cursor from a previous response.","required":false,"schema":{"type":"integer"}},{"name":"status","in":"query","description":"Batch item status filter.","required":false,"schema":{"type":"string"}}],"responses":{"200":{"description":"Batch item list","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.BatchItemListResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}}}},"/batches/{batchId}/process":{"post":{"operationId":"batch_processBatch","summary":"Process Batch","description":"Start processing a filled batch. Repeated calls return a conflict.","tags":["batch"],"parameters":[{"name":"batchId","in":"path","description":"The batch ID.","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Batch processing state","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.BatchSummary"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.BatchInvalidReferencesError"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"409":{"description":"Conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}}}},"/batches/{batchId}":{"get":{"operationId":"batch_getBatch","summary":"Get Batch","description":"Get a batch summary, including runtime progress when the batch has been processed.","tags":["batch"],"parameters":[{"name":"batchId","in":"path","description":"The batch ID.","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Batch summary","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.BatchSummary"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}}},"delete":{"operationId":"batch_deleteBatch","summary":"Delete Batch","description":"Delete a draft or invalid unprocessed batch. Processed batches cannot be deleted.","tags":["batch"],"parameters":[{"name":"batchId","in":"path","description":"The batch ID.","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Deleted batch","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.SuccessResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"409":{"description":"Conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/apidata.APIError"}}}}}}}},"tags":[{"name":"thread"},{"name":"user"},{"name":"userGroup"},{"name":"context"},{"name":"graph"},{"name":"data"},{"name":"entity"},{"name":"search"},{"name":"episodes"},{"name":"graph > episode"},{"name":"graph > node"},{"name":"observation"},{"name":"thread-summary"},{"name":"document"},{"name":"document-summary"},{"name":"project"},{"name":"task"},{"name":"batch"}],"servers":[{"url":"https://api.getzep.com/api/v2","description":"https://api.getzep.com/api/v2"}],"components":{"schemas":{"apidata.Thread":{"type":"object","properties":{"created_at":{"type":"string"},"graph_uuid":{"type":"string","description":"GraphUUID is the graphs.uuid of the owning user's graph (spec-3 section 13.5)."},"project_uuid":{"type":"string"},"thread_id":{"type":"string"},"user_id":{"type":"string"},"user_uuid":{"type":"string"},"uuid":{"type":"string"}},"title":"apidata.Thread"},"apidata.ThreadListResponse":{"type":"object","properties":{"response_count":{"type":"integer"},"threads":{"type":"array","items":{"$ref":"#/components/schemas/apidata.Thread"}},"total_count":{"type":"integer"}},"title":"apidata.ThreadListResponse"},"apidata.APIError":{"type":"object","properties":{"message":{"type":"string"}},"title":"apidata.APIError"},"models.CreateThreadRequest":{"type":"object","properties":{"thread_id":{"type":"string","maxLength":500,"description":"The unique identifier of the thread."},"user_id":{"type":"string","description":"The unique identifier of the user associated with the thread"}},"required":["thread_id","user_id"],"title":"models.CreateThreadRequest"},"apidata.SuccessResponse":{"type":"object","properties":{"message":{"type":"string"}},"title":"apidata.SuccessResponse"},"apidata.ThreadContextResponse":{"type":"object","properties":{"context":{"type":"string","description":"Context block containing relevant facts, entities, and messages/episodes from the user graph. Pass it through the model provider's untrusted-data channel."}},"title":"apidata.ThreadContextResponse"},"apidata.RoleType":{"type":"string","enum":["norole","system","assistant","user","function","tool"],"title":"apidata.RoleType"},"apidata.ThreadMessage":{"type":"object","properties":{"content":{"type":"string","description":"The content of the message."},"created_at":{"type":"string","description":"The timestamp of when the message was created."},"metadata":{"type":"object","additionalProperties":{"description":"Any type"},"description":"The metadata associated with the message."},"name":{"type":"string","description":"Customizable name of the sender of the message (e.g., \"john\", \"sales_agent\")."},"processed":{"type":"boolean","description":"Whether the message has been processed."},"role":{"$ref":"#/components/schemas/apidata.RoleType","description":"The role of message sender (e.g., \"user\", \"system\")."},"uuid":{"type":"string","description":"The unique identifier of the message."}},"required":["content","role"],"title":"apidata.ThreadMessage"},"apidata.ThreadMessageListResponse":{"type":"object","properties":{"messages":{"type":"array","items":{"$ref":"#/components/schemas/apidata.ThreadMessage"},"description":"A list of message objects."},"row_count":{"type":"integer","description":"The number of messages returned."},"thread_created_at":{"type":"string","description":"The thread creation timestamp."},"total_count":{"type":"integer","description":"The total number of messages."},"user_id":{"type":"string","description":"The user ID associated with this thread."},"user_uuid":{"type":"string","description":"The opaque user identifier used by dashboard routes."}},"title":"apidata.ThreadMessageListResponse"},"models.GraphDataType":{"type":"string","enum":["text","json","message","fact_triple"],"title":"models.GraphDataType"},"apidata.GraphEpisode":{"type":"object","properties":{"content":{"type":"string"},"created_at":{"type":"string"},"document_id":{"type":"string","description":"Optional document ID, will be present if the episode is part of a document"},"metadata":{"type":"object","additionalProperties":{"description":"Any type"}},"processed":{"type":"boolean"},"relevance":{"type":"number","format":"double","description":"Relevance is an experimental rank-aligned score in [0,1] derived from Score via logit transformation.\nOnly populated when using cross_encoder reranker; omitted for other reranker types (e.g., RRF)."},"role":{"type":"string","description":"Optional role, will only be present if the episode was created using memory.add API"},"role_type":{"$ref":"#/components/schemas/apidata.RoleType","description":"Optional role_type, will only be present if the episode was created using memory.add API"},"score":{"type":"number","format":"double","description":"Score is the reranker output: sigmoid-distributed logits [0,1] when using cross_encoder reranker, or RRF ordinal rank when using rrf reranker"},"selection_rank":{"type":"integer","description":"SelectionRank is the global cross-scope rank assigned by auto scope selection."},"source":{"$ref":"#/components/schemas/models.GraphDataType"},"source_description":{"type":"string"},"task_id":{"type":"string","description":"Optional task ID to poll episode processing status. Currently only available for batch ingestion."},"thread_id":{"type":"string","description":"Optional thread ID, will be present if the episode is part of a thread"},"uuid":{"type":"string"}},"required":["content","created_at","uuid"],"title":"apidata.GraphEpisode"},"apidata.GraphEpisodeResponse":{"type":"object","properties":{"episodes":{"type":"array","items":{"$ref":"#/components/schemas/apidata.GraphEpisode"}}},"title":"apidata.GraphEpisodeResponse"},"apidata.AddThreadMessagesRequest":{"type":"object","properties":{"ignore_roles":{"type":"array","items":{"$ref":"#/components/schemas/apidata.RoleType"},"description":"Optional list of role types to ignore when adding messages to graph memory.\nThe message itself will still be added, retained and used as context for messages\nthat are added to a user's graph."},"messages":{"type":"array","items":{"$ref":"#/components/schemas/apidata.ThreadMessage"},"description":"A list of message objects, where each message contains a role and content."},"return_context":{"type":"boolean","description":"Optionally return context block relevant to the most recent messages."},"strict_ontology":{"type":"boolean","description":"When true, prevents extraction of generic Entity nodes that do not match the configured ontology."}},"required":["messages"],"title":"apidata.AddThreadMessagesRequest"},"apidata.AddThreadMessagesResponse":{"type":"object","properties":{"context":{"type":"string"},"message_uuids":{"type":"array","items":{"type":"string"}},"task_id":{"type":"string"}},"title":"apidata.AddThreadMessagesResponse"},"apidata.ThreadSummary":{"type":"object","properties":{"created_at":{"type":"string","description":"CreatedAt is when the summary node was first created."},"last_summarized_at":{"type":"string","description":"LastSummarizedAt is the wall-clock timestamp of the most recent\nsummary update. This is an ingestion-time watermark; for the\nevent-time recency of the summary's content, use\nLastSummarizedEpisodeValidAt instead."},"last_summarized_episode_valid_at":{"type":"string","description":"LastSummarizedEpisodeValidAt is the maximum episode reference time\n(valid_at) covered by the most recent summary. Use this when\nanswering \"how recent is this summary's content in event-time?\"."},"summary":{"type":"string","description":"Summary is the incremental summary content."},"thread_id":{"type":"string","description":"ThreadID is the ID of the thread this summary belongs to.\nWhen a thread was created without an explicit thread_id, this\nfield falls back to the thread's UUID. Clients should treat it\nas an opaque identifier."},"uuid":{"type":"string","description":"UUID of the derived thread summary node."}},"title":"apidata.ThreadSummary"},"models.ThreadMessageUpdate":{"type":"object","properties":{"metadata":{"type":"object","additionalProperties":{"description":"Any type"}}},"required":["metadata"],"title":"models.ThreadMessageUpdate"},"apidata.CreateUserRequest":{"type":"object","properties":{"disable_default_ontology":{"type":"boolean","description":"When true, disables the use of default/fallback ontology for the user's graph."},"email":{"type":"string","description":"The email address of the user."},"first_name":{"type":"string","description":"The first name of the user."},"last_name":{"type":"string","description":"The last name of the user."},"metadata":{"type":"object","additionalProperties":{"description":"Any type"},"description":"The metadata associated with the user."},"time_zone":{"type":["string","null"],"description":"The user's IANA time zone. Null or omission leaves it unset at creation."},"user_id":{"type":"string","maxLength":500,"description":"The unique identifier of the user."}},"required":["user_id"],"title":"apidata.CreateUserRequest"},"apidata.User":{"type":"object","properties":{"created_at":{"type":"string"},"deleted_at":{"type":"string"},"disable_default_ontology":{"type":"boolean"},"email":{"type":"string"},"first_name":{"type":"string"},"graph_uuid":{"type":"string","description":"GraphUUID is the graphs.uuid of the user's graph (spec-3 section 13.5).\nOmitted when the graph row does not exist. Read-only; never accepted as input."},"id":{"type":"integer"},"last_name":{"type":"string"},"metadata":{"type":"object","additionalProperties":{"description":"Any type"},"description":"Deprecated"},"project_uuid":{"type":"string"},"session_count":{"type":"integer","description":"Deprecated"},"time_zone":{"type":["string","null"]},"updated_at":{"type":"string","description":"Deprecated"},"user_id":{"type":"string"},"uuid":{"type":"string"}},"title":"apidata.User"},"apidata.UserListResponse":{"type":"object","properties":{"row_count":{"type":"integer"},"total_count":{"type":"integer"},"users":{"type":"array","items":{"$ref":"#/components/schemas/apidata.User"}}},"title":"apidata.UserListResponse"},"apidata.UpdateUserRequest":{"type":"object","properties":{"disable_default_ontology":{"type":"boolean","description":"When true, disables the use of default/fallback ontology for the user's graph."},"email":{"type":"string","description":"The email address of the user."},"first_name":{"type":"string","description":"The first name of the user."},"last_name":{"type":"string","description":"The last name of the user."},"metadata":{"type":"object","additionalProperties":{"description":"Any type"},"description":"The metadata to update"},"time_zone":{"type":["string","null"],"description":"The user's IANA time zone. Null clears the existing value."}},"title":"apidata.UpdateUserRequest"},"graphiti.EntityNode":{"type":"object","properties":{"attributes":{"type":"object","additionalProperties":{"description":"Any type"},"description":"Additional attributes of the node. Dependent on node labels"},"created_at":{"type":"string","description":"Creation time of the node"},"labels":{"type":"array","items":{"type":"string"},"description":"Labels associated with the node"},"name":{"type":"string","description":"Name of the node"},"relevance":{"type":"number","format":"double","description":"Relevance is an experimental rank-aligned score in [0,1] derived from Score via logit transformation.\nOnly populated when using cross_encoder reranker; omitted for other reranker types (e.g., RRF)."},"score":{"type":"number","format":"double","description":"Score is the reranker output: sigmoid-distributed logits [0,1] when using cross_encoder reranker, or RRF ordinal rank when using rrf reranker"},"selection_rank":{"type":"integer","description":"SelectionRank is the global cross-scope rank assigned by auto scope selection."},"summary":{"type":"string","description":"Regional summary of surrounding edges"},"uuid":{"type":"string","description":"UUID of the node"}},"required":["created_at","name","summary","uuid"],"title":"graphiti.EntityNode"},"apidata.UserNodeResponse":{"type":"object","properties":{"node":{"$ref":"#/components/schemas/graphiti.EntityNode"}},"title":"apidata.UserNodeResponse"},"apidata.UserInstruction":{"type":"object","properties":{"name":{"type":"string","maxLength":100},"text":{"type":"string","minLength":1,"maxLength":100}},"required":["name","text"],"title":"apidata.UserInstruction"},"apidata.ListUserInstructionsResponse":{"type":"object","properties":{"instructions":{"type":"array","items":{"$ref":"#/components/schemas/apidata.UserInstruction"}}},"title":"apidata.ListUserInstructionsResponse"},"apidata.AddUserInstructionsRequest":{"type":"object","properties":{"instructions":{"type":"array","items":{"$ref":"#/components/schemas/apidata.UserInstruction"},"description":"Instructions to add to the user summary generation."},"user_ids":{"type":"array","items":{"type":"string"},"description":"User IDs to add the instructions to. If empty, the instructions are added to the project-wide default."}},"required":["instructions"],"title":"apidata.AddUserInstructionsRequest"},"apidata.DeleteUserInstructionsRequest":{"type":"object","properties":{"instruction_names":{"type":"array","items":{"type":"string"},"description":"Unique identifier for the instructions to be deleted. If empty deletes all instructions."},"user_ids":{"type":"array","items":{"type":"string"},"description":"Determines which users will have their custom instructions deleted. If no users are provided, the project-wide custom instructions will be effected."}},"title":"apidata.DeleteUserInstructionsRequest"},"models.UserGroupQuota":{"type":"object","properties":{"active_managed":{"type":"integer"},"allocation":{"type":"integer"},"has_feature":{"type":"boolean"},"resolved":{"type":"boolean"},"unlimited":{"type":"boolean"}},"title":"models.UserGroupQuota"},"models.UserGroupKind":{"type":"string","enum":["managed","virtual"],"title":"models.UserGroupKind"},"models.UserGroup":{"type":"object","properties":{"attached_policy_set_count":{"type":"integer"},"created_at":{"type":"string"},"description":{"type":"string"},"kind":{"$ref":"#/components/schemas/models.UserGroupKind"},"member_count":{"type":"integer"},"name":{"type":"string"},"project_uuid":{"type":"string"},"updated_at":{"type":"string"},"uuid":{"type":"string"},"version":{"type":"integer"}},"title":"models.UserGroup"},"apidata.UserGroupListResponse":{"type":"object","properties":{"quota":{"$ref":"#/components/schemas/models.UserGroupQuota"},"row_count":{"type":"integer"},"total_count":{"type":"integer"},"user_groups":{"type":"array","items":{"$ref":"#/components/schemas/models.UserGroup"}}},"title":"apidata.UserGroupListResponse"},"apidata.CreateUserGroupRequest":{"type":"object","properties":{"description":{"type":"string","maxLength":4096},"name":{"type":"string","minLength":1,"maxLength":128}},"required":["name"],"title":"apidata.CreateUserGroupRequest"},"apidata.UserGroupResponse":{"type":"object","properties":{"attached_policy_set_count":{"type":"integer"},"created_at":{"type":"string"},"description":{"type":"string"},"kind":{"$ref":"#/components/schemas/models.UserGroupKind"},"member_count":{"type":"integer"},"name":{"type":"string"},"project_uuid":{"type":"string"},"updated_at":{"type":"string"},"uuid":{"type":"string"},"version":{"type":"integer"}},"title":"apidata.UserGroupResponse"},"apidata.UserMembershipGroupsResponse":{"type":"object","properties":{"user_groups":{"type":"array","items":{"$ref":"#/components/schemas/models.UserGroup"}}},"title":"apidata.UserMembershipGroupsResponse"},"apidata.UpdateUserGroupRequest":{"type":"object","properties":{"description":{"type":"string","maxLength":4096},"expected_version":{"type":"integer","minimum":1},"name":{"type":"string","minLength":1,"maxLength":128}},"required":["expected_version"],"title":"apidata.UpdateUserGroupRequest"},"apidata.UserGroupMembersResponse":{"type":"object","properties":{"row_count":{"type":"integer"},"total_count":{"type":"integer"},"users":{"type":"array","items":{"$ref":"#/components/schemas/apidata.User"}}},"title":"apidata.UserGroupMembersResponse"},"apidata.MutateUserGroupMembersRequest":{"type":"object","properties":{"user_uuids":{"type":"array","items":{"type":"string"}}},"required":["user_uuids"],"title":"apidata.MutateUserGroupMembersRequest"},"apidata.UserGroupMembershipResponse":{"type":"object","properties":{"added_count":{"type":"integer"},"no_op_count":{"type":"integer"},"removed_count":{"type":"integer"}},"title":"apidata.UserGroupMembershipResponse"},"apidata.PolicySetSummaryResponse":{"type":"object","properties":{"mode":{"type":"string"},"name":{"type":"string"},"uuid":{"type":"string"},"version":{"type":"integer"}},"title":"apidata.PolicySetSummaryResponse"},"apidata.AttachedPolicySetsResponse":{"type":"object","properties":{"policy_sets":{"type":"array","items":{"$ref":"#/components/schemas/apidata.PolicySetSummaryResponse"}}},"title":"apidata.AttachedPolicySetsResponse"},"apidata.AttachPolicySetRequest":{"type":"object","properties":{"policy_set_uuid":{"type":"string"}},"required":["policy_set_uuid"],"title":"apidata.AttachPolicySetRequest"},"apidata.CreateContextTemplateRequest":{"type":"object","properties":{"template":{"type":"string","minLength":1,"maxLength":1200,"description":"The template content (max 1200 characters)."},"template_id":{"type":"string","maxLength":100,"description":"Unique identifier for the template (max 100 characters)."}},"required":["template","template_id"],"title":"apidata.CreateContextTemplateRequest"},"apidata.ContextTemplateResponse":{"type":"object","properties":{"template":{"type":"string","description":"The template content."},"template_id":{"type":"string","description":"Unique identifier for the template (max 100 characters)."},"uuid":{"type":"string","description":"Unique identifier for the template."}},"title":"apidata.ContextTemplateResponse"},"apidata.UpdateContextTemplateRequest":{"type":"object","properties":{"template":{"type":"string","minLength":1,"maxLength":1200,"description":"The template content (max 1200 characters)."}},"required":["template"],"title":"apidata.UpdateContextTemplateRequest"},"apidata.ListContextTemplatesResponse":{"type":"object","properties":{"templates":{"type":"array","items":{"$ref":"#/components/schemas/apidata.ContextTemplateResponse"}}},"title":"apidata.ListContextTemplatesResponse"},"GraphSetOntologyPutRequestBodyContentApplicationJsonSchemaEntities":{"type":"object","properties":{},"description":"Dictionary mapping entity type names to their definitions","title":"GraphSetOntologyPutRequestBodyContentApplicationJsonSchemaEntities"},"GraphSetOntologyPutRequestBodyContentApplicationJsonSchemaEdges":{"type":"object","properties":{},"description":"Dictionary mapping edge type names to their definitions with source/target constraints","title":"GraphSetOntologyPutRequestBodyContentApplicationJsonSchemaEdges"},"models.EntityPropertyType":{"type":"string","enum":["Text","Int","Float","Boolean"],"title":"models.EntityPropertyType"},"apidata.EntityProperty":{"type":"object","properties":{"description":{"type":"string","maxLength":500},"name":{"type":"string"},"type":{"$ref":"#/components/schemas/models.EntityPropertyType"}},"required":["description","name","type"],"title":"apidata.EntityProperty"},"apidata.EntityEdgeSourceTarget":{"type":"object","properties":{"source":{"type":"string","description":"Source represents the originating node identifier in the edge type relationship. (optional)"},"target":{"type":"string","description":"Target represents the target node identifier in the edge type relationship. (optional)"}},"title":"apidata.EntityEdgeSourceTarget"},"apidata.EdgeType":{"type":"object","properties":{"description":{"type":"string","maxLength":500},"name":{"type":"string"},"properties":{"type":"array","items":{"$ref":"#/components/schemas/apidata.EntityProperty"}},"source_targets":{"type":"array","items":{"$ref":"#/components/schemas/apidata.EntityEdgeSourceTarget"}}},"required":["description","name"],"title":"apidata.EdgeType"},"apidata.EntityType":{"type":"object","properties":{"description":{"type":"string","maxLength":500},"identity_properties":{"type":"array","items":{"type":"string"}},"name":{"type":"string"},"properties":{"type":"array","items":{"$ref":"#/components/schemas/apidata.EntityProperty"}}},"required":["description","name"],"title":"apidata.EntityType"},"apidata.EntityTypeResponse":{"type":"object","properties":{"edge_types":{"type":"array","items":{"$ref":"#/components/schemas/apidata.EdgeType"}},"entity_types":{"type":"array","items":{"$ref":"#/components/schemas/apidata.EntityType"}}},"title":"apidata.EntityTypeResponse"},"apidata.AddDataRequest":{"type":"object","properties":{"created_at":{"type":"string"},"data":{"type":"string"},"document_id":{"type":"string","minLength":1,"maxLength":100,"description":"Optional document ID that groups episodes as chunks of the same document\non a graph. Parallel to thread_id for message threads."},"graph_id":{"type":"string","description":"graph_id is the ID of the graph to which the data will be added. If adding to the user graph, please use user_id field instead."},"metadata":{"type":"object","additionalProperties":{"description":"Any type"},"description":"Optional metadata key-value pairs. Max 10 keys. Values must be strings, numbers, booleans, or arrays of scalars."},"source_description":{"type":"string","maxLength":500},"strict_ontology":{"type":"boolean","description":"When true, prevents extraction of generic Entity nodes that do not match the configured ontology."},"type":{"$ref":"#/components/schemas/models.GraphDataType"},"user_id":{"type":"string","description":"User ID is the ID of the user to which the data will be added. If not adding to a user graph, please use graph_id field instead."}},"required":["data","type"],"title":"apidata.AddDataRequest"},"apidata.EpisodeData":{"type":"object","properties":{"created_at":{"type":"string"},"data":{"type":"string"},"metadata":{"type":"object","additionalProperties":{"description":"Any type"},"description":"Optional metadata key-value pairs. Max 10 keys. Values must be strings, numbers, booleans, or arrays of scalars."},"source_description":{"type":"string","maxLength":500},"type":{"$ref":"#/components/schemas/models.GraphDataType"}},"required":["data","type"],"title":"apidata.EpisodeData"},"apidata.AddDataBatchRequest":{"type":"object","properties":{"document_id":{"type":"string","minLength":1,"maxLength":100,"description":"Optional document ID applied to every episode in this batch request."},"episodes":{"type":"array","items":{"$ref":"#/components/schemas/apidata.EpisodeData"}},"graph_id":{"type":"string","description":"graph_id is the ID of the graph to which the data will be added. If adding to the user graph, please use user_id field instead."},"strict_ontology":{"type":"boolean","description":"When true, prevents extraction of generic Entity nodes that do not match the configured ontology."},"user_id":{"type":"string","description":"User ID is the ID of the user to which the data will be added. If not adding to a user graph, please use graph_id field instead."}},"required":["episodes"],"title":"apidata.AddDataBatchRequest"},"graphiti.AddTripleRequest":{"type":"object","properties":{"created_at":{"type":"string","description":"The timestamp of the message"},"edge_attributes":{"type":"object","additionalProperties":{"description":"Any type"},"description":"Additional attributes of the edge. Values must be scalar types (string, number, boolean, or null).\nNested objects and arrays are not allowed."},"expired_at":{"type":"string","description":"The time (if any) at which the edge expires"},"fact":{"type":"string","maxLength":250,"description":"The fact relating the two nodes that this edge represents"},"fact_name":{"type":"string","minLength":1,"maxLength":50,"description":"The name of the edge to add. Should be all caps using snake case (eg RELATES_TO)"},"graph_id":{"type":"string"},"invalid_at":{"type":"string","description":"The time (if any) at which the fact stops being true"},"metadata":{"type":"object","additionalProperties":{"description":"Any type"},"description":"Optional metadata key-value pairs for the shadow episode created for this fact triple.\nMax 10 keys. Values must be strings, numbers, or booleans."},"source_node_attributes":{"type":"object","additionalProperties":{"description":"Any type"},"description":"Additional attributes of the source node. Values must be scalar types (string, number, boolean, or null).\nNested objects and arrays are not allowed."},"source_node_labels":{"type":"array","items":{"type":"string"},"description":"The labels for the source node. At most one entity-type label may be\nprovided so that manually-added triples remain consistent with automatic\nepisode extraction, which assigns one best-match entity type per node.\nThe base \"Entity\" label is added implicitly by the graph layer on save\nand does not need to be supplied here."},"source_node_name":{"type":"string","maxLength":50,"description":"The name of the source node to add"},"source_node_summary":{"type":"string","maxLength":500,"description":"The summary of the source node to add"},"source_node_uuid":{"type":"string","description":"The source node uuid"},"target_node_attributes":{"type":"object","additionalProperties":{"description":"Any type"},"description":"Additional attributes of the target node. Values must be scalar types (string, number, boolean, or null).\nNested objects and arrays are not allowed."},"target_node_labels":{"type":"array","items":{"type":"string"},"description":"The labels for the target node. At most one entity-type label may be\nprovided so that manually-added triples remain consistent with automatic\nepisode extraction, which assigns one best-match entity type per node.\nThe base \"Entity\" label is added implicitly by the graph layer on save\nand does not need to be supplied here."},"target_node_name":{"type":"string","maxLength":50,"description":"The name of the target node to add"},"target_node_summary":{"type":"string","maxLength":500,"description":"The summary of the target node to add"},"target_node_uuid":{"type":"string","description":"The target node uuid"},"user_id":{"type":"string"},"valid_at":{"type":"string","description":"The time at which the fact becomes true"}},"required":["fact","fact_name"],"title":"graphiti.AddTripleRequest"},"graphiti.EntityEdge":{"type":"object","properties":{"attributes":{"type":"object","additionalProperties":{"description":"Any type"},"description":"Additional attributes of the edge. Dependent on edge types"},"created_at":{"type":"string","description":"Creation time of the edge"},"episodes":{"type":"array","items":{"type":"string"},"description":"List of episode ids that reference these entity edges"},"expired_at":{"type":"string","description":"Datetime of when the node was invalidated"},"fact":{"type":"string","description":"Fact representing the edge and nodes that it connects"},"invalid_at":{"type":"string","description":"Datetime of when the fact stopped being true"},"name":{"type":"string","description":"Name of the edge, relation name"},"relevance":{"type":"number","format":"double","description":"Relevance is an experimental rank-aligned score in [0,1] derived from Score via logit transformation.\nOnly populated when using cross_encoder reranker; omitted for other reranker types (e.g., RRF)."},"scope":{"type":"string","description":"Scope of the edge (e.g. \"entity\", \"maybe_related\")"},"score":{"type":"number","format":"double","description":"Score is the reranker output: sigmoid-distributed logits [0,1] when using cross_encoder reranker, or RRF ordinal rank when using rrf reranker"},"selection_rank":{"type":"integer","description":"SelectionRank is the global cross-scope rank assigned by auto scope selection."},"source_node_labels":{"type":"array","items":{"type":"string"},"description":"SourceNodeLabels are the labels of the source node at read time. Same\nread-time-projection semantics as SourceNodeName."},"source_node_name":{"type":"string","description":"SourceNodeName is the name of the source node at read time. It is a\nread-time projection of current node state, not a stored edge\nattribute: a subsequent node rename is reflected on the next read.\nOmitted (the edge is still returned) if the source node cannot be\nresolved, for example if it was deleted concurrently."},"source_node_uuid":{"type":"string","description":"UUID of the source node"},"target_node_labels":{"type":"array","items":{"type":"string"},"description":"TargetNodeLabels are the labels of the target node at read time. Same\nread-time-projection semantics as SourceNodeName."},"target_node_name":{"type":"string","description":"TargetNodeName is the name of the target node at read time. Same\nread-time-projection semantics as SourceNodeName."},"target_node_uuid":{"type":"string","description":"UUID of the target node"},"uuid":{"type":"string","description":"UUID of the edge"},"valid_at":{"type":"string","description":"Datetime of when the fact became true"}},"required":["created_at","fact","name","source_node_uuid","target_node_uuid","uuid"],"title":"graphiti.EntityEdge"},"graphiti.AddTripleResponse":{"type":"object","properties":{"edge":{"$ref":"#/components/schemas/graphiti.EntityEdge"},"source_node":{"$ref":"#/components/schemas/graphiti.EntityNode"},"target_node":{"$ref":"#/components/schemas/graphiti.EntityNode"},"task_id":{"type":"string","description":"Task ID of the add triple task"}},"title":"graphiti.AddTripleResponse"},"apidata.CloneGraphRequest":{"type":"object","properties":{"source_graph_id":{"type":"string","description":"source_graph_id is the ID of the graph to be cloned. Required if source_user_id is not provided"},"source_user_id":{"type":"string","description":"user_id of the user whose graph is being cloned. Required if source_graph_id is not provided"},"target_graph_id":{"type":"string","description":"target_graph_id is the ID to be set on the cloned graph. Must not point to an existing graph. Required if target_user_id is not provided."},"target_user_id":{"type":"string","description":"user_id to be set on the cloned user. Must not point to an existing user. Required if target_graph_id is not provided."}},"title":"apidata.CloneGraphRequest"},"apidata.CloneGraphResponse":{"type":"object","properties":{"graph_id":{"type":"string","description":"graph_id is the ID of the cloned graph"},"task_id":{"type":"string","description":"Task ID of the clone graph task"},"user_id":{"type":"string"}},"title":"apidata.CloneGraphResponse"},"apidata.CreateGraphRequest":{"type":"object","properties":{"description":{"type":"string","maxLength":2000},"graph_id":{"type":"string"},"name":{"type":"string","maxLength":255},"time_zone":{"type":["string","null"],"description":"The graph's IANA time zone. Stored on its group-backed subject."}},"required":["graph_id"],"title":"apidata.CreateGraphRequest"},"apidata.Graph":{"type":"object","properties":{"canonical_graph_uuid":{"type":"string","description":"CanonicalGraphUUID is graphs.uuid, the v4 graph address (spec-3 §13.5).\nOmitted when the graphs row does not yet exist. Distinct from UUID,\nwhich is the group-row identifier."},"created_at":{"type":"string"},"description":{"type":"string"},"graph_id":{"type":"string"},"id":{"type":"integer"},"name":{"type":"string"},"project_uuid":{"type":"string"},"time_zone":{"type":["string","null"]},"updated_at":{"type":"string"},"uuid":{"type":"string"}},"title":"apidata.Graph"},"apidata.GraphListResponse":{"type":"object","properties":{"graphs":{"type":"array","items":{"$ref":"#/components/schemas/apidata.Graph"}},"page_number":{"type":"integer"},"page_size":{"type":"integer"},"row_count":{"type":"integer"},"total_count":{"type":"integer"}},"title":"apidata.GraphListResponse"},"apidata.ClusterDetectConfig":{"type":"object","properties":{},"title":"apidata.ClusterDetectConfig"},"apidata.CoOccurrenceDetectConfig":{"type":"object","properties":{"max_hops":{"type":"integer","minimum":1,"maximum":5,"description":"Max hops within which to detect co-occurring node types. Default: 3, Max: 5"}},"title":"apidata.CoOccurrenceDetectConfig"},"apidata.HubDetectConfig":{"type":"object","properties":{"min_degree":{"type":"integer","minimum":2,"description":"Minimum number of connections for a node to be considered a hub. Default: 3, Min: 2"}},"title":"apidata.HubDetectConfig"},"apidata.PathDetectConfig":{"type":"object","properties":{"max_hops":{"type":"integer","minimum":1,"maximum":5,"description":"Max hops from seed nodes for path detection. Default: 3, Max: 5"}},"title":"apidata.PathDetectConfig"},"apidata.RelationshipDetectConfig":{"type":"object","properties":{},"title":"apidata.RelationshipDetectConfig"},"apidata.DetectConfig":{"type":"object","properties":{"clusters":{"$ref":"#/components/schemas/apidata.ClusterDetectConfig","description":"Detect tightly interconnected groups (triangle topology)"},"co_occurrences":{"$ref":"#/components/schemas/apidata.CoOccurrenceDetectConfig","description":"Detect node types that co-occur within k hops"},"hubs":{"$ref":"#/components/schemas/apidata.HubDetectConfig","description":"Detect highly connected hub nodes (star topology)"},"paths":{"$ref":"#/components/schemas/apidata.PathDetectConfig","description":"Detect frequent multi-hop connection paths"},"relationships":{"$ref":"#/components/schemas/apidata.RelationshipDetectConfig","description":"Detect common (source_label, edge_type, target_label) relationship triples"}},"title":"apidata.DetectConfig"},"apidata.RecencyWeight":{"type":"string","enum":["none","7_days","30_days","90_days"],"title":"apidata.RecencyWeight"},"graphiti.ComparisonOperator":{"type":"string","enum":["=","<>",">","<",">=","<=","IS NULL","is_null","IS NOT NULL","CONTAINS"],"title":"graphiti.ComparisonOperator"},"graphiti.DateFilter":{"type":"object","properties":{"comparison_operator":{"$ref":"#/components/schemas/graphiti.ComparisonOperator","description":"Comparison operator for date filter"},"date":{"type":"string","description":"Date to filter on. Required for non-null operators (`=`, `<>`, `>`, `<`, `>=`, `<=`).\nShould be omitted for IS NULL (or is_null) and IS NOT NULL operators."}},"required":["comparison_operator"],"title":"graphiti.DateFilter"},"graphiti.EpisodeMetadataFilter":{"type":"object","properties":{"comparison_operator":{"$ref":"#/components/schemas/graphiti.ComparisonOperator","description":"Comparison operator: =, <>, >, <, >=, <=, IS NULL, IS NOT NULL, IN, CONTAINS"},"property_name":{"type":"string","description":"Metadata key to filter on"},"property_value":{"description":"Value to compare against. Not required for IS NULL / IS NOT NULL operators."}},"required":["comparison_operator","property_name"],"title":"graphiti.EpisodeMetadataFilter"},"GraphitiMetadataFilterGroupType":{"type":"string","enum":["and","or"],"description":"Logical operator: \"and\" or \"or\"","title":"GraphitiMetadataFilterGroupType"},"graphiti.MetadataFilterGroup":{"type":"object","properties":{"filters":{"type":"array","items":{"$ref":"#/components/schemas/graphiti.EpisodeMetadataFilter"},"description":"Leaf filters (predicates on metadata key-value pairs)"},"groups":{"type":"array","items":{"$ref":"#/components/schemas/graphiti.MetadataFilterGroup"},"description":"Nested sub-groups for composing complex boolean expressions"},"type":{"$ref":"#/components/schemas/GraphitiMetadataFilterGroupType","description":"Logical operator: \"and\" or \"or\""}},"required":["type"],"title":"graphiti.MetadataFilterGroup"},"graphiti.PropertyFilter":{"type":"object","properties":{"comparison_operator":{"$ref":"#/components/schemas/graphiti.ComparisonOperator","description":"Comparison operator for property filter"},"property_name":{"type":"string","description":"Property name to filter on"},"property_value":{"description":"Property value to match on. Accepted types: string, int, float64, bool, or nil.\nInvalid types (e.g., arrays, objects) will be rejected by validation.\nMust be non-nil for non-null operators (`=`, `<>`, `>`, `<`, `>=`, `<=`)."}},"required":["comparison_operator","property_name"],"title":"graphiti.PropertyFilter"},"graphiti.SearchFilters":{"type":"object","properties":{"connected_node_uuids":{"type":"array","items":{"type":"string"},"description":"List of node UUIDs to filter edges on: an edge matches if its source OR\ntarget node UUID is in this list. Applies to edges only; rejected on\nrequests whose result type contains no edges. Max 256 entries."},"created_at":{"type":"array","items":{"type":"array","items":{"$ref":"#/components/schemas/graphiti.DateFilter"}},"description":"2D array of date filters for the created_at field.\nThe outer array elements are combined with OR logic.\nThe inner array elements are combined with AND logic.\nExample: `[[{\">\", date1}, {\"<\", date2}], [{\"=\", date3}]]`\nThis translates to: `(created_at > date1 AND created_at < date2) OR (created_at = date3)`"},"edge_types":{"type":"array","items":{"type":"string"},"description":"List of edge types to filter on"},"edge_uuids":{"type":"array","items":{"type":"string"},"description":"List of edge UUIDs to filter on. Max 256 to align with graph-service filter limits."},"episode_metadata_filters":{"$ref":"#/components/schemas/graphiti.MetadataFilterGroup","description":"[Experimental] Episode metadata filter. Restricts results to edges/nodes derived from episodes\nmatching the metadata predicates. Uses explicit AND/OR groups. This feature is experimental and may change in future releases."},"episode_uuids":{"type":"array","items":{"type":"string"},"description":"List of episode UUIDs to filter on. An edge matches if it was derived\nfrom any listed episode; a node matches if it is mentioned by any\nlisted episode. Valid for both edge and node result types. Max 256\nentries."},"exclude_edge_types":{"type":"array","items":{"type":"string"},"description":"List of edge types to exclude from results"},"exclude_node_labels":{"type":"array","items":{"type":"string"},"description":"List of node labels to exclude from results"},"expired_at":{"type":"array","items":{"type":"array","items":{"$ref":"#/components/schemas/graphiti.DateFilter"}},"description":"2D array of date filters for the expired_at field.\nThe outer array elements are combined with OR logic.\nThe inner array elements are combined with AND logic.\nExample: `[[{\">\", date1}, {\"<\", date2}], [{\"=\", date3}]]`\nThis translates to: `(expired_at > date1 AND expired_at < date2) OR (expired_at = date3)`"},"invalid_at":{"type":"array","items":{"type":"array","items":{"$ref":"#/components/schemas/graphiti.DateFilter"}},"description":"2D array of date filters for the invalid_at field.\nThe outer array elements are combined with OR logic.\nThe inner array elements are combined with AND logic.\nExample: `[[{\">\", date1}, {\"<\", date2}], [{\"=\", date3}]]`\nThis translates to: `(invalid_at > date1 AND invalid_at < date2) OR (invalid_at = date3)`"},"node_labels":{"type":"array","items":{"type":"string"},"description":"List of node labels to filter on"},"property_filters":{"type":"array","items":{"$ref":"#/components/schemas/graphiti.PropertyFilter"},"description":"List of property filters to apply to nodes and edges"},"source_node_uuids":{"type":"array","items":{"type":"string"},"description":"List of node UUIDs to filter edges on: an edge matches if its source\nnode UUID is in this list. Applies to edges only; rejected on requests\nwhose result type contains no edges. Max 256 entries."},"target_node_uuids":{"type":"array","items":{"type":"string"},"description":"List of node UUIDs to filter edges on: an edge matches if its target\nnode UUID is in this list. Applies to edges only; rejected on requests\nwhose result type contains no edges. Max 256 entries."},"valid_at":{"type":"array","items":{"type":"array","items":{"$ref":"#/components/schemas/graphiti.DateFilter"}},"description":"2D array of date filters for the valid_at field.\nThe outer array elements are combined with OR logic.\nThe inner array elements are combined with AND logic.\nExample: `[[{\">\", date1}, {\"<\", date2}], [{\"=\", date3}]]`\nThis translates to: `(valid_at > date1 AND valid_at < date2) OR (valid_at = date3)`"}},"title":"graphiti.SearchFilters"},"apidata.PatternSeeds":{"type":"object","properties":{"edge_types":{"type":"array","items":{"type":"string"},"description":"All endpoints of these edge types become seeds"},"node_labels":{"type":"array","items":{"type":"string"},"description":"All nodes with these labels become seeds"},"node_uuids":{"type":"array","items":{"type":"string"},"description":"Specific node UUIDs to analyze around. Max 10000 to align with pattern detection seed limits."}},"title":"apidata.PatternSeeds"},"apidata.DetectPatternsRequest":{"type":"object","properties":{"detect":{"$ref":"#/components/schemas/apidata.DetectConfig","description":"Which pattern types to detect with type-specific configuration.\nOmit to detect all types with defaults. Ignored when query is set."},"edge_limit":{"type":"integer","minimum":1,"maximum":100,"description":"Max resolved edges per pattern. Default: 10, Max: 100. Only used with query."},"graph_id":{"type":"string","description":"Graph ID when detecting patterns on a named graph"},"limit":{"type":"integer","minimum":1,"maximum":200,"description":"Max patterns to return. Default: 50, Max: 200"},"min_occurrences":{"type":"integer","minimum":1,"description":"Minimum occurrence count to report a pattern. Default: 2"},"query":{"type":"string","minLength":1,"maxLength":400,"description":"Search query for discovering seed nodes via hybrid search.\nWhen set, forces triple-frequency detection only and enables edge resolution\nwith cross-encoder reranking. Mutually exclusive with seeds."},"query_limit":{"type":"integer","minimum":1,"maximum":50,"description":"Max seed nodes from search. Default: 10, Max: 50. Only used with query."},"recency_weight":{"$ref":"#/components/schemas/apidata.RecencyWeight","description":"Exponential half-life decay applied to edge created_at timestamps.\nValid values: none, 7_days, 30_days, 90_days. Default: none"},"search_filters":{"$ref":"#/components/schemas/graphiti.SearchFilters","description":"Filters which edges/nodes participate in pattern detection.\nReuses the same filter format as /graph/search."},"seeds":{"$ref":"#/components/schemas/apidata.PatternSeeds","description":"Seed selection. If omitted, analyzes the entire graph. Mutually exclusive with query."},"user_id":{"type":"string","description":"User ID when detecting patterns on a user graph"}},"title":"apidata.DetectPatternsRequest"},"apidata.PatternMetadata":{"type":"object","properties":{"edges_analyzed":{"type":"integer","description":"Number of edges analyzed"},"elapsed_ms":{"type":"integer","description":"Elapsed time in milliseconds"},"nodes_analyzed":{"type":"integer","description":"Number of unique nodes analyzed"}},"title":"apidata.PatternMetadata"},"apidata.PatternResult":{"type":"object","properties":{"description":{"type":"string","description":"Human-readable structural description of the pattern (e.g. \"Person -[KNOWS]-> Person\").\nOmitted in query mode in favor of Summary."},"edge_types":{"type":"array","items":{"type":"string"},"description":"Edge types in the pattern structure"},"edges":{"type":"array","items":{"$ref":"#/components/schemas/graphiti.EntityEdge"},"description":"Resolved edges for this pattern, sorted by cross-encoder relevance.\nOnly populated when query is set."},"node_labels":{"type":"array","items":{"type":"string"},"description":"Node labels in the pattern structure"},"occurrences":{"type":"integer","description":"Raw structural occurrence count (always unweighted).\nReflects pattern frequency in the graph, not the number of resolved edges after filtering."},"summary":{"type":"string","description":"Fact-derived summary from top reranked edges. Only populated when query is set.\nThis is the primary display field for QA consumers."},"type":{"type":"string","description":"Pattern type: relationship, path, co_occurrence, hub, cluster"},"weighted_score":{"type":"number","format":"double","description":"Weighted structural support — equals occurrences when recency_weight is \"none\".\nReflects graph-level support, not post-enrichment edge count."}},"title":"apidata.PatternResult"},"apidata.DetectPatternsResponse":{"type":"object","properties":{"metadata":{"$ref":"#/components/schemas/apidata.PatternMetadata","description":"Statistics about the detection run"},"nodes":{"type":"array","items":{"$ref":"#/components/schemas/graphiti.EntityNode"},"description":"Resolved nodes referenced by pattern edges (deduplicated). Only populated when query is set."},"patterns":{"type":"array","items":{"$ref":"#/components/schemas/apidata.PatternResult"},"description":"Detected patterns, sorted by weighted_score descending"}},"title":"apidata.DetectPatternsResponse"},"graphiti.Reranker":{"type":"string","enum":["rrf","mmr","node_distance","episode_mentions","cross_encoder"],"title":"graphiti.Reranker"},"graphiti.GraphSearchScope":{"type":"string","enum":["edges","nodes","episodes","thread_summaries","observations","auto"],"title":"graphiti.GraphSearchScope"},"graphiti.GraphSearchQuery":{"type":"object","properties":{"bfs_origin_node_uuids":{"type":"array","items":{"type":"string"},"description":"Nodes that are the origins of the BFS searches"},"center_node_uuid":{"type":"string","description":"Node to rerank around for node distance reranking"},"graph_id":{"type":"string","description":"The graph_id to search in. When searching user graph, please use user_id instead."},"limit":{"type":"integer","maximum":50,"description":"The maximum number of facts to retrieve for non-auto scopes. Defaults to 10. Limited to 50. Ignored when scope=auto."},"max_characters":{"type":"integer","minimum":1,"maximum":50000,"description":"Maximum total characters across all selected results when scope=auto. Defaults to 2500. Limited to 50000."},"mmr_lambda":{"type":"number","format":"double","description":"weighting for maximal marginal relevance"},"query":{"type":"string","maxLength":400,"description":"The string to search for (required)"},"reranker":{"$ref":"#/components/schemas/graphiti.Reranker","description":"Defaults to RRF. Ignored when scope=auto except node_distance and episode_mentions are rejected;\nauto search always uses RRF retrieval and applies its own internal rerank after retrieval.\nepisode_mentions ranks edge candidates by how many of the episodes listed\nin search_filters.episode_uuids mention them; without episode_uuids it has\nno effect and results are ranked as if no reranker were specified."},"return_raw_results":{"type":"boolean","description":"When scope=auto, include the selected raw graph results alongside the materialized context block.\nFor graph-service-backed auto mode, selected raw results may include episodes,\nedges, nodes, observations, and thread_summaries."},"scope":{"$ref":"#/components/schemas/graphiti.GraphSearchScope","description":"Defaults to Edges."},"search_filters":{"$ref":"#/components/schemas/graphiti.SearchFilters","description":"Search filters to apply to the search"},"user_id":{"type":"string","description":"The user_id when searching user graph. If not searching user graph, please use graph_id instead."}},"required":["query"],"title":"graphiti.GraphSearchQuery"},"graphiti.DerivedNode":{"type":"object","properties":{"attributes":{"type":"object","additionalProperties":{"description":"Any type"},"description":"Additional attributes of the derived node."},"created_at":{"type":"string","description":"Creation time of the node"},"end_at":{"type":"string","description":"EndAt is the close timestamp of the evidence window. Set when the\nunderlying pattern is no longer supported (closed observations);\nnil for active observations."},"episode_ids":{"type":"array","items":{"type":"string"},"description":"Episode UUIDs that support this observation. Only populated for observation nodes in web API responses."},"labels":{"type":"array","items":{"type":"string"},"description":"Labels associated with the node"},"latest_evidence_at":{"type":"string","description":"LatestEvidenceAt is the most recent source-episode timestamp from\nwhich this observation drew evidence."},"name":{"type":"string","description":"Name of the node"},"relevance":{"type":"number","format":"double","description":"Relevance is an experimental rank-aligned score in [0,1] derived from Score via logit transformation.\nOnly populated when using cross_encoder reranker; omitted for other reranker types (e.g., RRF)."},"score":{"type":"number","format":"double","description":"Score is the reranker output: sigmoid-distributed logits [0,1] when using cross_encoder reranker, or RRF ordinal rank when using rrf reranker"},"selection_rank":{"type":"integer","description":"SelectionRank is the global cross-scope rank assigned by auto scope selection."},"start_at":{"type":"string","description":"StartAt is the earliest source-episode timestamp from which this\nobservation was derived. Only populated for observation nodes."},"summary":{"type":"string","description":"Region summary of member nodes"},"uuid":{"type":"string","description":"UUID of the node"}},"required":["created_at","name","uuid"],"title":"graphiti.DerivedNode"},"apidata.GraphSearchResponseMetadata":{"type":"object","properties":{"server_latency_ms":{"type":"integer","description":"Server-side processing latency in milliseconds."}},"title":"apidata.GraphSearchResponseMetadata"},"graphiti.SagaNode":{"type":"object","properties":{"created_at":{"type":"string","description":"Creation time of the node"},"labels":{"type":"array","items":{"type":"string"},"description":"Labels associated with the node"},"last_summarized_at":{"type":"string","description":"Wall-clock timestamp of the most recent summary update. Used internally\nas the watermark for filtering new episodes by ingestion time."},"last_summarized_episode_valid_at":{"type":"string","description":"Maximum episode reference time (valid_at) covered by the most recent\nsummary. Use this field — not LastSummarizedAt — when answering \"how\nrecent is this summary's content in event-time?\"."},"name":{"type":"string","description":"Name of the node"},"relevance":{"type":"number","format":"double","description":"Relevance is an experimental rank-aligned score in [0,1] derived from Score via logit transformation.\nOnly populated when using cross_encoder reranker; omitted for other reranker types (e.g., RRF)."},"score":{"type":"number","format":"double","description":"Score is the reranker output: sigmoid-distributed logits [0,1] when using cross_encoder reranker, or RRF ordinal rank when using rrf reranker"},"selection_rank":{"type":"integer","description":"SelectionRank is the global cross-scope rank assigned by auto scope selection."},"summary":{"type":"string","description":"Incremental summary of the thread."},"uuid":{"type":"string","description":"UUID of the node"}},"required":["created_at","name","uuid"],"title":"graphiti.SagaNode"},"apidata.GraphSearchResults":{"type":"object","properties":{"context":{"type":"string"},"edges":{"type":"array","items":{"$ref":"#/components/schemas/graphiti.EntityEdge"}},"episodes":{"type":"array","items":{"$ref":"#/components/schemas/apidata.GraphEpisode"}},"nodes":{"type":"array","items":{"$ref":"#/components/schemas/graphiti.EntityNode"}},"observations":{"type":"array","items":{"$ref":"#/components/schemas/graphiti.DerivedNode"}},"response":{"$ref":"#/components/schemas/apidata.GraphSearchResponseMetadata"},"thread_summaries":{"type":"array","items":{"$ref":"#/components/schemas/graphiti.SagaNode"}}},"title":"apidata.GraphSearchResults"},"apidata.GraphSubgraphRequest":{"type":"object","properties":{"depth":{"type":"integer","minimum":1,"maximum":3,"description":"Maximum traversal depth from the seeds. 1-3. Defaults to 1."},"direction":{"type":"string","description":"Edge orientation followed during expansion, relative to each frontier\nnode: \"in\" | \"out\" | \"both\". Defaults to \"both\"."},"graph_id":{"type":"string","description":"graph_id identifies the target named graph. Exactly one of user_id or\ngraph_id is required."},"max_edges":{"type":"integer","minimum":1,"maximum":1000,"description":"Maximum number of edges in the response. 1-1000. Defaults to 200."},"max_nodes":{"type":"integer","minimum":1,"maximum":500,"description":"Maximum number of nodes in the response, including admitted seeds.\n1-500. Defaults to 100."},"search_filters":{"$ref":"#/components/schemas/graphiti.SearchFilters","description":"Filters constraining traversed edges and included nodes. Reuses the\ngraph.search filter type. search_filters.episode_metadata_filters is\nrejected: it cannot be enforced during graph traversal."},"seed_node_uuids":{"type":"array","items":{"type":"string"},"description":"Seed node UUIDs to expand from, in traversal-priority order: seeds are\nadmitted before any expansion, in this order, and count toward\nmax_nodes first. 1-20 entries, required. Seeds that do not exist in\nthe target graph are ignored, not an error."},"user_id":{"type":"string","description":"user_id identifies the target user graph. Exactly one of user_id or\ngraph_id is required."}},"required":["seed_node_uuids"],"title":"apidata.GraphSubgraphRequest"},"apidata.GraphSubgraphResponse":{"type":"object","properties":{"edges":{"type":"array","items":{"$ref":"#/components/schemas/graphiti.EntityEdge"},"description":"Every traversed edge that passed the request filters. Both endpoints\nof every edge are present in Nodes (edge-endpoint closure)."},"nodes":{"type":"array","items":{"$ref":"#/components/schemas/graphiti.EntityNode"},"description":"Every admitted seed and every node reached within budget."},"truncated":{"type":"boolean","description":"True whenever any budget or internal limit reduced the result."},"truncation_reason":{"type":"string","description":"Names the binding limit (for example \"max_nodes\", \"max_edges\") when\nTruncated is true; nil otherwise."}},"title":"apidata.GraphSubgraphResponse"},"apidata.UpdateGraphRequest":{"type":"object","properties":{"description":{"type":["string","null"],"maxLength":2000},"name":{"type":["string","null"],"maxLength":255},"time_zone":{"type":["string","null"],"description":"The graph's IANA time zone. Stored on its group-backed subject."}},"title":"apidata.UpdateGraphRequest"},"apidata.GraphEdgesRequest":{"type":"object","properties":{"cursor":{"type":"string","description":"Opaque cursor for pagination, obtained from the Zep-Next-Cursor response header\nof the previous page. Encodes the sort field, direction, and continuation position."},"direction":{"type":"string","description":"Sort direction. One of \"asc\" or \"desc\" (default \"desc\")."},"filters":{"$ref":"#/components/schemas/graphiti.SearchFilters","description":"Optional filters applied to the listed artifacts. Reuses the graph.search filter type."},"limit":{"type":"integer","description":"Maximum number of items to return"},"order_by":{"type":"string","description":"Field to sort by. One of \"created_at\", \"valid_at\", or \"uuid\" (default \"uuid\")."},"uuid_cursor":{"type":"string","description":"UUID based cursor, used for pagination. Should be the UUID of the last item in the previous page.\n\nDeprecated: prefer Cursor, the opaque cursor returned via the Zep-Next-Cursor response header."}},"title":"apidata.GraphEdgesRequest"},"apidata.UpdateEdgeRequest":{"type":"object","properties":{"attributes":{"type":"object","additionalProperties":{"description":"Any type"},"description":"Updated attributes. Merged with existing attributes. Set a key to null to delete it."},"expired_at":{"type":"string","description":"Updated time at which the edge expires"},"fact":{"type":"string","maxLength":250,"description":"Updated fact for the edge"},"invalid_at":{"type":"string","description":"Updated time at which the fact stopped being true"},"name":{"type":"string","minLength":1,"maxLength":50,"description":"Updated name (relationship type) for the edge"},"valid_at":{"type":"string","description":"Updated time at which the fact becomes true"}},"title":"apidata.UpdateEdgeRequest"},"apidata.GraphEpisodeListRequest":{"type":"object","properties":{"cursor":{"type":"string","description":"Opaque cursor for pagination, obtained from the Zep-Next-Cursor\nresponse header of the previous page."},"direction":{"type":"string","description":"Sort direction. One of \"asc\" or \"desc\". Defaults to \"desc\"."},"limit":{"type":"integer","description":"Maximum number of episodes to return. An explicit value is clamped to\n50; when omitted, the default page size (100) applies."},"mentioned_node_uuids":{"type":"array","items":{"type":"string"},"description":"Restricts results to episodes that mention any of the listed node\nUUIDs. At most 256 entries; each must be a syntactically valid UUID."},"order_by":{"type":"string","description":"Field to sort by. One of \"uuid\" or \"created_at\". Defaults to \"uuid\"."}},"title":"apidata.GraphEpisodeListRequest"},"apidata.UpdateEpisodeRequest":{"type":"object","properties":{"metadata":{"type":"object","additionalProperties":{"description":"Any type"},"description":"Updated metadata. Merged with existing metadata: supplied keys overwrite/add, keys set to null are removed. Maximum 10 keys. Values must be scalars (string, number, boolean, null) or arrays of scalars."}},"required":["metadata"],"title":"apidata.UpdateEpisodeRequest"},"apidata.EpisodeMentions":{"type":"object","properties":{"edges":{"type":"array","items":{"$ref":"#/components/schemas/graphiti.EntityEdge"}},"nodes":{"type":"array","items":{"$ref":"#/components/schemas/graphiti.EntityNode"}}},"title":"apidata.EpisodeMentions"},"graphiti.AddNodeItem":{"type":"object","properties":{"attributes":{"type":"object","additionalProperties":{"description":"Any type"},"description":"Additional attributes of the node. Values must be scalar types (string,\nnumber, boolean, or null). Nested objects and arrays are not allowed."},"created_at":{"type":"string","description":"The node creation time. Defaults to the request time when absent."},"label":{"type":"string","maxLength":100,"description":"The node's entity type. At most one; the base \"Entity\" label is added\nimplicitly by the graph layer on save and does not need to be supplied."},"metadata":{"type":"object","additionalProperties":{"description":"Any type"},"description":"Optional metadata attached to the node's shadow episode. Max 10 scalar\nkey-value pairs."},"name":{"type":"string","minLength":1,"maxLength":50,"description":"The name of the node. Used to derive the node's search embedding."},"summary":{"type":"string","maxLength":500,"description":"A regional summary of the node."}},"required":["name"],"title":"graphiti.AddNodeItem"},"graphiti.AddNodesRequest":{"type":"object","properties":{"graph_id":{"type":"string"},"nodes":{"type":"array","items":{"$ref":"#/components/schemas/graphiti.AddNodeItem"},"description":"The nodes to add. 1 to 100 items."},"user_id":{"type":"string"}},"required":["nodes"],"title":"graphiti.AddNodesRequest"},"graphiti.AddedNode":{"type":"object","properties":{"attributes":{"type":"object","additionalProperties":{"description":"Any type"},"description":"Additional attributes of the node."},"created_at":{"type":"string","description":"The node creation time."},"label":{"type":"string","maxLength":100,"description":"The node's entity type."},"metadata":{"type":"object","additionalProperties":{"description":"Any type"},"description":"Metadata attached to the node's shadow episode."},"name":{"type":"string","minLength":1,"maxLength":50,"description":"The name of the node."},"summary":{"type":"string","maxLength":500,"description":"A regional summary of the node."},"uuid":{"type":"string","description":"The node UUID, assigned by Zep."}},"required":["name"],"title":"graphiti.AddedNode"},"graphiti.AddNodesResponse":{"type":"object","properties":{"nodes":{"type":"array","items":{"$ref":"#/components/schemas/graphiti.AddedNode"},"description":"The accepted nodes, each carrying the UUID Zep assigned to it, in request\norder."},"task_id":{"type":"string","description":"Task ID of the async add-nodes task."}},"title":"graphiti.AddNodesResponse"},"apidata.GraphNodesRequest":{"type":"object","properties":{"cursor":{"type":"string","description":"Opaque cursor for pagination, obtained from the Zep-Next-Cursor response header\nof the previous page. Encodes the sort field, direction, and continuation position."},"direction":{"type":"string","description":"Sort direction. One of \"asc\" or \"desc\" (default \"desc\")."},"filters":{"$ref":"#/components/schemas/graphiti.SearchFilters","description":"Optional filters applied to the listed artifacts. Reuses the graph.search filter type."},"limit":{"type":"integer","description":"Maximum number of items to return"},"order_by":{"type":"string","description":"Field to sort by. One of \"created_at\", \"valid_at\", or \"uuid\" (default \"uuid\")."},"uuid_cursor":{"type":"string","description":"UUID based cursor, used for pagination. Should be the UUID of the last item in the previous page.\n\nDeprecated: prefer Cursor, the opaque cursor returned via the Zep-Next-Cursor response header."}},"title":"apidata.GraphNodesRequest"},"apidata.GraphNodeNeighborsRequest":{"type":"object","properties":{"cursor":{"type":"string","description":"Opaque cursor for pagination, obtained from the Zep-Next-Cursor\nresponse header of the previous page."},"direction":{"type":"string","description":"Orientation of the connecting edge relative to the anchor node: \"out\"\n(anchor is the edge's source), \"in\" (anchor is the edge's target), or\n\"both\" (either). Defaults to \"both\"."},"direction_sort":{"type":"string","description":"Sort direction for order_by. One of \"asc\" or \"desc\". Defaults to\n\"desc\". Named direction_sort to avoid clashing with the traversal\nDirection field above."},"filters":{"$ref":"#/components/schemas/graphiti.SearchFilters","description":"Filters constraining the connecting edges (edge types, dates, and the\nnode- and episode-anchored UUID fields) and the neighbor nodes\n(node_labels/exclude_node_labels). Reuses the graph.search filter\ntype."},"limit":{"type":"integer","description":"Maximum number of neighbor nodes to return. An explicit value is\nclamped to 50; when omitted, the default page size (100) applies."},"order_by":{"type":"string","description":"Field to sort neighbor nodes by. One of \"uuid\" or \"created_at\".\nDefaults to \"uuid\"."}},"title":"apidata.GraphNodeNeighborsRequest"},"apidata.GraphNodeNeighbor":{"type":"object","properties":{"edges":{"type":"array","items":{"$ref":"#/components/schemas/graphiti.EntityEdge"}},"node":{"$ref":"#/components/schemas/graphiti.EntityNode"}},"title":"apidata.GraphNodeNeighbor"},"apidata.UpdateNodeRequest":{"type":"object","properties":{"attributes":{"type":"object","additionalProperties":{"description":"Any type"},"description":"Updated attributes. Merged with existing attributes. Set a key to null to delete it."},"labels":{"type":"array","items":{"type":"string"},"description":"Updated labels for the node"},"name":{"type":"string","minLength":1,"maxLength":50,"description":"Updated name for the node"},"summary":{"type":"string","maxLength":500,"description":"Updated summary for the node"}},"title":"apidata.UpdateNodeRequest"},"apidata.CustomInstruction":{"type":"object","properties":{"name":{"type":"string","maxLength":100},"text":{"type":"string","minLength":1,"maxLength":5000}},"required":["name","text"],"title":"apidata.CustomInstruction"},"apidata.ListCustomInstructionsResponse":{"type":"object","properties":{"instructions":{"type":"array","items":{"$ref":"#/components/schemas/apidata.CustomInstruction"}}},"title":"apidata.ListCustomInstructionsResponse"},"apidata.AddCustomInstructionsRequest":{"type":"object","properties":{"graph_ids":{"type":"array","items":{"type":"string"},"description":"Graph IDs to add the instructions to. If empty, the instructions are added to the project-wide default."},"instructions":{"type":"array","items":{"$ref":"#/components/schemas/apidata.CustomInstruction"},"description":"Instructions to add to the graph."},"user_ids":{"type":"array","items":{"type":"string"},"description":"User IDs to add the instructions to. If empty, the instructions are added to the project-wide default."}},"required":["instructions"],"title":"apidata.AddCustomInstructionsRequest"},"apidata.DeleteCustomInstructionsRequest":{"type":"object","properties":{"graph_ids":{"type":"array","items":{"type":"string"},"description":"Determines which group graphs will have their custom instructions deleted. If no graphs are provided, the project-wide custom instructions will be affected."},"instruction_names":{"type":"array","items":{"type":"string"},"description":"Unique identifier for the instructions to be deleted. If empty deletes all instructions."},"user_ids":{"type":"array","items":{"type":"string"},"description":"Determines which user graphs will have their custom instructions deleted. If no users are provided, the project-wide custom instructions will be affected."}},"title":"apidata.DeleteCustomInstructionsRequest"},"apidata.GraphObservationsRequest":{"type":"object","properties":{"cursor":{"type":"string","description":"Opaque cursor for pagination, obtained from the Zep-Next-Cursor response header\nof the previous page. Encodes the sort field, direction, and continuation position."},"direction":{"type":"string","description":"Sort direction. One of \"asc\" or \"desc\" (default \"desc\")."},"filters":{"$ref":"#/components/schemas/graphiti.SearchFilters","description":"Optional filters applied to the listed artifacts. Reuses the graph.search filter type."},"limit":{"type":"integer","description":"Maximum number of items to return"},"order_by":{"type":"string","description":"Field to sort by. One of \"created_at\", \"valid_at\", or \"uuid\" (default \"uuid\")."},"uuid_cursor":{"type":"string","description":"UUID based cursor, used for pagination. Should be the UUID of the last item in the previous page.\n\nDeprecated: prefer Cursor, the opaque cursor returned via the Zep-Next-Cursor response header."}},"title":"apidata.GraphObservationsRequest"},"apidata.GraphThreadSummariesRequest":{"type":"object","properties":{"cursor":{"type":"string","description":"Opaque cursor for pagination, obtained from the Zep-Next-Cursor response header\nof the previous page. Encodes the sort field, direction, and continuation position."},"direction":{"type":"string","description":"Sort direction. One of \"asc\" or \"desc\" (default \"desc\")."},"filters":{"$ref":"#/components/schemas/graphiti.SearchFilters","description":"Optional filters applied to the listed artifacts. Reuses the graph.search filter type."},"limit":{"type":"integer","description":"Maximum number of items to return"},"order_by":{"type":"string","description":"Field to sort by. One of \"created_at\", \"valid_at\", or \"uuid\" (default \"uuid\")."},"uuid_cursor":{"type":"string","description":"UUID based cursor, used for pagination. Should be the UUID of the last item in the previous page.\n\nDeprecated: prefer Cursor, the opaque cursor returned via the Zep-Next-Cursor response header."}},"title":"apidata.GraphThreadSummariesRequest"},"apidata.GraphDocumentSummariesRequest":{"type":"object","properties":{"cursor":{"type":"string","description":"Opaque cursor for pagination, obtained from the Zep-Next-Cursor response header\nof the previous page. Encodes the sort field, direction, and continuation position."},"direction":{"type":"string","description":"Sort direction. One of \"asc\" or \"desc\" (default \"desc\")."},"filters":{"$ref":"#/components/schemas/graphiti.SearchFilters","description":"Optional filters applied to the listed artifacts. Reuses the graph.search filter type."},"limit":{"type":"integer","description":"Maximum number of items to return"},"order_by":{"type":"string","description":"Field to sort by. One of \"created_at\", \"valid_at\", or \"uuid\" (default \"uuid\")."},"uuid_cursor":{"type":"string","description":"UUID based cursor, used for pagination. Should be the UUID of the last item in the previous page.\n\nDeprecated: prefer Cursor, the opaque cursor returned via the Zep-Next-Cursor response header."}},"title":"apidata.GraphDocumentSummariesRequest"},"apidata.DocumentSummary":{"type":"object","properties":{"created_at":{"type":"string","description":"CreatedAt is when the summary node was first created."},"document_id":{"type":"string","description":"DocumentID is the customer-facing document identifier."},"last_summarized_at":{"type":"string","description":"LastSummarizedAt is the wall-clock timestamp of the most recent\nsummary update."},"last_summarized_episode_valid_at":{"type":"string","description":"LastSummarizedEpisodeValidAt is the maximum episode reference time\n(valid_at) covered by the most recent summary."},"summary":{"type":"string","description":"Summary is the incremental summary content."},"uuid":{"type":"string","description":"UUID of the document summary (derived) node."}},"title":"apidata.DocumentSummary"},"apidata.ProjectInfo":{"type":"object","properties":{"created_at":{"type":"string"},"default_time_zone":{"type":["string","null"]},"description":{"type":"string"},"name":{"type":"string"},"uuid":{"type":"string"}},"title":"apidata.ProjectInfo"},"apidata.ProjectInfoResponse":{"type":"object","properties":{"project":{"$ref":"#/components/schemas/apidata.ProjectInfo"}},"title":"apidata.ProjectInfoResponse"},"apidata.UpdateProjectInfoRequest":{"type":"object","properties":{"default_time_zone":{"type":["string","null"],"description":"The project's IANA fallback time zone. Null clears the existing value."}},"title":"apidata.UpdateProjectInfoRequest"},"apidata.ObservationType":{"type":"object","properties":{"description":{"type":"string","maxLength":500},"name":{"type":"string","maxLength":50}},"required":["description","name"],"title":"apidata.ObservationType"},"apidata.ObservationSteeringConfig":{"type":"object","properties":{"instruction":{"type":["string","null"],"maxLength":2000},"types":{"type":"array","items":{"$ref":"#/components/schemas/apidata.ObservationType"}}},"title":"apidata.ObservationSteeringConfig"},"apidata.TaskErrorResponse":{"type":"object","properties":{"code":{"type":"string"},"details":{"type":"object","additionalProperties":{"description":"Any type"}},"message":{"type":"string"}},"title":"apidata.TaskErrorResponse"},"apidata.TaskProgress":{"type":"object","properties":{"message":{"type":"string"},"stage":{"type":"string"}},"title":"apidata.TaskProgress"},"apidata.GetTaskResponse":{"type":"object","properties":{"completed_at":{"type":"string"},"created_at":{"type":"string"},"error":{"$ref":"#/components/schemas/apidata.TaskErrorResponse"},"params":{"type":"object","additionalProperties":{"description":"Any type"}},"progress":{"$ref":"#/components/schemas/apidata.TaskProgress"},"started_at":{"type":"string"},"status":{"type":"string"},"task_id":{"type":"string"},"type":{"type":"string"},"updated_at":{"type":"string"}},"title":"apidata.GetTaskResponse"},"apidata.CreateBatchRequest":{"type":"object","properties":{"ignore_roles":{"type":"array","items":{"$ref":"#/components/schemas/apidata.RoleType"},"description":"Optional list of message role types to skip during graph ingestion for\nthread_message items in this batch. The messages are still stored and\nretained as context, but no graph extraction is performed for them.\nHas no effect on graph_episode items."},"metadata":{"type":"object","additionalProperties":{"description":"Any type"}},"strict_ontology":{"type":"boolean","description":"When true, prevents extraction of generic Entity nodes that do not match the configured ontology."}},"title":"apidata.CreateBatchRequest"},"apidata.BatchProgress":{"type":"object","properties":{"canceled_items":{"type":"integer"},"failed_items":{"type":"integer"},"percent_complete":{"type":"number","format":"double"},"processing_items":{"type":"integer"},"queued_items":{"type":"integer"},"skipped_items":{"type":"integer"},"succeeded_items":{"type":"integer"},"total_items":{"type":"integer"}},"title":"apidata.BatchProgress"},"models.BatchStatus":{"type":"string","enum":["draft","invalid","queued","processing","succeeded","partial","failed","canceled"],"title":"models.BatchStatus"},"apidata.BatchSummary":{"type":"object","properties":{"batch_id":{"type":"string"},"completed_at":{"type":"string"},"created_at":{"type":"string"},"ignore_roles":{"type":"array","items":{"$ref":"#/components/schemas/apidata.RoleType"}},"item_count":{"type":"integer"},"metadata":{"type":"object","additionalProperties":{"description":"Any type"}},"processed_at":{"type":"string"},"progress":{"$ref":"#/components/schemas/apidata.BatchProgress"},"status":{"$ref":"#/components/schemas/models.BatchStatus"},"strict_ontology":{"type":"boolean"},"updated_at":{"type":"string"}},"title":"apidata.BatchSummary"},"models.BatchItemKind":{"type":"string","enum":["graph_episode","thread_message"],"title":"models.BatchItemKind"},"apidata.BatchAddItem":{"type":"object","properties":{"content":{"type":"string"},"created_at":{"type":"string"},"data":{"type":"string"},"data_type":{"$ref":"#/components/schemas/models.GraphDataType"},"document_id":{"type":"string","minLength":1,"maxLength":100,"description":"Optional document ID for graph_episode items. Groups episodes as document\nchunks. Ignored for thread_message items."},"graph_id":{"type":"string"},"metadata":{"type":"object","additionalProperties":{"description":"Any type"}},"name":{"type":"string"},"role":{"$ref":"#/components/schemas/apidata.RoleType"},"source_description":{"type":"string","maxLength":500},"thread_id":{"type":"string"},"type":{"$ref":"#/components/schemas/models.BatchItemKind"},"user_id":{"type":"string"}},"required":["type"],"title":"apidata.BatchAddItem"},"apidata.AddBatchItemsRequest":{"type":"object","properties":{"items":{"type":"array","items":{"$ref":"#/components/schemas/apidata.BatchAddItem"}}},"required":["items"],"title":"apidata.AddBatchItemsRequest"},"models.BatchItemStatus":{"type":"string","enum":["pending","queued","processing","succeeded","failed","skipped","canceled"],"title":"models.BatchItemStatus"},"apidata.BatchItemDetail":{"type":"object","properties":{"created_at":{"type":"string"},"document_id":{"type":"string"},"episode_uuid":{"type":"string","description":"EpisodeUUID is the UUID of the episode that will be (or has been) created\nfor this batch item. Populated for every item kind and always equal to\nSourceUUID — the underlying source row's UUID is reused as the episode\nUUID during processing."},"error":{"type":"object","additionalProperties":{"description":"Any type"}},"graph_id":{"type":"string"},"graph_uuid":{"type":"string"},"item_id":{"type":"string"},"kind":{"$ref":"#/components/schemas/models.BatchItemKind"},"sequence_index":{"type":"integer"},"source_uuid":{"type":"string"},"status":{"$ref":"#/components/schemas/models.BatchItemStatus"},"thread_id":{"type":"string"},"updated_at":{"type":"string"},"user_id":{"type":"string"},"user_uuid":{"type":"string"}},"title":"apidata.BatchItemDetail"},"apidata.BatchInvalidItem":{"type":"object","properties":{"graph_id":{"type":"string"},"item_id":{"type":"string"},"reason":{"type":"string"},"sequence_index":{"type":"integer"},"source_uuid":{"type":"string"},"thread_id":{"type":"string"},"user_id":{"type":"string"}},"title":"apidata.BatchInvalidItem"},"apidata.BatchInvalidReferencesError":{"type":"object","properties":{"code":{"type":"string"},"invalid_items":{"type":"array","items":{"$ref":"#/components/schemas/apidata.BatchInvalidItem"}},"message":{"type":"string"}},"title":"apidata.BatchInvalidReferencesError"},"apidata.BatchListResponse":{"type":"object","properties":{"batches":{"type":"array","items":{"$ref":"#/components/schemas/apidata.BatchSummary"}},"next_cursor":{"type":"integer"}},"title":"apidata.BatchListResponse"},"apidata.BatchItemListResponse":{"type":"object","properties":{"items":{"type":"array","items":{"$ref":"#/components/schemas/apidata.BatchItemDetail"}},"next_cursor":{"type":"integer"}},"title":"apidata.BatchItemListResponse"}},"securitySchemes":{"Api-Key":{"type":"apiKey","in":"header","name":"Authorization","description":"Type \"Api-Key\" followed by a space and JWT token."}}}}