---
title: "List Tenants"
method: GET
path: "/v2/facts/{proj_id}/{env_id}/tenants"
tags: ["Tenants"]
---

# List Tenants

`GET /v2/facts/{proj_id}/{env_id}/tenants`

Lists all the tenants defined within an env.

## Path parameters

- `proj_id` string, required — Either the unique id of the project, or the URL-friendly key of the project (i.e: the "slug").
- `env_id` string, required — Either the unique id of the environment, or the URL-friendly key of the environment (i.e: the "slug").

## Query parameters

- `search` string — Text search for the tenant name or key
- `include_total_count` boolean — Include total count in response
- `page` integer — Page number of the results to fetch, starting at 1.
- `per_page` integer — The number of results per page (max 100).

## Response `200`

Successful Response

- union
  - PaginatedResultTenantRead
    - `data` TenantRead[], required — List of Tenants
      - `key` string, required — A unique id by which Permit will identify the tenant. The tenant key must be url-friendly (slugified).
      - `id` string, uuid, required — Unique id of the tenant
      - `organization_id` string, uuid, required — Unique id of the organization that the tenant belongs to.
      - `project_id` string, uuid, required — Unique id of the project that the tenant belongs to.
      - `environment_id` string, uuid, required — Unique id of the environment that the tenant belongs to.
      - `created_at` string, date-time, required — Date and time when the tenant was created (ISO_8601 format).
      - `updated_at` string, date-time, required — Date and time when the tenant was last updated/modified (ISO_8601 format).
      - `last_action_at` string, date-time, required — Date and time when the tenant was last active (ISO_8601 format). In other words, this is the last time a permission check was done on a resource belonging to this tenant.
      - `name` string, required — A descriptive name for the tenant
      - `description` string — an optional longer description of the tenant
      - `attributes` object — Arbitraty tenant attributes that will be used to enforce attribute-based access control policies.
    - `total_count` integer, required
    - `page_count` integer
  - TenantRead[]
    - `key` string, required — A unique id by which Permit will identify the tenant. The tenant key must be url-friendly (slugified).
    - `id` string, uuid, required — Unique id of the tenant
    - `organization_id` string, uuid, required — Unique id of the organization that the tenant belongs to.
    - `project_id` string, uuid, required — Unique id of the project that the tenant belongs to.
    - `environment_id` string, uuid, required — Unique id of the environment that the tenant belongs to.
    - `created_at` string, date-time, required — Date and time when the tenant was created (ISO_8601 format).
    - `updated_at` string, date-time, required — Date and time when the tenant was last updated/modified (ISO_8601 format).
    - `last_action_at` string, date-time, required — Date and time when the tenant was last active (ISO_8601 format). In other words, this is the last time a permission check was done on a resource belonging to this tenant.
    - `name` string, required — A descriptive name for the tenant
    - `description` string — an optional longer description of the tenant
    - `attributes` object — Arbitraty tenant attributes that will be used to enforce attribute-based access control policies.

## Other responses

- `422` — Validation Error

---

[API](https://skmtc.net/permit/apis/permit-io-api.md) · [All operations](https://skmtc.net/permit/apis/permit-io-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/permit/permit-io-api/revisions/2d4b53fdbeb9/schema)
