GenuineAIGenuineAI
For usersFor developers
  • Overview
  • Guides
  • How-to
  • API reference
Documentation
  • Quickstart
  • Authentication
  • Errors
  • Rate limits
  • API reference
Platform
  • Platform overview
  • Solutions
  • Pricing
  • Sign in
Company
  • Status
  • Trust Center
  • Contact
  • Terms of Service
  • Privacy Policy

© 2026 GenuineAI Ventures LLC

support@genuinehq.com
Overview
Core
Media library
    Files
      List filesgetCreate an empty documentpostGet a filegetUpdate a fileputDelete a filedeleteCopy to the librarypostFavorite or unfavoritepatchList file historygetSet media tagsputMove a filepostList file referencesgetList similar filesgetReindex a repositorypostAdd media tags to filespostChange file statusespostSearch files by namegetList the trashgetRestore a filepostList media filesgetList formatsget
    Uploads
    Stock photos
    Downloads
    File versions
    File analysis
    Media analysis schemas
    Faces
    Albums
    People
    Media tags
    Share links
    Publications
    Distribution control
AI
Documents
Knowledge
Creative
Website & content
Automation
Customer channels
Administration
Schemas
GenuineAI API
GenuineAI API

Files

Everything stored in the workspace: what it is, where it sits, and how it is found. Bytes move through signed URLs, never through the API.


List files

GET
https://api.genuineai.app/api/v1
/files

Returns files in one repository. repo_type selects which — media for the shared media library, or the kind of object that owns them (ds, thread, design, prompt) together with a repo_id naming it. A repository is required: files are always scoped to one rather than listed across the workspace.

Each repository also has its own collection, which is the more direct way to ask — GET /knowledge-bases/{id}/files, GET /threads/{id}/files, GET /designs/{id}/files — and GET /media-files lists the media library with album membership and similarity search.

Requires any one of media:view, document:view, knowledge-base:view, thread:view, design:view, prompt:view or presentation:view.

List files › query Parameters

cursor
​string · maxLength: 512 · pattern: ^[A-Za-z0-9_-]+$
file_added_by
​string · uuid
file_created
​array
file_hash
​string
file_id
​string · uuid
file_name
​string
file_provider_id
​string
​object · style: deepObject · explode: true
file_status
​string
file_type
​string
file_updated
​array
limit
​integer
offset
​integer · min: 0
repo_id
​string · uuid
repo_type
​string · enum
Enum values:
media
generated
docs
ds
thread
design
prompt
ppt
sort
​string · minLength: 1 · maxLength: 64 · pattern: ^-?[a-z0-9_]+$

List files › Headers

X-Tenant-Id
​string · uuid · required

The workspace this request acts in. Every row the API returns is isolated to it at the database layer by row-level security.

List files › Responses

Success

​File[] · required
has_more
​boolean · required

Whether more rows exist past this page.

next_cursor
​string | null · required

Pass back as cursor for the next page. Null on the last page.

GET/files
curl https://api.genuineai.app/api/v1/files \ --header 'X-Tenant-Id: <string>' \ --header 'X-Api-Key: <api-key>'
Example Responses
{ "data": [ { "file_repo": { "library": [ "media" ], "ds": "00000000-0000-0000-0000-000000000000", "thread": "00000000-0000-0000-0000-000000000000", "design": "00000000-0000-0000-0000-000000000000", "prompt": "00000000-0000-0000-0000-000000000000", "ppt": "00000000-0000-0000-0000-000000000000", "ppt_template": "00000000-0000-0000-0000-000000000000", "form": "00000000-0000-0000-0000-000000000000", "submission": "00000000-0000-0000-0000-000000000000", "field": "field", "infographic": "00000000-0000-0000-0000-000000000000", "sitemap": "00000000-0000-0000-0000-000000000000", "node": "00000000-0000-0000-0000-000000000000", "wf_instance": "00000000-0000-0000-0000-000000000000", "wf_name": "wf_name" }, "file_id": "00000000-0000-0000-0000-000000000000", "file_name": "file_name", "file_type": "file_type", "file_size": 0, "file_created": "2024-08-25T15:00:00Z", "file_updated": "2024-08-25T15:00:00Z", "file_metadata": {}, "file_provider_id": "00000000-0000-0000-0000-000000000000", "file_bucket": "file_bucket", "file_folder": "file_folder", "file_hash": "file_hash", "file_status": "file_status", "file_added_by": "file_added_by", "file_replicas": "file_replicas", "file_summary": "file_summary", "file_pref": {} } ], "has_more": true, "next_cursor": "next_cursor" }
json
application/json

Create an empty document

POST
https://api.genuineai.app/api/v1
/files

Creates a markdown document to write into. For uploading bytes, start with upload URLs instead.

Requires any one of media:upload, document:upload, knowledge-base:upload, thread:upload, design:edit, prompt:edit or presentation:edit.

Create an empty document › Headers

X-Tenant-Id
​string · uuid · required

The workspace this request acts in. Every row the API returns is isolated to it at the database layer by row-level security.

