# ResolveAddress

Retrieve geolocation information for a specified US or Canadian address

`GET /api/v2/addresses/resolve`

**API:** AvaTax API
**Tag:** Addresses
**API Version:** v2
**Base URL:** https://sandbox-rest.avatax.com/
**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/Addresses/ResolveAddress/

## Description

Resolve a US or Canadian address against Avalara's address validation system.  Note that this API is 
valid for US and Canadian addresses only.  

If the address can be resolved, this API provides the latitude and longitude of the resolved location.  
The value `resolutionQuality` can be used to identify how closely this address can be located.  If the 
address cannot be clearly located, use the `messages` structure to learn more about problems with this address.
This is the same API as the POST /api/v2/addresses/resolve endpoint.
Both verbs are supported to provide for flexible implementation.
            
In order to get any evaluation for an address, please provide at least one of the following fields/pairs:
1. postal code
2. line1 + city + region
3. line1 + postal code

### Security Policies

* This API requires one of the following user roles: AccountAdmin, AccountOperator, AccountUser, AvaTaxOnlyAccountAdmin, AvaTaxOnlyAccountUser, AvaTaxOnlyCompanyAdmin, AvaTaxOnlyCompanyUser, BatchServiceAdmin, CompanyAdmin, CompanyUser, CSPTester, ReturnsOnlyAccountAdmin, ReturnsOnlyCompanyAdmin, SSTAdmin, TechnicalSupportAdmin, TechnicalSupportUser.
* This API depends on the following active services:*Required* (all):  AutoAddress.

## Parameters

| Name | Type | In | Required | Description |
|---|---|---|---|---|
| `line1` | string | query | No | Line 1 |
| `line2` | string | query | No | Line 2 |
| `line3` | string | query | No | Line 3 |
| `city` | string | query | No | City |
| `region` | string | query | No | State / Province / Region |
| `postalCode` | string | query | No | Postal Code / Zip Code |
| `country` | string | query | No | Two character ISO 3166 Country Code (see /api/v2/definitions/countries for a full list) |
| `textCase` | string | query | No | selectable text case for address validation |
| `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/) . |

## Responses

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

### 200 Response: `AddressResolutionModel`

Address Resolution Model

| Property | Type | Required | Description |
|---|---|---|---|
| `address` | AddressInfo | No | The original address |
| `validatedAddresses` | ValidatedAddressInfo[] | No | The validated address or addresses |
| `coordinates` | CoordinateInfo | No | The geospatial coordinates of this address |
| `resolutionQuality` | string | No | The resolution quality of the geospatial coordinates Values: `NotCoded`, `External`, `CountryCentroid`, `RegionCentroid`, `PartialCentroid`, `PostalCentroidGood`, `PostalCentroidBetter`, `PostalCentroidBest`, `Intersection`, `Interpolated`, `Rooftop`, `Constant`. Example: `NotCoded`. |
| `taxAuthorities` | TaxAuthorityInfo[] | No | List of informational and warning messages regarding this address |
| `messages` | AvaTaxMessage[] | No | List of informational and warning messages regarding this address |

## Example Request

```bash
curl -X GET "https://sandbox-rest.avatax.com/api/v2/addresses/resolve" \
  -H "Authorization: Basic <credentials>" \
  -H "Accept: application/json"
```