Skip to main content
GET
/
api
/
v2
/
users
/
{projectKey}
/
{environmentKey}
List users
curl --request GET \
  --url https://app.launchdarkly.com/api/v2/users/{projectKey}/{environmentKey} \
  --header 'Authorization: <api-key>'
{
  "totalCount": 245,
  "items": [
    {
      "lastPing": "2022-06-28T23:21:29.176609596Z",
      "environmentId": "1234a56b7c89d012345e678f",
      "ownerId": "12ab3c45de678910abc12345",
      "user": {
        "key": "user-key-123abc",
        "secondary": "2398127",
        "ip": "10.10.10.10",
        "country": "United States",
        "email": "sandy@example.com",
        "firstName": "Sandy",
        "lastName": "Smith",
        "avatar": "http://example.com/avatar.png",
        "name": "Sandy Smith",
        "anonymous": false,
        "custom": {},
        "privateAttrs": [
          "<string>"
        ]
      },
      "sortValue": "user-key-123abc",
      "_links": {
        "parent": {
          "href": "/api/v2/users/my-project/my-environment",
          "type": "application/json"
        },
        "self": {
          "href": "/api/v2/users/my-project/my-environment/my-user",
          "type": "application/json"
        },
        "settings": {
          "href": "/api/v2/users/my-project/my-environment/my-user/flags",
          "type": "text/html"
        },
        "site": {
          "href": "/my-project/my-environment/users/my-user",
          "type": "text/html"
        }
      },
      "_access": {
        "denied": [
          {
            "action": "<string>",
            "reason": {
              "effect": "allow",
              "resources": [
                "proj/*:env/*;qa_*:/flag/*"
              ],
              "notResources": [
                "<string>"
              ],
              "actions": [
                "*"
              ],
              "notActions": [
                "<string>"
              ],
              "role_name": "<string>"
            }
          }
        ],
        "allowed": [
          {
            "action": "<string>",
            "reason": {
              "effect": "allow",
              "resources": [
                "proj/*:env/*;qa_*:/flag/*"
              ],
              "notResources": [
                "<string>"
              ],
              "actions": [
                "*"
              ],
              "notActions": [
                "<string>"
              ],
              "role_name": "<string>"
            }
          }
        ]
      }
    }
  ],
  "_links": {
    "next": {
      "href": "/api/v2/users/my-project/my-environment?after=1647993600000&limit=20&searchAfter=my-user",
      "type": "application/json"
    },
    "self": {
      "href": "/api/v2/users/my-project/my-environment?after=1647993600000&limit=20",
      "type": "application/json"
    }
  }
}

Documentation Index

Fetch the complete documentation index at: https://launchdarkly-preview.mintlify.app/llms.txt

Use this file to discover all available pages before exploring further.

Authorizations

Authorization
string
header
required

Path Parameters

projectKey
string<string>
required

The project key

environmentKey
string<string>
required

The environment key

Query Parameters

limit
integer<int64>

The number of elements to return per page

searchAfter
string<string>

Limits results to users with sort values after the value you specify. You can use this for pagination, but we recommend using the next link we provide instead.

Response

Users collection response

totalCount
integer
required

The total number of users in the environment

Example:

245

items
object[]
required

Details on the users

The location and content type of related resources

Example:
{
"next": {
"href": "/api/v2/users/my-project/my-environment?after=1647993600000&limit=20&searchAfter=my-user",
"type": "application/json"
},
"self": {
"href": "/api/v2/users/my-project/my-environment?after=1647993600000&limit=20",
"type": "application/json"
}
}