Data

Verify a data record against a schema

post

Verify that a data record satisfies a JSON schema without saving it to the database.

Required scope: user-data

Authorizations
AuthorizationstringRequired

Enter JWT access token

Body

DTO for verifying data against a JSON schema, can have any properties in additional to the required schemaUri

schemaUristringRequired

URL to JSON schema for validation

Example: https://example.com/schemas/memory.json
Responses
200

Validation completed

application/json
post
/api/v1/data/verify

Get data records

get

Get Data Records

This endpoint provides skip-based pagination for querying data records.

Key Features

  • Pagination: Uses page numbers and limits for simple pagination

  • Flexible filtering: Support for complex MongoDB-style filter (passed as URL-encoded JSON)

  • Simple sorting: Sort by predefined fields with asc/desc order

Usage Examples

First Page Request

GET /data/v1/memories?page=1&limit=20&filter=%7B%22status%22%3A%22active%22%7D&sortBy=createdAt&sortOrder=desc

Next Page Request

GET /data/v1/memories?page=2&limit=20&filter=%7B%22status%22%3A%22active%22%7D&sortBy=createdAt&sortOrder=desc

Sort by Updated Date

GET /data/v1/memories?page=1&limit=10&sortBy=updatedAt&sortOrder=asc

Filter Examples

  • Simple filter: { "status": "active" }

  • Date range filter: { "createdAt": { "$gte": "2025-01-01T00:00:00.000Z" } }

  • ObjectId filter: { "id": "507f1f77bcf86cd799439011" }

  • Complex filter: { "$and": [{ "status": "active" }, { "priority": { "$gte": 5 } }] }

Required scope: user-data

Authorizations
AuthorizationstringRequired

Enter JWT access token

Path parameters
collectionstringRequired

Collection to look into

Example: memories
Query parameters
filterstringOptional

MongoDB-style filter object (passed as URL-encoded JSON string)

Example: { "status": "active" }
sortBystring · enumOptional

Field to sort by

Example: createdAtPossible values:
sortOrderstring · enumOptional

Sort order

Example: descPossible values:
limitnumberOptional

Number of records to return (1-100)

Example: 20
pagenumberOptional

Page number (1-based)

Example: 1
Responses
200

Query executed successfully

application/json
get
/api/v1/data/{collection}

Create a new data record

post

Creates a new record in the specified collection.

Required scope: user-data

Authorizations
AuthorizationstringRequired

Enter JWT access token

Path parameters
collectionstringRequired

Collection to create the record into

Example: memories
Body

DTO for creating a new record, can have any properties in addition to the schemaUri used for validation.

schemaUristringOptional

URL to JSON schema for validation

Example: https://example.com/schemas/memory.json
Responses
post
/api/v1/data/{collection}

Get data record by ID

get

Retrieves a single data record by its unique identifier for a given collection.

Required scope: user-data

Authorizations
AuthorizationstringRequired

Enter JWT access token

Path parameters
collectionstringRequired

Collection to look into

Example: memories
recordIdstringRequired

ID of the data record to retrieve

Example: 66bd3762c23f9e3f152fb4d1
Responses
200

Data record retrieved successfully

application/json
get
/api/v1/data/{collection}/{recordId}

Update an existing data record

put

Updates an existing data record.

Required scope: user-data

Authorizations
AuthorizationstringRequired

Enter JWT access token

Path parameters
collectionstringRequired

Collection the record belongs to

Example: memories
recordIdstringRequired

ID of the data record to update

Example: 66bd3762c23f9e3f152fb4d1
Body

DTO for updating an existing record, can have any properties in addition to the optional schemaUri used for validation.

schemaUristringOptional

URL to JSON schema for validation

Example: https://example.com/schemas/memory.json
Responses
200

Data record updated successfully

application/json
put
/api/v1/data/{collection}/{recordId}

Delete a data record by ID

delete

Deletes a data record from the specified collection by its unique identifier.

Required scope: user-data

Authorizations
AuthorizationstringRequired

Enter JWT access token

Path parameters
collectionstringRequired

Collection the record belongs to

Example: memories
recordIdstringRequired

ID of the data record to delete

Example: 66bd3762c23f9e3f152fb4d1
Responses
delete
/api/v1/data/{collection}/{recordId}

No content

Last updated