# Update_Invalid_Reason

Update an invalid reason.

`PUT /v2/invalid-reasons/{id}`

**API:** Avalara CertCapture RESTful APIs
**Tag:** Invalid Reason
**API Version:** v2
**Base URL:** https://sbx-api.certcapture.com/v2/
**Content-Type:** `application/x-www-form-urlencoded`
**Accepts:** `application/json`
**Authentication:** Basic (username + license key) or API Key (`Authorization` in header)

Source: https://developer.avalara.com/products/ecm/api/certcapture/methods/Invalid%20Reason/Update_Invalid_Reason/

## Description

Update an invalid reason for an account.

## Parameters

| Name | Type | In | Required | Description |
|---|---|---|---|---|
| `x-client-id` | integer | header | Yes | To access a client ID, it is available from Company Settings -> Company Details -> Company ID |
| `id` | integer | path | Yes | The id of the invalid reason |
| `name` | string | formData | Yes | The name of the Invalid Reason. |
| `description` | string | formData | Yes | The description of the Invalid Reason. |
| `document_types` | object | formData | Yes | The document type of the invalid reason. |

## Responses

| Status | Description | Schema |
|---|---|---|
| 200 | Success | `InvalidReasonResponse` |
| 400 | Bad Request |  |
| 401 | Unauthorized |  |

### 200 Response: `InvalidReasonResponse`

Invalid Reason Response Model

| Property | Type | Required | Description |
|---|---|---|---|
| `created` | string | No | DateTime of when the record was created. Example: `2017-10-26 12:41:48.377959`. |
| `description` | string | No | The description of the Invalid Reason. Example: `Customer does not accept drop shipments.`. |
| `id` | integer | No | System Generated Invalid Reason id Example: `1`. |
| `modified` | string | No | DateTime of when the record was modified. Example: `2017-10-26 12:41:48.377959`. |
| `name` | string | No | The name of the Invalid Reason. Example: `DROP SHIP NOT ALLOWED`. |
| `system_code` | boolean | No | Designates if the Invalid Reason is active or not. Example: `false`. |

## Example Request

```bash
curl -X PUT "https://sbx-api.certcapture.com/v2/v2/invalid-reasons/{id}" \
  -H "Authorization: Basic <credentials>" \
  -H "Content-Type: application/x-www-form-urlencoded" \
  -H "Accept: application/json"
```