# Entities

`GET /base/entities`

Group: Base › Entities · Operation ID: `entities`

Returns a list of legal entities. Their id values are the entityId that most other resources reference.

[Open in the interactive reference](https://docs.api.lensing.ai/?op=entities)

## Parameters

| Name | In | Type | Required | Description |
| --- | --- | --- | --- | --- |
| `Api-Version` | header | `"v1"` | yes | The API version this request targets, named by its public identifier. Required on every request; omitting it, or naming a version this company does not have, is answered with 400. This document describes version `v1`. |

## Query surface

- `id` — filter by eq, ne, gt, gte, lt, lte, in, notIn, between, like
- `currency` — filter by eq, ne, gt, gte, lt, lte, in, notIn, between, like
- `timeZone` — filter by eq, ne, gt, gte, lt, lte, in, notIn, between, like
- `status` — filter by eq, ne, gt, gte, lt, lte, in, notIn, between, like
- `entityType` — filter by eq, ne, gt, gte, lt, lte, in, notIn, between, like
- `country` — filter by eq, ne, gt, gte, lt, lte, in, notIn, between, like
- `entityCode` — filter by eq, ne, gt, gte, lt, lte, in, notIn, between, like
- `localeCode` — filter by eq, ne, gt, gte, lt, lte, in, notIn, between, like
- `startDate` — filter by eq, ne, gt, gte, lt, lte, in, notIn, between, like
- `endDate` — filter by eq, ne, gt, gte, lt, lte, in, notIn, between, like
- `lastModifiedDate` — filter by eq, ne, gt, gte, lt, lte, in, notIn, between, like
- Orderable: id, currency, timeZone, status, entityType, country, entityCode, localeCode, startDate, endDate, lastModifiedDate
- Selectable: id, entityName, entityNumber, currency, timeZone, status, entityType, country, entityCode, localeCode, startDate, endDate, lastModifiedDate

## Response

`200` Success

Under `data`, an array of entitiesRow:

| Field | Type | Required | Description |
| --- | --- | --- | --- |
| `id` | string | no | The unique identifier for the legal entity. Other resources reference it as entityId. |
| `entityName` | string | no | The name of the legal entity, for example 'Acme Inc.'. Unique within the tenant. |
| `entityNumber` | string or null | no | The entity's business number, separate from its name. Absent until one is assigned. |
| `currency` | string or null | no | The entity's functional currency, its default for reporting and posting. Format ISO 4217, for example 'USD'. Absent when none has been set. |
| `timeZone` | string or null | no | The time zone the entity operates in. Format IANA time-zone name, for example 'Europe/Berlin'. New entities default to 'Etc/UTC'. Absent when none has been set. |
| `status` | string or null | no | The lifecycle status of the entity. Possible values: 'active', 'inactive', 'created'. 'created' is the default for a new entity. |
| `entityType` | string or null | no | Whether the entity is a legal entity or a non-legal reporting entity. Possible values: 'LegalEntity', 'NonLegalReportingEntity'. Defaults to 'LegalEntity'. |
| `country` | string or null | no | The country the entity is registered in. Format ISO 3166-1 alpha-2, for example 'US'. Absent when none has been set. |
| `entityCode` | string or null | no | A short code for the entity, separate from its entityNumber. Absent until one is assigned. |
| `localeCode` | string or null | no | The locale for documents sent from this entity, setting the language and regional format. Format BCP 47, for example 'en-US'. Absent when none has been set. |
| `startDate` | string (date) or null | no | The date the entity became effective. Format YYYY-MM-DD. Absent when none has been set. |
| `endDate` | string (date) or null | no | The date the entity stops being effective. Format YYYY-MM-DD. Absent when the entity has no scheduled end. |
| `lastModifiedDate` | string (date-time) or null | no | The date and time the entity last changed, in UTC. Format YYYY-MM-DDTHH:mm:ss.sssZ. |

## Statuses

- `400` — Invalid request or business failure
- `401` — Missing or invalid access token
- `403` — Not authorized
- `404` — Not found
- `429` — Too many requests
- `500` — Internal server error
