---
title: "Upload a supporting document"
method: POST
path: "/prior-authorities/{priorAuthorityId}/documents"
tags: ["Prior Authority"]
---

# Upload a supporting document

`POST /prior-authorities/{priorAuthorityId}/documents`

## Request

- Base URL: `http://localhost:8080`
- URL: `http://localhost:8080/prior-authorities/{priorAuthorityId}/documents`
- Auth: none declared

Accepts a multipart/form-data file upload from the frontend and returns the uploaded file's metadata. The document is uploaded without a category; use the PATCH endpoint to assign one afterwards.

## Path parameters

- `priorAuthorityId` string, uuid, required

## Request body `multipart/form-data`

- object
  - `file` string, binary, required: File to upload.

## Response `200`

File accepted.

- UploadedDocument: A document uploaded as supporting evidence for a prior-authority request.
  - `documentId` string, uuid: Identifier assigned to the uploaded document by the Access Data Store.
  - `documentType` 'GATEWAY_EVIDENCE' | 'MERITS_REPORT' | 'STATEMENT_OF_CASE' | 'COURT_APPLICATION' | 'COURT_ORDER' | 'EXPERT_REPORT' | 'COURT_APPLICATION_OR_ORDER' | 'PARENTAL_RESPONSIBILITY' | 'LOCAL_AUTHORITY_ASSESSMENT' | 'GROUNDS_OF_APPEAL' | 'COUNSEL_OPINION' | 'JUDGEMENT' | 'PLF_COURT_ORDER' | 'LETTER_OF_INSTRUCTION' | 'ESTIMATE_OF_COSTS' | 'ALTERNATIVE_QUOTE' | 'OTHER_PARTY_CERTIFICATE_REFERENCE' | 'OTHER_SUPPORTING_DOCUMENT' | 'PRIMARY_QUOTE' | 'ADDITIONAL_QUOTE': Type of document that was uploaded.
  - `fileName` string, required: Filename of the uploaded document.
  - `fileType` string: File extension/type of the uploaded document.
  - `mediaType` string: MIME content type of the uploaded document.
  - `hostedUrl` string
  - `size` integer: Size of the uploaded document, in bytes.
  - `uploadedAt` string, date-time: Timestamp the document was uploaded.
  - `sourceService` string: The service that uploaded the document to the Access Data Store.
  - `checksum` string: Checksum of the uploaded document contents.

## Other responses

- `400`: No file supplied or file is empty.
- `404`: Prior authority not found in the access data store.
- `409`: The access data store rejected the document as a conflict.
- `413`: File exceeds the configured maximum size.
- `415`: Unsupported file type.
- `502`: The access data store failed to store the document.

## Changes

- **2026-09-21** `5885d8e9baa9`: 3 info
  - added the non-success response with the status `404`
  - added the non-success response with the status `409`
  - added the non-success response with the status `502`
- **2026-09-16** `c96fb373a2c9`: 5 info
  - added the optional property `checksum` to the response with the `200` status
  - added the optional property `documentType` to the response with the `200` status
  - added the optional property `fileType` to the response with the `200` status
  - added the optional property `mediaType` to the response with the `200` status
  - …1 more
- **2026-09-11** `efed7defdc0c`: 1 info
  - endpoint added

[Operation history](https://skmtc.dev/ministryofjustice/apis/ministry-of-justice-laa-civil-manage-api/changes/prior-authorities/:priorAuthorityId/documents/post.md)

---

[API](https://skmtc.dev/ministryofjustice/apis/ministry-of-justice-laa-civil-manage-api.md) - [All operations](https://skmtc.dev/ministryofjustice/apis/ministry-of-justice-laa-civil-manage-api/llms.txt) - [OpenAPI document](https://skmtc.dev/ministryofjustice/apis/ministry-of-justice-laa-civil-manage-api/revisions/fc3ff4e8c6f9?raw)