Create an empty document › Request Body

file_repo
​object · required
file_name
​string · required

Create an empty document › Responses

Created

Anything stored in the workspace: what it is, where its bytes sit, and what is known about it.
File
​FileRepo

What the file belongs to. One key naming the owning object, or library for a library it sits in rather than an object it belongs to. Keys the platform stamps (presentation jobs, form submissions, workflow runs) are returned but cannot be sent.

file_id
​string · uuid
file_name
​string
file_type
​string
file_size
​integer
file_created
​string · date-time
file_updated
​string · date-time
file_metadata
​object
file_provider_id
​string · uuid
file_bucket
​string
file_folder
​string
file_hash
​string
file_status
​string
file_added_by
​string
file_replicas
​string
file_summary
​string
file_pref
​object
POST/files
curl https://api.genuineai.app/api/v1/files \ --request POST \ --header 'Content-Type: application/json' \ --header 'X-Tenant-Id: <string>' \ --header 'X-Api-Key: <api-key>' \ --data '{ "file_repo": {}, "file_name": "file_name" }'
Example Request Body
{ "file_repo": {}, "file_name": "file_name" }
json
Example Responses
{ "file_repo": { "library": [ "media" ], "ds": "00000000-0000-0000-0000-000000000000", "thread": "00000000-0000-0000-0000-000000000000", "design": "00000000-0000-0000-0000-000000000000", "prompt": "00000000-0000-0000-0000-000000000000", "ppt": "00000000-0000-0000-0000-000000000000", "ppt_template": "00000000-0000-0000-0000-000000000000", "form": "00000000-0000-0000-0000-000000000000", "submission": "00000000-0000-0000-0000-000000000000", "field": "field", "infographic": "00000000-0000-0000-0000-000000000000", "sitemap": "00000000-0000-0000-0000-000000000000", "node": "00000000-0000-0000-0000-000000000000", "wf_instance": "00000000-0000-0000-0000-000000000000", "wf_name": "wf_name" }, "file_id": "00000000-0000-0000-0000-000000000000", "file_name": "file_name", "file_type": "file_type", "file_size": 0, "file_created": "2024-08-25T15:00:00Z", "file_updated": "2024-08-25T15:00:00Z", "file_metadata": {}, "file_provider_id": "00000000-0000-0000-0000-000000000000", "file_bucket": "file_bucket", "file_folder": "file_folder", "file_hash": "file_hash", "file_status": "file_status", "file_added_by": "file_added_by", "file_replicas": "file_replicas", "file_summary": "file_summary", "file_pref": {} }
json
application/json

Get a file

GET
https://api.genuineai.app/api/v1
/files/{id}

Returns one file's record — what it is, where it sits and what is known about it. The bytes are reached through a download URL.

Requires any one of media:view, document:view, knowledge-base:view, thread:view, design:view, prompt:view or presentation:view.

Get a file › path Parameters

id
​string · uuid · required

Get a file › Headers

X-Tenant-Id
​string · uuid · required

The workspace this request acts in. Every row the API returns is isolated to it at the database layer by row-level security.

Get a file › Responses

Success

Anything stored in the workspace: what it is, where its bytes sit, and what is known about it.
File
​FileRepo

What the file belongs to. One key naming the owning object, or library for a library it sits in rather than an object it belongs to. Keys the platform stamps (presentation jobs, form submissions, workflow runs) are returned but cannot be sent.

file_id
​string · uuid
file_name
​string
file_type
​string
file_size
​integer
file_created
​string · date-time
file_updated
​string · date-time
file_metadata
​object
file_provider_id
​string · uuid
file_bucket
​string
file_folder
​string
file_hash
​string
file_status
​string
file_added_by
​string
file_replicas
​string
file_summary
​string
file_pref
​object
GET/files/{id}
curl https://api.genuineai.app/api/v1/files/:id \ --header 'X-Tenant-Id: <string>' \ --header 'X-Api-Key: <api-key>'
Example Responses
{ "file_repo": { "library": [ "media" ], "ds": "00000000-0000-0000-0000-000000000000", "thread": "00000000-0000-0000-0000-000000000000", "design": "00000000-0000-0000-0000-000000000000", "prompt": "00000000-0000-0000-0000-000000000000", "ppt": "00000000-0000-0000-0000-000000000000", "ppt_template": "00000000-0000-0000-0000-000000000000", "form": "00000000-0000-0000-0000-000000000000", "submission": "00000000-0000-0000-0000-000000000000", "field": "field", "infographic": "00000000-0000-0000-0000-000000000000", "sitemap": "00000000-0000-0000-0000-000000000000", "node": "00000000-0000-0000-0000-000000000000", "wf_instance": "00000000-0000-0000-0000-000000000000", "wf_name": "wf_name" }, "file_id": "00000000-0000-0000-0000-000000000000", "file_name": "file_name", "file_type": "file_type", "file_size": 0, "file_created": "2024-08-25T15:00:00Z", "file_updated": "2024-08-25T15:00:00Z", "file_metadata": {}, "file_provider_id": "00000000-0000-0000-0000-000000000000", "file_bucket": "file_bucket", "file_folder": "file_folder", "file_hash": "file_hash", "file_status": "file_status", "file_added_by": "file_added_by", "file_replicas": "file_replicas", "file_summary": "file_summary", "file_pref": {} }
json
application/json

