> For the complete documentation index, see [llms.txt](https://partner-docs.covergenius.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://partner-docs.covergenius.com/xclaim/claims/claim-files/upload-file-for-an-existing-claim.md).

# Upload File for an Existing Claim

Upload a file with and attach it to a claim that has already been submitted

## Upload File for an Existing Claim

<mark style="color:green;">`POST`</mark> `https://api.xclaim.xcover-staging.com/partners/{partnerCode}/claims/{claimUuid}/files`

Upload a file with and attach it to a claim that has already been submitted. Note that the `section_field_id` in this request can be obtained from the FNOL request for a given claim type.

#### Path Parameters

| Name                                          | Type   | Description |
| --------------------------------------------- | ------ | ----------- |
| partnerCode<mark style="color:red;">\*</mark> | String | eg. XYZ999  |

#### Headers

| Name                                            | Type   | Description          |
| ----------------------------------------------- | ------ | -------------------- |
| Authorization<mark style="color:red;">\*</mark> | String | Bearer {{JWT token}} |

{% tabs %}
{% tab title="422: Unprocessable Entity " %}
{% tabs %}
{% tab title="Request" %}

```json
{
    "file": "dummy.pdf <file-resource>",
    "section_field_id": null
}
```

{% endtab %}

{% tab title="Response" %}

```json
{
    "type": "exception",
    "message": "422 Unprocessable Content",
    "errors": {
        "sectionFieldId": [
            "The section field id must be a valid UUID."
        ]
    }
}
```

{% endtab %}
{% endtabs %}
{% endtab %}

{% tab title="422: Unprocessable Entity " %}
{% tabs %}
{% tab title="Request" %}

```json
{
    "file": "dummy.pdf <file-resource>",
    "section_field_id": "96f13930-f64b-4f00-90cd-7b6983edfb91"
}
```

{% endtab %}

{% tab title="Response" %}

```json
{
    "type": "exception",
    "message": "Could not find the claim with id of fd98bfd5-7702-4ede-afdc-78686b3bdf99"
}
```

{% endtab %}
{% endtabs %}
{% endtab %}

{% tab title="201: Created " %}
{% tabs %}
{% tab title="Request" %}

```
{
    "file": "dummy.pdf <file-resource>",
    "section_field_id": "96f13930-f64b-4f00-90cd-7b6983edfb91"
}
```

{% endtab %}

{% tab title="Response" %}

```json
{
    "data": {
        "id": "017dc109-10a6-4163-8a11-2d54b3093ffe",
        "claimId": "fd98bfd5-7702-4ede-afdc-78686b3bdfb9",
        "location": "claim_files/f76698c4-5360-11ee-9151-41990e09938a.pdf",
        "meta": {
            "dirname": ".",
            "basename": "dummy.pdf",
            "extension": "pdf",
            "filename": "dummy"
        },
        "createdAt": "2023-09-15T00:44:02+00:00",
        "updatedAt": "2023-09-15T00:44:02+00:00"
    }
}
```

{% endtab %}
{% endtabs %}
{% endtab %}
{% endtabs %}


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://partner-docs.covergenius.com/xclaim/claims/claim-files/upload-file-for-an-existing-claim.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
