Upload Enrollment Document

Returns a pre-signed URL to upload a PDF document for the specified transaction enrollment.

POST/enrollments/{enrollmentId}/documents

This endpoint returns a pre-signed URL that you can use to upload a PDF document related to the specified transaction enrollment.

  1. Call this endpoint with the enrollment ID for the transaction enrollment request where you want to upload the PDF. The enrollment ID is returned in the responses for the Create Enrollment and List Enrollments endpoints. It's also listed at the top of the enrollment's details page in the Stedi portal.

  2. The endpoint returns a pre-signed URL that you can use to upload the PDF document to the enrollment record. The URL expires in 24 hours.

  3. Use a PUT request to upload the attachment file to the pre-signed URL (uploadURL) in the response. The request must include a Content-Type header set to application/pdf.

    curl --request PUT \
    --url "<uploadUrl>" \
    --header "Content-Type: application/pdf" \
    --upload-file /path/to/file.pdf

    Uploaded documents are listed on the enrollment's details page in the Stedi portal.

Document status

Calling this endpoint creates a new document record on the enrollment with its status set to PENDING. When you successfully upload the PDF to the pre-signed URL, the document record's status changes from PENDING to UPLOADED.

After 24 hours, Stedi automatically deletes any document records that are still in the PENDING status. In this case, you'll need to call this endpoint again to get a new pre-signed URL for uploading the document.

Authorization
RequiredHeader

A Stedi API Key for authentication.

Path Parameters

The enrollment ID for the transaction enrollment where you want to upload the PDF document. The enrollment ID is returned in the responses for the Create Enrollment and List Enrollments endpoints. It's also listed at the top of the enrollment's details page in the Stedi portal.

Body

application/json
name
StringRequired

The file name of the PDF document you want to upload. The name should include the file extension, such as provider-license.pdf. This name will be displayed in the Stedi portal.

taskId
String

The ID for the task associated with this PDF upload. Only include this property when the PDF upload is related to completing a specific task on the transaction enrollment.

Response

application/json

CreateEnrollmentDocumentUpload 200 response

enrollmentId
StringRequired

The enrollment ID for the transaction enrollment request associated with the PDF document.

uploadUrl
StringRequired

The pre-signed URL you can use to upload the PDF document. This URL expires after 24 hours.

documentId
StringRequired

A unique identifier for the document record within Stedi.