Update a file

PUT
https://api.genuineai.app/api/v1
/files/{id}

Replaces the file's record. This is a PUT: it is the metadata that is being written, never the bytes. Which repository the file belongs to is not editable here — moving it is its own operation, because where a file sits decides who can reach it.

Requires any one of media:edit, document:edit, knowledge-base:write, thread:edit, design:edit, prompt:edit, presentation:edit or task:form:edit.

Update a file › path Parameters

id
​string · uuid · required

Update a file › Headers

X-Tenant-Id
​string · uuid · required

The workspace this request acts in. Every row the API returns is isolated to it at the database layer by row-level security.

Update a file › Responses

Success

Anything stored in the workspace: what it is, where its bytes sit, and what is known about it.
File
​FileRepo

What the file belongs to. One key naming the owning object, or library for a library it sits in rather than an object it belongs to. Keys the platform stamps (presentation jobs, form submissions, workflow runs) are returned but cannot be sent.

file_id
​string · uuid
file_name
​string
file_type
​string
file_size
​integer
file_created
​string · date-time
file_updated
​string · date-time
file_metadata
​object
file_provider_id
​string · uuid
file_bucket
​string
file_folder
​string
file_hash
​string
file_status
​string
file_added_by
​string
file_replicas
​string
file_summary
​string
file_pref
​object
PUT/files/{id}
curl https://api.genuineai.app/api/v1/files/:id \ --request PUT \ --header 'X-Tenant-Id: <string>' \ --header 'X-Api-Key: <api-key>'
Example Responses
{ "file_repo": { "library": [ "media" ], "ds": "00000000-0000-0000-0000-000000000000", "thread": "00000000-0000-0000-0000-000000000000", "design": "00000000-0000-0000-0000-000000000000", "prompt": "00000000-0000-0000-0000-000000000000", "ppt": "00000000-0000-0000-0000-000000000000", "ppt_template": "00000000-0000-0000-0000-000000000000", "form": "00000000-0000-0000-0000-000000000000", "submission": "00000000-0000-0000-0000-000000000000", "field": "field", "infographic": "00000000-0000-0000-0000-000000000000", "sitemap": "00000000-0000-0000-0000-000000000000", "node": "00000000-0000-0000-0000-000000000000", "wf_instance": "00000000-0000-0000-0000-000000000000", "wf_name": "wf_name" }, "file_id": "00000000-0000-0000-0000-000000000000", "file_name": "file_name", "file_type": "file_type", "file_size": 0, "file_created": "2024-08-25T15:00:00Z", "file_updated": "2024-08-25T15:00:00Z", "file_metadata": {}, "file_provider_id": "00000000-0000-0000-0000-000000000000", "file_bucket": "file_bucket", "file_folder": "file_folder", "file_hash": "file_hash", "file_status": "file_status", "file_added_by": "file_added_by", "file_replicas": "file_replicas", "file_summary": "file_summary", "file_pref": {} }
json
application/json

Delete a file

DELETE
https://api.genuineai.app/api/v1
/files/{id}

Recoverable from the trash while its storage objects are still within the retention window.

Requires any one of media:delete, document:delete, knowledge-base:delete, thread:edit, design:edit, prompt:edit, presentation:edit or task:form:edit.

Delete a file › path Parameters

id
​string · uuid · required

Delete a file › Headers

X-Tenant-Id
​string · uuid · required

The workspace this request acts in. Every row the API returns is isolated to it at the database layer by row-level security.

Delete a file › Responses

Success. No content.

No data returned
DELETE/files/{id}
curl https://api.genuineai.app/api/v1/files/:id \ --request DELETE \ --header 'X-Tenant-Id: <string>' \ --header 'X-Api-Key: <api-key>'
Example Responses
No example specified for this content type

Copy to the library

POST
https://api.genuineai.app/api/v1
/files/{id}/copy-to-media

Copies a file into the media library, where albums, faces and tags apply to it. The original stays where it was.

Requires any one of media:download, document:download, knowledge-base:view, thread:view, design:view, prompt:view, presentation:view or media:upload.

Copy to the library › path Parameters

id
​string · uuid · required

Copy to the library › Headers

X-Tenant-Id
​string · uuid · required

The workspace this request acts in. Every row the API returns is isolated to it at the database layer by row-level security.

Copy to the library › Responses

Success

No data returned
POST/files/{id}/copy-to-media
curl https://api.genuineai.app/api/v1/files/:id/copy-to-media \ --request POST \ --header 'X-Tenant-Id: <string>' \ --header 'X-Api-Key: <api-key>'
Example Responses
No example specified for this content type

Favorite or unfavorite

