> ## Documentation Index
> Fetch the complete documentation index at: https://api-docs.scholarlysoftware.com/llms.txt
> Use this file to discover all available pages before exploring further.

# List users

> Return a list of users



## OpenAPI

````yaml /openapi.json get /api/v1/users
openapi: 3.1.0
info:
  title: Scholarly API V1
  version: v1
  description: API for accessing Scholarly data
  license:
    name: Proprietary
    identifier: Proprietary
servers:
  - url: https://api.scholarlysoftware.com
    description: Production server
security: []
paths:
  /api/v1/users:
    get:
      tags:
        - Users
      summary: List users
      description: Return a list of users
      operationId: listUsers
      parameters:
        - name: Authorization
          in: header
          required: true
          description: Bearer token
          schema:
            type: string
        - name: include
          in: query
          required: false
          description: >-
            Comma-separated list of relationships to include. Allowed:
            `profile`, `employments`, `current_employment`,
            `admin_assistant_roles`, `addresses`, `phone_numbers`
          schema:
            type: string
        - name: sort
          in: query
          required: false
          description: >-
            Sort order. Prefix with `-` for descending. Allowed: `created_at`,
            `updated_at`, `display_name`
          schema:
            type: string
        - name: filter[key]
          in: query
          required: false
          description: >-
            Filter results. Available filters: `email`, `employee_id`,
            `employee_ids` (filter users by employee id for a given
            configuration, example `filter[employee_ids][UID]=12345`),
            `employee_ids.in` (filter users by employee id in a comma-separated
            list for a given configuration, example
            `filter[employee_ids.in][UID]=12345,67890`), `display_name`,
            `display_name.neq`, `display_name.cont` (case-insensitive substring
            match), `display_name.in` (comma-separated list), `display_name.nin`
            (comma-separated list), `profile`, `profile.exists`, `employments`,
            `current_employment`, `current_employment.exists`,
            `admin_assistant_roles`, `addresses`, `phone_numbers`. Custom fields
            can also be filtered with `filter[custom_fields.field_name]`.
          schema:
            type: string
        - name: page[size]
          in: query
          required: false
          description: Number of items per page (max 100)
          schema:
            type: integer
        - name: page[after]
          in: query
          required: false
          description: Cursor for next page
          schema:
            type: string
        - name: page[before]
          in: query
          required: false
          description: Cursor for previous page
          schema:
            type: string
      responses:
        '200':
          description: users found
          content:
            application/vnd.api+json:
              schema:
                type: object
                properties:
                  data:
                    type: array
                    items:
                      $ref: '#/components/schemas/User'
                  meta:
                    $ref: '#/components/schemas/PaginationMeta'
                  links:
                    $ref: '#/components/schemas/PaginationLinks'
                required:
                  - data
        '401':
          description: unauthorized
          content:
            application/vnd.api+json:
              schema:
                $ref: '#/components/schemas/Error'
      security:
        - bearer_auth: []
components:
  schemas:
    User:
      type: object
      properties:
        id:
          type: string
          format: uuid
        type:
          type: string
          const: user
          example: user
        attributes:
          type: object
          properties:
            created_at:
              type: string
              format: datetime
            updated_at:
              type: string
              format: datetime
            custom_fields:
              type:
                - object
                - 'null'
            display_name:
              type: string
            primary_employee_id:
              type:
                - string
                - 'null'
            employee_ids:
              type:
                - object
                - 'null'
            emails:
              type: array
              example:
                - primary@example.com
                - secondary@example.com
              description: >
                The full list of email addresses for the user. The first address
                in the array is the primary email address.


                Some special notes about setting emails in Sandboxes:

                - Emails must be globally unique across all Scholarly accounts,
                including sandboxes. By default, users created in sandboxes will
                not have emails copied over from the production account.

                - Sandbox accounts will still send emails! Scholarly recommends
                setting sandbox user emails to addresses you control to avoid
                sending emails to unintended recipients. Example:
                jsmith@scholarly.edu becomes it+jsmith@scholarly.edu
              items:
                type: string
            deactivated:
              type:
                - boolean
                - 'null'
        relationships:
          type: object
          properties:
            profile:
              type: object
              properties:
                links:
                  type: object
                  properties:
                    related:
                      type:
                        - string
                        - 'null'
                      format: uri
                  required:
                    - related
                meta:
                  type: object
                data:
                  oneOf:
                    - type: object
                      required:
                        - type
                        - id
                      properties:
                        type:
                          type: string
                          const: profile
                          example: profile
                        id:
                          type: string
                          format: uuid
                    - type: 'null'
              anyOf:
                - required:
                    - links
                - required:
                    - meta
                - required:
                    - data
            employments:
              type: object
              properties:
                links:
                  type: object
                  properties:
                    related:
                      type:
                        - string
                        - 'null'
                      format: uri
                  required:
                    - related
                meta:
                  type: object
                data:
                  type: array
                  items:
                    type: object
                    required:
                      - type
                      - id
                    properties:
                      type:
                        type: string
                        const: employment
                        example: employment
                      id:
                        type: string
                        format: uuid
              anyOf:
                - required:
                    - links
                - required:
                    - meta
                - required:
                    - data
            current_employment:
              type: object
              properties:
                links:
                  type: object
                  properties:
                    related:
                      type:
                        - string
                        - 'null'
                      format: uri
                  required:
                    - related
                meta:
                  type: object
                data:
                  oneOf:
                    - type: object
                      required:
                        - type
                        - id
                      properties:
                        type:
                          type: string
                          const: employment
                          example: employment
                        id:
                          type: string
                          format: uuid
                    - type: 'null'
              anyOf:
                - required:
                    - links
                - required:
                    - meta
                - required:
                    - data
            admin_assistant_roles:
              type: object
              properties:
                links:
                  type: object
                  properties:
                    related:
                      type:
                        - string
                        - 'null'
                      format: uri
                  required:
                    - related
                meta:
                  type: object
              anyOf:
                - required:
                    - links
                - required:
                    - meta
            addresses:
              type: object
              properties:
                links:
                  type: object
                  properties:
                    related:
                      type:
                        - string
                        - 'null'
                      format: uri
                  required:
                    - related
                meta:
                  type: object
              anyOf:
                - required:
                    - links
                - required:
                    - meta
            phone_numbers:
              type: object
              properties:
                links:
                  type: object
                  properties:
                    related:
                      type:
                        - string
                        - 'null'
                      format: uri
                  required:
                    - related
                meta:
                  type: object
              anyOf:
                - required:
                    - links
                - required:
                    - meta
      required:
        - id
        - type
        - attributes
    PaginationMeta:
      type: object
      properties:
        page:
          type: object
          properties:
            size:
              type: integer
        total:
          type: integer
    PaginationLinks:
      type: object
      properties:
        self:
          type: string
        first:
          type: string
        next:
          type:
            - string
            - 'null'
        prev:
          type:
            - string
            - 'null'
        last:
          type:
            - string
            - 'null'
    Error:
      type: object
      properties:
        errors:
          type: array
          items:
            type: object
            properties:
              status:
                type: string
              title:
                type: string
              detail:
                type: string
            required:
              - status
              - title
      required:
        - errors
  securitySchemes:
    bearer_auth:
      type: http
      scheme: bearer
      bearerFormat: API Key

````