# Addresses

This endpoint returns any address associated with the business, such as registered addresses, trading address etc.

Using geolocation data, we have also incorporated latitude and longitude coordinates into our addresses. A value in decimal degrees to 5 decimal places is precise to approximately 1 metre.

### Example URL:

```
https://api2.redflagalert.net/v4/companies/01777777/addresses/
```

### JSON Structure:

```javascript
{
	"data": [{
		"attributes": {
			"town": "West Drayton",
			"type": "trading",
			"location": {
				"lat": 51.5373252879822,
				"lon": -0.487355421766335
			},
			"county": "Middlesex",
			"postcode": "UB7 0GB",
			"address_line_4": null,
			"address_line_2": null,
			"address_line_3": null,
			"address_line_1": "Po Box 365"
		},
		"type": "address",
		"id": "645323-645323"
	}]
}
```

### Attributes

| Field Key                                                                                                                                   | Description                                                                                         |
| ------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------- |
| `town`                                                                                                                                      | The town of the registered address.                                                                 |
| `type`                                                                                                                                      | Type of address, such as trading, registered etc.                                                   |
| `location`                                                                                                                                  | A dictionary of key/value pairs containing the latitude and longitude of the business or post code. |
| `county`                                                                                                                                    | The county containing the address.                                                                  |
| `postcode`                                                                                                                                  | The post code of the business address.                                                              |
| <p><code>address\_line\_1</code><br><code>address\_line\_2</code><br><code>address\_line\_3</code><br><code>address\_line\_4</code><br></p> | Lines of the business address. `null` will be returned on empty lines.                              |


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://developer.redflagalert.net/company-resources/addresses.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