PATCH
https://api.genuineai.app/api/v1
/files/{id}/favorite

Flips the caller's own favorite flag on the file. Favorites are per user, not per workspace.

Requires any one of media:view, document:view, knowledge-base:view, thread:view, design:view, prompt:view or presentation:view.

Favorite or unfavorite › path Parameters

id
​string · uuid · required

Favorite or unfavorite › Headers

X-Tenant-Id
​string · uuid · required

The workspace this request acts in. Every row the API returns is isolated to it at the database layer by row-level security.

Favorite or unfavorite › Request Body optional

favorite
​boolean

Favorite or unfavorite › Responses

Success

favorite
​boolean

The state the file is now in.

PATCH/files/{id}/favorite
curl https://api.genuineai.app/api/v1/files/:id/favorite \ --request PATCH \ --header 'Content-Type: application/json' \ --header 'X-Tenant-Id: <string>' \ --header 'X-Api-Key: <api-key>' \ --data '{ "favorite": true }'
Example Request Body
{ "favorite": true }
json
Example Responses
{ "favorite": true }
json
application/json

List file history

GET
https://api.genuineai.app/api/v1
/files/{id}/history

Completed analysis runs, tag edits, renames and deletions, newest first, reduced to the facts that changed — the full analysis records behind them are not returned here.

List file history › path Parameters

id
​string · uuid · required

List file history › Headers

X-Tenant-Id
​string · uuid · required

The workspace this request acts in. Every row the API returns is isolated to it at the database layer by row-level security.

List file history › Responses

Success

No data returned
GET/files/{id}/history
curl https://api.genuineai.app/api/v1/files/:id/history \ --header 'X-Tenant-Id: <string>' \ --header 'X-Api-Key: <api-key>'
Example Responses
No example specified for this content type

Set media tags

PUT
https://api.genuineai.app/api/v1
/files/{id}/media-tags

Replaces the file's tags with what you send.

Requires any one of media:edit, document:edit, knowledge-base:write, thread:edit, design:edit, prompt:edit, presentation:edit or task:form:edit.

Set media tags › path Parameters

id
​string · uuid · required

Set media tags › Headers

X-Tenant-Id
​string · uuid · required

The workspace this request acts in. Every row the API returns is isolated to it at the database layer by row-level security.

Set media tags › Request Body

mediaTags
​object · required

Set media tags › Responses

Success

No data returned
PUT/files/{id}/media-tags
curl https://api.genuineai.app/api/v1/files/:id/media-tags \ --request PUT \ --header 'Content-Type: application/json' \ --header 'X-Tenant-Id: <string>' \ --header 'X-Api-Key: <api-key>' \ --data '{ "mediaTags": {} }'
Example Request Body
{ "mediaTags": {} }
json
Example Responses
No example specified for this content type

Move a file

POST
https://api.genuineai.app/api/v1
/files/{id}/move

Files the file under a different repository. Everything the move touches is checked: write access to the file, write access to where it is going, and write access to what it is leaving — taking a document out of a knowledge base changes that knowledge base.

Retrieval follows the move: chunks indexed for the old repository answer for the new one from then on. A file that was never indexed does not become searchable by moving it into a knowledge base — reindex it explicitly.

Only repositories a caller may name are accepted — library, ds, thread, design and prompt. The rest are stamped by the platform to record how a file came to exist, and are returned but never sent.

Requires any one of media:edit, document:edit, knowledge-base:write, thread:edit, design:edit, prompt:edit, presentation:edit or task:form:edit.

Move a file › path Parameters

id
​string · uuid · required

Move a file › Headers

X-Tenant-Id
​string · uuid · required

The workspace this request acts in. Every row the API returns is isolated to it at the database layer by row-level security.

Move a file › Request Body

file_repo
​object · required

Move a file › Responses

Success

Anything stored in the workspace: what it is, where its bytes sit, and what is known about it.
File
​FileRepo

What the file belongs to. One key naming the owning object, or library for a library it sits in rather than an object it belongs to. Keys the platform stamps (presentation jobs, form submissions, workflow runs) are returned but cannot be sent.

