# getaddress-api

> GetAddress.io core address look-up functionality

Latest version **2.3.1** (published 2025-02-23) · MIT license · 0 weekly downloads

## Install

```sh
npm install getaddress-api
pnpm add getaddress-api
yarn add getaddress-api
bun add getaddress-api
```

## Health

**Score 35/100 (D)** — status: maintenance-mode.

Positive: has types; esm support; no vulnerabilities.

Warnings: low downloads.

Negative: stale; low maintenance score.

## Facts

| | |
|---|---|
| Version | 2.3.1 |
| Published | 2025-02-23 |
| First published | 2021-12-30 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | bundled |
| Module format | ESM |
| Node | >= 18.0.0 |
| Dependencies | 0 |
| Unpacked size | 117.9 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 1 |
| Author | Codeberry Limited |
| Maintainers | getaddress |
| Keywords | getaddress.io postcode getaddress getaddress() address API |

## Links

- npm: https://www.npmjs.com/package/getaddress-api
- Repository: https://github.com/getAddress/api
- Homepage: https://getaddress.io
- Issues: https://github.com/getAddress/api/issues
- npm.io page: https://npm.io/package/getaddress-api

## Recent versions

- 2.3.1 (latest) — 2025-02-23
- 2.3.0 — 2025-02-22
- 2.2.0 — 2025-01-13
- 2.1.0 — 2024-12-20
- 2.0.5 — 2024-11-27
- 2.0.3 — 2024-11-27
- 2.0.1 — 2024-11-25
- 2.0.0 — 2024-11-25
- 1.4.6 — 2024-05-15
- 1.4.4 — 2024-04-30
- 1.4.3 — 2024-03-28
- 1.4.1 — 2024-03-25
- 1.4.0 — 2024-03-25
- 1.3.2 — 2024-03-25
- 1.3.1 — 2022-11-29
- … 25 more at https://npm.io/package/getaddress-api/versions

## README

GetAddress.io core address look-up functionality.

# Installation
```
npm install getaddress-api
```
# Usage

## Autocomplete
```
import Client from 'getaddress-api'

const api = new Client("<your API key>");

const autocompleteResult = await api.autocomplete('TR19 7AA');

if(autocompleteResult.isSuccess)
{
  var success = autocompleteResult.toSuccess();

  for(const suggestion of success.suggestions)
  {
      const address = await api.get(suggestion.id);
      console.log(address);
  }
}
else
{
  const failed = autocompleteResult.toFailed();
  console.log(failed);
}
```

---
_Source: https://npm.io/package/getaddress-api · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
