# isAuthorized refactor to GetAccount

Source: https://developer.avalara.com/soap-to-restv2-refactor-guide/rtv7710199639775/

# isAuthorized refactor to GetAccount

Learn how to refactor from the isAuthorized method in SOAP to the GetAccount method in RESTv2, including field differences and examples.

This example shows how to refactor from [isAuthorized](https://developer.avalara.com/api-reference/avatax/soap/methods/isAuthorized/) in SOAP to [GetAccount](https://developer.avalara.com/api-reference/avatax/rest/v2/methods/Accounts/GetAccount/) in RESTv2. It also includes a table showing the differences in the fields that are included in each API.

SOAP

RESTv2

isAuthorized.Message

GetAccount

## Examples

**SOAP**

```
POST https://development.avalara.net/Tax/TaxSvc.asmx/V2
    {{accountId}} {{licenseKey}}    Test Test SOAP_API      Test  
```

**REST V2**

```
curl
  -X GET
  -H 'Accept: application/json'
  -H 'Authorization: Basic ${btoa(`:`)}'
  'https://sandbox-rest.avatax.com/api/v2/accounts/{accountid}'
```