file_id
​string · uuid
file_name
​string
file_type
​string
file_size
​integer
file_created
​string · date-time
file_updated
​string · date-time
file_metadata
​object
file_provider_id
​string · uuid
file_bucket
​string
file_folder
​string
file_hash
​string
file_status
​string
file_added_by
​string
file_replicas
​string
file_summary
​string
file_pref
​object
POST/files/{id}/move
curl https://api.genuineai.app/api/v1/files/:id/move \ --request POST \ --header 'Content-Type: application/json' \ --header 'X-Tenant-Id: <string>' \ --header 'X-Api-Key: <api-key>' \ --data '{ "file_repo": {} }'
Example Request Body
{ "file_repo": {} }
json
Example Responses
{ "file_repo": { "library": [ "media" ], "ds": "00000000-0000-0000-0000-000000000000", "thread": "00000000-0000-0000-0000-000000000000", "design": "00000000-0000-0000-0000-000000000000", "prompt": "00000000-0000-0000-0000-000000000000", "ppt": "00000000-0000-0000-0000-000000000000", "ppt_template": "00000000-0000-0000-0000-000000000000", "form": "00000000-0000-0000-0000-000000000000", "submission": "00000000-0000-0000-0000-000000000000", "field": "field", "infographic": "00000000-0000-0000-0000-000000000000", "sitemap": "00000000-0000-0000-0000-000000000000", "node": "00000000-0000-0000-0000-000000000000", "wf_instance": "00000000-0000-0000-0000-000000000000", "wf_name": "wf_name" }, "file_id": "00000000-0000-0000-0000-000000000000", "file_name": "file_name", "file_type": "file_type", "file_size": 0, "file_created": "2024-08-25T15:00:00Z", "file_updated": "2024-08-25T15:00:00Z", "file_metadata": {}, "file_provider_id": "00000000-0000-0000-0000-000000000000", "file_bucket": "file_bucket", "file_folder": "file_folder", "file_hash": "file_hash", "file_status": "file_status", "file_added_by": "file_added_by", "file_replicas": "file_replicas", "file_summary": "file_summary", "file_pref": {} }
json
application/json

List file references

GET
https://api.genuineai.app/api/v1
/files/{id}/references

Everything holding on to this file — the albums containing it, designs using it in a layer or as a background, social posts that published it, share links exposing it, and the business objects it is attached to. This is what to check before deleting one.

Sections the caller may not see come back empty rather than being refused.

List file references › path Parameters

id
​string · uuid · required

List file references › Headers

X-Tenant-Id
​string · uuid · required

The workspace this request acts in. Every row the API returns is isolated to it at the database layer by row-level security.

List file references › Responses

Success

No data returned
GET/files/{id}/references
curl https://api.genuineai.app/api/v1/files/:id/references \ --header 'X-Tenant-Id: <string>' \ --header 'X-Api-Key: <api-key>'
Example Responses
No example specified for this content type

List similar files

GET
https://api.genuineai.app/api/v1
/files/{id}/similar

Compares stored embeddings. Returns an empty list when the file has no embedding yet — analysis still pending, or a generated image, which never gets one.

List similar files › path Parameters

id
​string · uuid · required

List similar files › query Parameters

limit
​integer · min: 1 · max: 24

List similar files › Headers

X-Tenant-Id
​string · uuid · required

The workspace this request acts in. Every row the API returns is isolated to it at the database layer by row-level security.

List similar files › Responses

Success

​File[]
Anything stored in the workspace: what it is, where its bytes sit, and what is known about it.
File
​FileRepo

What the file belongs to. One key naming the owning object, or library for a library it sits in rather than an object it belongs to. Keys the platform stamps (presentation jobs, form submissions, workflow runs) are returned but cannot be sent.

file_id
​string · uuid
file_name
​string
file_type
​string
file_size
​integer
file_created
​string · date-time
file_updated
​string · date-time
file_metadata
​object
file_provider_id
​string · uuid
file_bucket
​string
file_folder
​string
file_hash
​string
file_status
​string
file_added_by
​string
file_replicas
​string
file_summary
​string
file_pref
​object
GET/files/{id}/similar
curl https://api.genuineai.app/api/v1/files/:id/similar \ --header 'X-Tenant-Id: <string>' \ --header 'X-Api-Key: <api-key>'
Example Responses
[ { "file_repo": { "library": [ "media" ], "ds": "00000000-0000-0000-0000-000000000000", "thread": "00000000-0000-0000-0000-000000000000", "design": "00000000-0000-0000-0000-000000000000", "prompt": "00000000-0000-0000-0000-000000000000", "ppt": "00000000-0000-0000-0000-000000000000", "ppt_template": "00000000-0000-0000-0000-000000000000", "form": "00000000-0000-0000-0000-000000000000", "submission": "00000000-0000-0000-0000-000000000000", "field": "field", "infographic": "00000000-0000-0000-0000-000000000000", "sitemap": "00000000-0000-0000-0000-000000000000", "node": "00000000-0000-0000-0000-000000000000", "wf_instance": "00000000-0000-0000-0000-000000000000", "wf_name": "wf_name" }, "file_id": "00000000-0000-0000-0000-000000000000", "file_name": "file_name", "file_type": "file_type", "file_size": 0, "file_created": "2024-08-25T15:00:00Z", "file_updated": "2024-08-25T15:00:00Z", "file_metadata": {}, "file_provider_id": "00000000-0000-0000-0000-000000000000", "file_bucket": "file_bucket", "file_folder": "file_folder", "file_hash": "file_hash", "file_status": "file_status", "file_added_by": "file_added_by", "file_replicas": "file_replicas", "file_summary": "file_summary", "file_pref": {} } ]
json
application/json

Reindex a repository

POST
https://api.genuineai.app/api/v1
/files/actions/reindex

Rebuilds the search and retrieval index for a repository. It answers when the reindex is done, and refuses a repository holding more than 99 files rather than running long — the count of what was processed, skipped and what failed comes back in the response.

