# UpdateLocationParameter

Update a location parameter

`PUT /api/v2/companies/{companyId}/locations/{locationId}/parameters/{id}`

**API:** AvaTax API
**Tag:** Locations
**API Version:** v2
**Base URL:** https://sandbox-rest.avatax.com/
**Content-Type:** `application/json`
**Accepts:** `application/json`
**Authentication:** API Key (`Authorization` in header) or OAuth 2.0 or Basic (username + license key)

Source: https://developer.avalara.com/products/avatax/api/methods/Locations/UpdateLocationParameter/

## Description

Update a location parameter.
            
Some locations can be taxed differently depending on the properties of that location. In AvaTax, these tax-affecting properties are called "parameters".
            
A parameter added to a location will be used by default in tax calculation but will not show on the transaction line referencing the location.
            
A parameter specified on a transaction line will override a location parameter if they share the same parameter name.

### Security Policies

* This API requires one of the following user roles: AccountAdmin, AvaTaxOnlyAccountAdmin, AvaTaxOnlyCompanyAdmin, BatchServiceAdmin, CompanyAdmin, CSPAdmin, CSPTester, FirmAdmin, ReturnsOnlyAccountAdmin, ReturnsOnlyCompanyAdmin, SiteAdmin, SSTAdmin, SystemAdmin, TechnicalSupportAdmin.

## Parameters

| Name | Type | In | Required | Description |
|---|---|---|---|---|
| `companyId` | integer | path | Yes | The company id. |
| `locationId` | integer | path | Yes | The location id |
| `id` | integer | path | Yes | The location parameter id |
| `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

**Schema:** `LocationParameterModel`

The parameter associated with a company location.

| Property | Type | Required | Description |
|---|---|---|---|
| `id` | integer | No | The ID number of the parameter. Example: `0`. |
| `name` | string | **Yes** | The parameter's name. Example: `NumberOfUnitsForRent`. |
| `unit` | string | No | The parameter's value. Example: `Count`. |
| `value` | string | **Yes** | The value of the parameter. Example: `10`. |
| `locationId` | integer | No | The ID of the company location the parameter associated with. Example: `12345`. |

## Responses

| Status | Description | Schema |
|---|---|---|
| 200 | Success | `LocationParameterModel` |
| 400 | Bad Request |  |
| 401 | Unauthorized |  |
| 404 | Not Found |  |

### 200 Response: `LocationParameterModel`

The parameter associated with a company location.

| Property | Type | Required | Description |
|---|---|---|---|
| `id` | integer | No | The ID number of the parameter. Example: `0`. |
| `name` | string | **Yes** | The parameter's name. Example: `NumberOfUnitsForRent`. |
| `unit` | string | No | The parameter's value. Example: `Count`. |
| `value` | string | **Yes** | The value of the parameter. Example: `10`. |
| `locationId` | integer | No | The ID of the company location the parameter associated with. Example: `12345`. |

## Example Request

```bash
curl -X PUT "https://sandbox-rest.avatax.com/api/v2/companies/{companyId}/locations/{locationId}/parameters/{id}" \
  -H "Authorization: Basic <credentials>" \
  -H "Content-Type: application/json" \
  -H "Accept: application/json" \
  -d '{
  "id": 0,
  "name": "NumberOfUnitsForRent",
  "unit": "Count",
  "value": "10",
  "locationId": 12345
}'
```