Skip to content

AssetUploadService

Chatto exposes this service below /api/connect.

Shared message and enum definitions are documented in Shared Types And Enums.

Creates room-scoped attachment assets through chunked ConnectRPC uploads.

Starts a room-scoped attachment upload for the authenticated user.

POST /api/connect/chatto.api.v1.AssetUploadService/CreateUpload

Request to start a room-scoped attachment upload.

FieldTypeDescription
room_idstringRequired room ID.
filenamestringOriginal filename supplied by the client.
content_typestringMIME content type. Empty values are treated as application/octet-stream.
sizeint64Required total file size in bytes.
sha256stringRequired SHA-256 digest of the complete file, lowercase hexadecimal.

Response after creating an upload.

FieldTypeDescription
uploadAssetUploadCreated upload session.

Appends one chunk at the upload’s current committed offset.

POST /api/connect/chatto.api.v1.AssetUploadService/UploadChunk

Request to append one chunk to an upload.

FieldTypeDescription
upload_idstringRequired upload session ID.
offsetint64Byte offset where this chunk starts.
contentbytesChunk bytes. The server enforces a per-RPC size limit.
chunk_sha256stringSHA-256 digest of this chunk, lowercase hexadecimal.

Response after committing an upload chunk.

FieldTypeDescription
uploadAssetUploadUpdated upload session.

Reads current upload state for retry or resume.

POST /api/connect/chatto.api.v1.AssetUploadService/GetUpload

Request to fetch upload state.

FieldTypeDescription
upload_idstringRequired upload session ID.

Response containing upload state.

FieldTypeDescription
uploadAssetUploadCurrent upload session.

Verifies the completed upload and creates the attachment asset.

POST /api/connect/chatto.api.v1.AssetUploadService/CompleteUpload

Request to complete an upload and create its attachment asset.

FieldTypeDescription
upload_idstringRequired upload session ID.

Response after an upload completes.

FieldTypeDescription
uploadAssetUploadCompleted upload session.
assetAssetAttachment asset produced by this upload.

Cancels an incomplete upload and releases temporary storage.

POST /api/connect/chatto.api.v1.AssetUploadService/CancelUpload

Request to cancel an upload.

FieldTypeDescription
upload_idstringRequired upload session ID.

Response after cancelling an upload.

FieldTypeDescription
uploadAssetUploadUpdated upload session.