Reindex a repository › Headers

X-Tenant-Id
​string · uuid · required

The workspace this request acts in. Every row the API returns is isolated to it at the database layer by row-level security.

Reindex a repository › Request Body

repo_type
​string · enum · required
Enum values:
media
generated
docs
ds
thread
design
prompt
ppt
repo_id
​string · uuid

Reindex a repository › Responses

Success

No data returned
POST/files/actions/reindex
curl https://api.genuineai.app/api/v1/files/actions/reindex \ --request POST \ --header 'Content-Type: application/json' \ --header 'X-Tenant-Id: <string>' \ --header 'X-Api-Key: <api-key>' \ --data '{ "repo_type": "media", "repo_id": "00000000-0000-0000-0000-000000000000" }'
Example Request Body
{ "repo_type": "media", "repo_id": "00000000-0000-0000-0000-000000000000" }
json
Example Responses
No example specified for this content type

Add media tags to files

POST
https://api.genuineai.app/api/v1
/files/actions/set-media-tags

Adds to what is already there, rather than replacing it.

Add media tags to files › Headers

X-Tenant-Id
​string · uuid · required

The workspace this request acts in. Every row the API returns is isolated to it at the database layer by row-level security.

Add media tags to files › Request Body

file_ids
​string[] · required
mediaTags
​object · required
remove
​boolean

Add media tags to files › Responses

Success

No data returned
POST/files/actions/set-media-tags
curl https://api.genuineai.app/api/v1/files/actions/set-media-tags \ --request POST \ --header 'Content-Type: application/json' \ --header 'X-Tenant-Id: <string>' \ --header 'X-Api-Key: <api-key>' \ --data '{ "file_ids": [ "00000000-0000-0000-0000-000000000000" ], "mediaTags": {}, "remove": true }'
Example Request Body
{ "file_ids": [ "00000000-0000-0000-0000-000000000000" ], "mediaTags": {}, "remove": true }
json
Example Responses
No example specified for this content type

Change file statuses

POST
https://api.genuineai.app/api/v1
/files/actions/transition

Moves files to another status in the flow that governs them. A move the flow does not allow is refused rather than forced.

Change file statuses › Headers

X-Tenant-Id
​string · uuid · required

The workspace this request acts in. Every row the API returns is isolated to it at the database layer by row-level security.

Change file statuses › Request Body

file_ids
​string[] · required
target_state_id
​string · uuid · required

Change file statuses › Responses

Success

No data returned
POST/files/actions/transition
curl https://api.genuineai.app/api/v1/files/actions/transition \ --request POST \ --header 'Content-Type: application/json' \ --header 'X-Tenant-Id: <string>' \ --header 'X-Api-Key: <api-key>' \ --data '{ "file_ids": [ "00000000-0000-0000-0000-000000000000" ], "target_state_id": "00000000-0000-0000-0000-000000000000" }'
Example Request Body
{ "file_ids": [ "00000000-0000-0000-0000-000000000000" ], "target_state_id": "00000000-0000-0000-0000-000000000000" }
json
Example Responses
No example specified for this content type

Search files by name

GET
https://api.genuineai.app/api/v1
/files/search

Name matching for pickers and mentions, limited to files whose text has been extracted — a file with no rendition would add nothing to the message that mentions it. Two sources answer, each behind its own grant and labelled by source: the documents a knowledge base indexes, and the document library. An empty query answers with the most recently added.

Requires any one of media:view, document:view, knowledge-base:view, thread:view, design:view, prompt:view or presentation:view.

Search files by name › query Parameters

limit
​integer · min: 1 · max: 25
q
​string

Search files by name › Headers

X-Tenant-Id
​string · uuid · required

The workspace this request acts in. Every row the API returns is isolated to it at the database layer by row-level security.

Search files by name › Responses

Success

​File[]
Anything stored in the workspace: what it is, where its bytes sit, and what is known about it.
File
​FileRepo

What the file belongs to. One key naming the owning object, or library for a library it sits in rather than an object it belongs to. Keys the platform stamps (presentation jobs, form submissions, workflow runs) are returned but cannot be sent.

