v1

latestOpenAPI 3.0.0Apache 2.0 License2026-07-1435190156.6 KB

Uploads a file that can then be used either as a default in a <code>FileUploadCard</code> from Q App definition or as a file that is used inside a single Q App run. The purpose of the document is determined by a scope parameter that indicates whether it is at the app definition level or at the app session level.

post/apps.importDocument#instance-id

Headers

instance-idstring required

The unique identifier of the Amazon Q Business application environment instance.

Request body

cardIdstring required

The unique identifier of the card the file is associated with.

appIdstring required

The unique identifier of the Q App the file is associated with.

fileContentsBase64string required

The base64-encoded contents of the file to upload.

fileNamestring required

The name of the file being uploaded.

scope'APPLICATION' | 'SESSION' required

Whether the file is associated with a Q App definition or a specific Q App session.

sessionIdstring

The unique identifier of the Q App session the file is associated with, if applicable.

Response

Success

fileIdstring

The unique identifier assigned to the uploaded file.