Skip to content

List members

member.list(MemberListParams**kwargs) -> MemberListResponse
GET/v1/members

Returns a paginated list of members in your workspace. Results are sorted by when the record was created in Lightfield (createdAt), newest first. Use offset and limit to paginate through results. See List endpoints for more information about pagination.

Required scope: members:read

Rate limit category: Search

ParametersExpand Collapse
limit: Optional[int]

Maximum number of records to return. Defaults to 25, maximum 25.

minimum1
maximum9007199254740991
offset: Optional[int]

Number of records to skip for pagination. Defaults to 0.

minimum0
maximum9007199254740991
ReturnsExpand Collapse
class MemberListResponse: …
data: List[Data]

Array of member objects for the current page.

id: str

Unique identifier for the member.

created_at: str

ISO 8601 timestamp of when the member was created.

fields: DataFields

Map of field names to their typed values.

email: DataFieldsEmail

The member’s email address.

value: str

The field value.

value_type: Literal["EMAIL"]

The data type of the field value.

name: DataFieldsName

The member’s full name.

value: DataFieldsNameValue
first_name: Optional[str]

The contact’s first name.

last_name: Optional[str]

The contact’s last name.

value_type: Literal["FULL_NAME"]

The data type of the field value.

profile_image: DataFieldsProfileImage

URL of the member’s profile image, or null if unset.

value: Optional[str]

The field value, or null if unset.

value_type: Literal["URL"]

The data type of the field value.

role: DataFieldsRole

The member’s workspace role.

value: str

The field value.

value_type: Literal["TEXT"]

The data type of the field value.

relationships: DataRelationships

Map of relationship names to their associated entities.

user: DataRelationshipsUser

The underlying user record for this workspace member.

cardinality: Literal["HAS_ONE"]

Whether the relationship is has_one or has_many.

object_type: Literal["user"]

The type of the related object.

values: List[str]

IDs of the related users.

updated_at: Optional[str]

ISO 8601 timestamp of when the member was last updated, or null.

object: str

The object type, always "list".

total_count: int

Total number of members in the workspace.

minimum0
maximum9007199254740991

List members

from lightfield import Lightfield

client = Lightfield(
    api_key="My API Key",
)
member_list_response = client.member.list()
print(member_list_response.data)
{
  "data": [
    {
      "id": "id",
      "createdAt": "createdAt",
      "fields": {
        "$email": {
          "value": "value",
          "valueType": "EMAIL"
        },
        "$name": {
          "value": {
            "firstName": "firstName",
            "lastName": "lastName"
          },
          "valueType": "FULL_NAME"
        },
        "$profileImage": {
          "value": "value",
          "valueType": "URL"
        },
        "$role": {
          "value": "value",
          "valueType": "TEXT"
        }
      },
      "httpLink": "httpLink",
      "relationships": {
        "$user": {
          "cardinality": "HAS_ONE",
          "objectType": "user",
          "values": [
            "string"
          ]
        }
      },
      "updatedAt": "updatedAt"
    }
  ],
  "object": "object",
  "totalCount": 0
}
Returns Examples
{
  "data": [
    {
      "id": "id",
      "createdAt": "createdAt",
      "fields": {
        "$email": {
          "value": "value",
          "valueType": "EMAIL"
        },
        "$name": {
          "value": {
            "firstName": "firstName",
            "lastName": "lastName"
          },
          "valueType": "FULL_NAME"
        },
        "$profileImage": {
          "value": "value",
          "valueType": "URL"
        },
        "$role": {
          "value": "value",
          "valueType": "TEXT"
        }
      },
      "httpLink": "httpLink",
      "relationships": {
        "$user": {
          "cardinality": "HAS_ONE",
          "objectType": "user",
          "values": [
            "string"
          ]
        }
      },
      "updatedAt": "updatedAt"
    }
  ],
  "object": "object",
  "totalCount": 0
}