file_id
​string · uuid
file_name
​string
file_type
​string
file_size
​integer
file_created
​string · date-time
file_updated
​string · date-time
file_metadata
​object
file_provider_id
​string · uuid
file_bucket
​string
file_folder
​string
file_hash
​string
file_status
​string
file_added_by
​string
file_replicas
​string
file_summary
​string
file_pref
​object
GET/files/search
curl https://api.genuineai.app/api/v1/files/search \ --header 'X-Tenant-Id: <string>' \ --header 'X-Api-Key: <api-key>'
Example Responses
[ { "file_repo": { "library": [ "media" ], "ds": "00000000-0000-0000-0000-000000000000", "thread": "00000000-0000-0000-0000-000000000000", "design": "00000000-0000-0000-0000-000000000000", "prompt": "00000000-0000-0000-0000-000000000000", "ppt": "00000000-0000-0000-0000-000000000000", "ppt_template": "00000000-0000-0000-0000-000000000000", "form": "00000000-0000-0000-0000-000000000000", "submission": "00000000-0000-0000-0000-000000000000", "field": "field", "infographic": "00000000-0000-0000-0000-000000000000", "sitemap": "00000000-0000-0000-0000-000000000000", "node": "00000000-0000-0000-0000-000000000000", "wf_instance": "00000000-0000-0000-0000-000000000000", "wf_name": "wf_name" }, "file_id": "00000000-0000-0000-0000-000000000000", "file_name": "file_name", "file_type": "file_type", "file_size": 0, "file_created": "2024-08-25T15:00:00Z", "file_updated": "2024-08-25T15:00:00Z", "file_metadata": {}, "file_provider_id": "00000000-0000-0000-0000-000000000000", "file_bucket": "file_bucket", "file_folder": "file_folder", "file_hash": "file_hash", "file_status": "file_status", "file_added_by": "file_added_by", "file_replicas": "file_replicas", "file_summary": "file_summary", "file_pref": {} } ]
json
application/json

List the trash

GET
https://api.genuineai.app/api/v1
/files/trash

Each entry says whether it is still recoverable — the underlying storage objects are kept for a retention window, and once that passes the file is gone for good.

List the trash › Headers

X-Tenant-Id
​string · uuid · required

The workspace this request acts in. Every row the API returns is isolated to it at the database layer by row-level security.

List the trash › Responses

Success

​File[]
Anything stored in the workspace: what it is, where its bytes sit, and what is known about it.
File
​FileRepo

What the file belongs to. One key naming the owning object, or library for a library it sits in rather than an object it belongs to. Keys the platform stamps (presentation jobs, form submissions, workflow runs) are returned but cannot be sent.

file_id
​string · uuid
file_name
​string
file_type
​string
file_size
​integer
file_created
​string · date-time
file_updated
​string · date-time
file_metadata
​object
file_provider_id
​string · uuid
file_bucket
​string
file_folder
​string
file_hash
​string
file_status
​string
file_added_by
​string
file_replicas
​string
file_summary
​string
file_pref
​object
GET/files/trash
curl https://api.genuineai.app/api/v1/files/trash \ --header 'X-Tenant-Id: <string>' \ --header 'X-Api-Key: <api-key>'
Example Responses
[ { "file_repo": { "library": [ "media" ], "ds": "00000000-0000-0000-0000-000000000000", "thread": "00000000-0000-0000-0000-000000000000", "design": "00000000-0000-0000-0000-000000000000", "prompt": "00000000-0000-0000-0000-000000000000", "ppt": "00000000-0000-0000-0000-000000000000", "ppt_template": "00000000-0000-0000-0000-000000000000", "form": "00000000-0000-0000-0000-000000000000", "submission": "00000000-0000-0000-0000-000000000000", "field": "field", "infographic": "00000000-0000-0000-0000-000000000000", "sitemap": "00000000-0000-0000-0000-000000000000", "node": "00000000-0000-0000-0000-000000000000", "wf_instance": "00000000-0000-0000-0000-000000000000", "wf_name": "wf_name" }, "file_id": "00000000-0000-0000-0000-000000000000", "file_name": "file_name", "file_type": "file_type", "file_size": 0, "file_created": "2024-08-25T15:00:00Z", "file_updated": "2024-08-25T15:00:00Z", "file_metadata": {}, "file_provider_id": "00000000-0000-0000-0000-000000000000", "file_bucket": "file_bucket", "file_folder": "file_folder", "file_hash": "file_hash", "file_status": "file_status", "file_added_by": "file_added_by", "file_replicas": "file_replicas", "file_summary": "file_summary", "file_pref": {} } ]
json
application/json

Restore a file

POST
https://api.genuineai.app/api/v1
/files/trash/{id}/recover

Restores the file and its thumbnails. Answers 409 if the storage objects are past their retention window — at that point there is nothing left to restore.

Restore a file › path Parameters

id
​string · uuid · required

Restore a file › Headers

X-Tenant-Id
​string · uuid · required

The workspace this request acts in. Every row the API returns is isolated to it at the database layer by row-level security.

Restore a file › Responses

Success

No data returned
POST/files/trash/{id}/recover
curl https://api.genuineai.app/api/v1/files/trash/:id/recover \ --request POST \ --header 'X-Tenant-Id: <string>' \ --header 'X-Api-Key: <api-key>'
Example Responses
No example specified for this content type

List media files

GET
https://api.genuineai.app/api/v1
/media-files

Returns files with the albums each belongs to. An embedding in the request adds a similarity score and orders by it; a face embedding does the same through face_similarity. GET /files is the plainer listing — this one is the library's own, and it is the only place the similarity searches are offered.

repo_type is required, as it is on GET /files: media for the uploaded library, generated for what the platform produced on its own. An image generated inside a conversation belongs to that conversation instead — list those with repo_type=thread.

