accounts

get/api/projects/{project_id}/accounts/

Request

  • Base URL: https://us.posthog.com
  • URL: https://us.posthog.com/api/projects/{project_id}/accounts/
  • Auth: HTTP bearer

Path parameters

project_idstring required

Project ID of the project you're trying to access. To find the ID of the project, make a call to /api/projects/.

Query parameters

all_roles_unassignedboolean

When true, returns only accounts where no user actively holds any relationship.

inactive_lastboolean

When true, active and tracked accounts come before churned or ignored ones, and ordering applies within each group. Use with include_churned or include_ignored.

include_churnedboolean

Include churned accounts. Churned accounts are hidden by default.

include_ignoredboolean

Include ignored accounts. Ignored accounts are hidden by default.

limitinteger

Number of results to return per page.

offsetinteger

The initial index from which to return the results.

ordering'-created_at' | '-name' | '-updated_at' | 'created_at' | 'name' | 'updated_at'

Sort order. Defaults to '-created_at'.

searchstring

Case-insensitive substring search across account name and external ID. A query holding an email address also matches accounts that list it as a known email, and a query holding a domain matches accounts that own that email domain.

tagsstring

JSON-encoded array of tag names to filter by, e.g. ["enterprise","priority"]. Returns accounts that have any of the listed tags. Malformed values (not a JSON-encoded list of strings) return a 400.

Response

countinteger required
nextstring uri nullable
previousstring uri nullable

Example response

{
  "count": 123,
  "next": "http://api.example.org/accounts/?offset=400&limit=100",
  "previous": "http://api.example.org/accounts/?offset=200&limit=100"
}

Changes

No recorded changes to this operation across all 1 revision of this API.