# UploadW9Files

Replace the PDF file for a W9/W4/W8 form

`POST /w9/forms/{id}/attachment`

**API:** Avalara 1099 & W-9 API Definition
**Tag:** Forms W9
**API Version:** 2.0
**Base URL:** https://api.sbx.avalara.com/avalara1099
**Authentication:** Bearer token

Source: https://developer.avalara.com/products/avalara-1099-and-w9/api/methods/Forms%20W9/UploadW9Files/

## Description

Replaces the PDF file for a W9/W4/W8 form.

## Parameters

| Name | Type | In | Required | Description |
|---|---|---|---|---|
| `id` | string | path | Yes | Id of the form |
| `avalara-version` | string | header | Yes | API version |
| `X-Correlation-Id` | string | header | No | Unique correlation Id in a GUID format |
| `X-Avalara-Client` | string | header | No | Identifies the software you are using to call this API. For more information on the client header, see [Client Headers](https://developer.avalara.com/avatax/client-headers/) . |

## Request Body

**Content-Type:** `multipart/form-data`

## Responses

| Status | Description | Schema |
|---|---|---|
| 200 |  |  |
| 400 | Bad request (e.g., only .pdf files are allowed.) | `ErrorResponse` |
| 401 | Authentication failed |  |
| 404 | W9/W4/W8 form not found | `ErrorResponse` |

## Example Request

```bash
curl -X POST "https://api.sbx.avalara.com/avalara1099/w9/forms/{id}/attachment" \
  -H "Authorization: Basic <credentials>" \
  -H "Accept: application/json"
```