fileType cuts the list by kind — Image, Video, Audio or Document — and file_format by the file name's extension, mov or mp4, with or without the leading dot. Both repeat to widen the selection rather than narrow it, and GET /media-files/formats answers which values are worth sending for a given repository. file_added_by keeps only files the named users uploaded, by user id, and repeats the same way.

analyzed=false keeps the files AI analysis never produced output for — deferred while credits were exhausted, failed, or uploaded before analysis existed — the set worth re-running; analyzed=true is its complement.

Requires either media:view or infographic:view.

List media files › query Parameters

aiGenerated
​boolean
analyzed
​boolean
contentType
​string · enum
Enum values:
image
infographic
embedding_search
​string
face_embedding
​string
face_person
​string · uuid
face_threshold
​number · min: 0 · max: 1
favorite
​boolean
file_added_by
​string
file_format
​string
fileType
​string
has_faces
​boolean
limit
​string · pattern: ^-?[0-9]+(\.[0-9]+)?…
offset
​string · pattern: ^-?[0-9]+(\.[0-9]+)?…
repo_id
​string · uuid
repo_type
​string · enum
Enum values:
media
generated
docs
ds
thread
design
prompt
ppt
search
​string · maxLength: 200
similarityThreshold
​number · min: 0 · max: 1

List media files › Headers

X-Tenant-Id
​string · uuid · required

The workspace this request acts in. Every row the API returns is isolated to it at the database layer by row-level security.

List media files › Responses

Success

​MediaFile[] · required
has_more
​boolean · required

Whether more rows exist past this page.

next_cursor
​string | null · required

Pass back as cursor for the next page. Null on the last page.

GET/media-files
curl https://api.genuineai.app/api/v1/media-files \ --header 'X-Tenant-Id: <string>' \ --header 'X-Api-Key: <api-key>'
Example Responses
{ "data": [ { "file_repo": { "library": [ "media" ], "ds": "00000000-0000-0000-0000-000000000000", "thread": "00000000-0000-0000-0000-000000000000", "design": "00000000-0000-0000-0000-000000000000", "prompt": "00000000-0000-0000-0000-000000000000", "ppt": "00000000-0000-0000-0000-000000000000", "ppt_template": "00000000-0000-0000-0000-000000000000", "form": "00000000-0000-0000-0000-000000000000", "submission": "00000000-0000-0000-0000-000000000000", "field": "field", "infographic": "00000000-0000-0000-0000-000000000000", "sitemap": "00000000-0000-0000-0000-000000000000", "node": "00000000-0000-0000-0000-000000000000", "wf_instance": "00000000-0000-0000-0000-000000000000", "wf_name": "wf_name" }, "file_id": "00000000-0000-0000-0000-000000000000", "file_name": "file_name", "file_type": "file_type", "file_size": 0, "file_created": "2024-08-25T15:00:00Z", "file_updated": "2024-08-25T15:00:00Z", "file_added_by": "file_added_by", "file_hash": "file_hash", "file_metadata": {}, "file_replicas": "file_replicas", "file_status": "file_status", "file_bucket": "file_bucket", "file_folder": "file_folder", "file_provider_id": "00000000-0000-0000-0000-000000000000", "file_state_item": "file_state_item", "file_pref": {}, "file_albums": [ {} ], "similarity": 0, "face_similarity": 0 } ], "has_more": true, "next_cursor": "next_cursor" }
json
application/json

List formats

GET
https://api.genuineai.app/api/v1
/media-files/formats

The kinds and formats of file actually present in the repository the request names, each with how many files carry it. This is the option list behind the media library's type filter — it is what lets that filter offer mov and mp4 as separate choices without offering formats the account holds none of.

A row is a filter: kind is what fileType takes on GET /media-files and format is what file_format takes, so a caller sends one straight back. The counts describe the repository, the album and the favorite flag and nothing else — the gallery's remaining filters and both similarity searches leave them alone, so a count says what is in here rather than what the current query matches. A file whose name carries no extension has no format and is counted under its kind alone.

Counting is exact, which means reading every file the caller can see. A library too large to do that inside the server's budget answers with all four kinds, a null count on each and no formats — the filter still works, it just stops saying how many. Treat a null count as "not counted" rather than zero.

Requires either media:view or infographic:view.

List formats › query Parameters

af_album
​string · uuid
favorite
​boolean
repo_id
​string · uuid
repo_type
​string · enum
Enum values:
media
generated
docs
ds
thread
design
prompt
ppt

List formats › Headers

X-Tenant-Id
​string · uuid · required

The workspace this request acts in. Every row the API returns is isolated to it at the database layer by row-level security.

List formats › Responses

Success

​object[] · required
​object[] · required

Ordered by count, most common first.

GET/media-files/formats
curl https://api.genuineai.app/api/v1/media-files/formats \ --header 'X-Tenant-Id: <string>' \ --header 'X-Api-Key: <api-key>'
Example Responses
{ "kinds": [ { "kind": "Image", "count": 0 } ], "formats": [ { "format": "format", "kind": "Image", "count": 0 } ] }
json
application/json

UsageUploads