Revyl Org Files API
The Org Files API from Revyl — 6 operation(s) for org files.
The Org Files API from Revyl — 6 operation(s) for org files.
Every API here is available over the APIs.io API and to AI agents over MCP.
One button, every client — Claude, Cursor, VS Code and the rest.
https://apis.io/mcp
find_apisBrowse and filter every API in the catalog.get_api_artifactsOne API's artifacts, grouped by type.get_openapiThe primary OpenAPI for this API.find_similar_apisAPIs that look like this one.apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.resolveTurn a domain, URL or GitHub org into the provider it belongs to.find_cohortsEvery scored population of providers in the catalog.curl "https://apis.io/api/v1/apis/revyl:revyl-org-files-api"
curl "https://apis.io/api/v1/apis?limit=25"
Calls without X-API-Key need no key. Calls with it need a paid plan — get a key.
Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. By signing up you are subscribing to the APIs.io and API Evangelist newsletters — you can unsubscribe from any issue. See our Privacy Policy and Terms.
A second provider on the same verified email joins the account you already have.
openapi: 3.2.0
info:
description: Revyl API
title: Revyl Org Files API
version: 1.0.0
servers:
- description: Production
url: https://backend.revyl.ai
tags:
- name: Org Files
paths:
/api/v1/files/:
get:
description: List all files for the authenticated user's org.
operationId: list_org_files_api_v1_files__get
parameters:
- in: query
name: limit
required: false
schema:
default: 100
maximum: 1000
minimum: 1
title: Limit
type: integer
- in: query
name: offset
required: false
schema:
default: 0
minimum: 0
title: Offset
type: integer
responses:
'200':
content:
application/json:
schema:
$ref: '#/components/schemas/OrgFileListResponse'
description: Successful Response
'422':
content:
application/json:
schema:
$ref: '#/components/schemas/HTTPValidationError'
description: Validation Error
security:
- HTTPBearer: []
summary: List Org Files
tags:
- Org Files
/api/v1/files/upload-url:
post:
description: 'Generate a presigned S3 upload URL and create the file record.
The client should PUT the file directly to the returned URL.'
operationId: get_upload_url_api_v1_files_upload_url_post
requestBody:
content:
application/json:
schema:
$ref: '#/components/schemas/OrgFileUploadRequest'
required: true
responses:
'201':
content:
application/json:
schema:
$ref: '#/components/schemas/OrgFileUploadResponse'
description: Successful Response
'422':
content:
application/json:
schema:
$ref: '#/components/schemas/HTTPValidationError'
description: Validation Error
security:
- HTTPBearer: []
summary: Get Upload Url
tags:
- Org Files
/api/v1/files/{file_id}:
delete:
description: Delete a file from S3 and the database (works on both pending and ready files).
operationId: delete_org_file_api_v1_files__file_id__delete
parameters:
- in: path
name: file_id
required: true
schema:
format: uuid
title: File Id
type: string
responses:
'204':
description: Successful Response
'422':
content:
application/json:
schema:
$ref: '#/components/schemas/HTTPValidationError'
description: Validation Error
security:
- HTTPBearer: []
summary: Delete Org File
tags:
- Org Files
put:
description: Update file name and/or description.
operationId: update_org_file_api_v1_files__file_id__put
parameters:
- in: path
name: file_id
required: true
schema:
format: uuid
title: File Id
type: string
requestBody:
content:
application/json:
schema:
$ref: '#/components/schemas/OrgFileUpdate'
required: true
responses:
'200':
content:
application/json:
schema:
$ref: '#/components/schemas/OrgFile'
description: Successful Response
'422':
content:
application/json:
schema:
$ref: '#/components/schemas/HTTPValidationError'
description: Validation Error
security:
- HTTPBearer: []
summary: Update Org File
tags:
- Org Files
/api/v1/files/{file_id}/complete-upload:
post:
description: 'Confirm that an S3 upload completed successfully.
For new uploads: flips status from ''pending'' to ''ready''.
For replacements: updates s3_key/filename/size and keeps status ''ready''.'
operationId: complete_upload_api_v1_files__file_id__complete_upload_post
parameters:
- in: path
name: file_id
required: true
schema:
format: uuid
title: File Id
type: string
requestBody:
content:
application/json:
schema:
$ref: '#/components/schemas/OrgFileCompleteUploadRequest'
required: true
responses:
'200':
content:
application/json:
schema:
$ref: '#/components/schemas/OrgFile'
description: Successful Response
'422':
content:
application/json:
schema:
$ref: '#/components/schemas/HTTPValidationError'
description: Validation Error
security:
- HTTPBearer: []
summary: Complete Upload
tags:
- Org Files
/api/v1/files/{file_id}/download-url:
get:
description: Generate a presigned download URL for an org file.
operationId: get_file_download_url_api_v1_files__file_id__download_url_get
parameters:
- in: path
name: file_id
required: true
schema:
format: uuid
title: File Id
type: string
responses:
'200':
content:
application/json:
schema:
$ref: '#/components/schemas/OrgFileDownloadUrlResponse'
description: Successful Response
'422':
content:
application/json:
schema:
$ref: '#/components/schemas/HTTPValidationError'
description: Validation Error
security:
- HTTPBearer: []
summary: Get File Download Url
tags:
- Org Files
/api/v1/files/{file_id}/replace-url:
put:
description: 'Generate a presigned URL to replace an existing file''s content.
Preserves the file ID so references (e.g. revyl-file://) remain valid.
The DB record is NOT modified here — it stays unchanged until the
client confirms the upload via POST /{file_id}/complete-upload.'
operationId: get_replace_url_api_v1_files__file_id__replace_url_put
parameters:
- in: path
name: file_id
required: true
schema:
format: uuid
title: File Id
type: string
requestBody:
content:
application/json:
schema:
$ref: '#/components/schemas/OrgFileUploadRequest'
required: true
responses:
'200':
content:
application/json:
schema:
$ref: '#/components/schemas/OrgFileUploadResponse'
description: Successful Response
'422':
content:
application/json:
schema:
$ref: '#/components/schemas/HTTPValidationError'
description: Validation Error
security:
- HTTPBearer: []
summary: Get Replace Url
tags:
- Org Files
components:
schemas:
OrgFileCompleteUploadRequest:
description: Request body for confirming a file upload completed successfully.
properties:
content_type:
anyOf:
- type: string
- type: 'null'
description: New content type (for replace flow)
title: Content Type
description:
anyOf:
- type: string
- type: 'null'
description: New description (for replace flow)
title: Description
file_size:
anyOf:
- minimum: 1.0
type: integer
- type: 'null'
description: New file size in bytes (for replace flow)
title: File Size
filename:
anyOf:
- type: string
- type: 'null'
description: New display name (for replace flow)
title: Filename
s3_key:
anyOf:
- type: string
- type: 'null'
description: New S3 key (required for replace flow)
title: S3 Key
title: OrgFileCompleteUploadRequest
type: object
OrgFileDownloadUrlResponse:
description: Response model for file download URL.
properties:
expires_in:
description: URL expiry in seconds
title: Expires In
type: integer
filename:
description: Original filename
title: Filename
type: string
url:
description: Presigned download URL
title: Url
type: string
required:
- url
- filename
- expires_in
title: OrgFileDownloadUrlResponse
type: object
OrgFile:
description: Full org file model with database fields.
properties:
content_type:
anyOf:
- type: string
- type: 'null'
description: MIME content type
title: Content Type
created_at:
description: Upload timestamp
format: date-time
title: Created At
type: string
description:
anyOf:
- type: string
- type: 'null'
description: File description
title: Description
file_size:
description: File size in bytes
title: File Size
type: integer
filename:
description: Display name
title: Filename
type: string
id:
description: File ID
format: uuid
title: Id
type: string
org_id:
description: Organization ID
format: uuid
title: Org Id
type: string
status:
default: ready
description: 'Upload status: ''pending'' or ''ready'''
title: Status
type: string
updated_at:
description: Last update timestamp
format: date-time
title: Updated At
type: string
user_id:
description: User ID who uploaded the file
format: uuid
title: User Id
type: string
required:
- id
- org_id
- user_id
- filename
- file_size
- created_at
- updated_at
title: OrgFile
type: object
HTTPValidationError:
properties:
detail:
items:
$ref: '#/components/schemas/ValidationError'
title: Detail
type: array
title: HTTPValidationError
type: object
OrgFileUpdate:
description: Model for updating an org file.
properties:
description:
anyOf:
- type: string
- type: 'null'
description: Description
title: Description
filename:
anyOf:
- type: string
- type: 'null'
description: Display name
title: Filename
title: OrgFileUpdate
type: object
OrgFileUploadResponse:
description: Response model for presigned upload URL.
properties:
content_type:
description: Content-Type to use in the PUT request
title: Content Type
type: string
expires_in:
description: URL expiry in seconds
title: Expires In
type: integer
file:
$ref: '#/components/schemas/OrgFile'
description: Created file record
s3_key:
anyOf:
- type: string
- type: 'null'
description: S3 object key (used by client in confirm step for replace flow)
title: S3 Key
upload_url:
description: Presigned S3 PUT URL
title: Upload Url
type: string
required:
- file
- upload_url
- expires_in
- content_type
title: OrgFileUploadResponse
type: object
OrgFileUploadRequest:
description: Request model for generating a presigned upload URL.
properties:
content_type:
anyOf:
- type: string
- type: 'null'
description: MIME content type
title: Content Type
description:
anyOf:
- type: string
- type: 'null'
description: File description
title: Description
display_name:
anyOf:
- type: string
- type: 'null'
description: Display name (defaults to filename)
title: Display Name
file_size:
description: File size in bytes (used for size validation)
minimum: 1.0
title: File Size
type: integer
filename:
description: Original filename (used for extension validation)
title: Filename
type: string
required:
- filename
- file_size
title: OrgFileUploadRequest
type: object
OrgFileListResponse:
description: Response model for listing org files.
properties:
count:
description: Total count of files
title: Count
type: integer
files:
description: List of files
items:
$ref: '#/components/schemas/OrgFile'
title: Files
type: array
required:
- files
- count
title: OrgFileListResponse
type: object
ValidationError:
properties:
ctx:
title: Context
type: object
input:
title: Input
loc:
items:
anyOf:
- type: string
- type: integer
title: Location
type: array
msg:
title: Message
type: string
type:
title: Error Type
type: string
required:
- loc
- msg
- type
title: ValidationError
type: object
securitySchemes:
HTTPBearer:
scheme: bearer
type: http