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

# List workspace records

> Lists workspace records, with the option to filter and sort results.

Required scopes: `record_permission:read`, `object_configuration:read`.



## OpenAPI

````yaml https://api.attio.com/openapi/standard-objects post /v2/objects/workspaces/records/query
openapi: 3.1.0
info:
  title: Attio Standard Objects
  version: 2.0.0
servers:
  - url: https://api.attio.com
    description: Production
security:
  - oauth2: []
paths:
  /v2/objects/workspaces/records/query:
    post:
      tags:
        - Workspaces
      summary: List workspace records
      description: |-
        Lists workspace records, with the option to filter and sort results.

        Required scopes: `record_permission:read`, `object_configuration:read`.
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                filter:
                  type: object
                  description: >-
                    An object used to filter results to a subset of records. See
                    the [full guide to filtering and sorting
                    here](/rest-api/guides/filtering-and-sorting).
                  additionalProperties: true
                  example:
                    $and:
                      - workspace_id:
                          value:
                            $eq: '123'
                sorts:
                  type: array
                  items:
                    anyOf:
                      - type: object
                        properties:
                          direction:
                            type: string
                            enum:
                              - asc
                              - desc
                            description: The direction to sort the results by.
                          attribute:
                            type: string
                            description: A slug or ID to identify the attribute to sort by.
                          field:
                            type: string
                            description: >-
                              Which field on the value to sort by e.g.
                              "last_name" on a name value.
                        required:
                          - direction
                          - attribute
                        description: Sort by attribute
                      - type: object
                        properties:
                          direction:
                            type: string
                            enum:
                              - asc
                              - desc
                            description: The direction to sort the results by.
                          path:
                            type: array
                            items:
                              type: array
                              items:
                                anyOf:
                                  - type: string
                                    description: >-
                                      The slug or ID of the object e.g.
                                      "people".
                                  - type: string
                                    description: >-
                                      A slug or ID to identify the attribute to
                                      sort by.
                              minItems: 2
                              maxItems: 2
                            description: >-
                              You may use the `path` property to traverse record
                              reference attributes and parent records on list
                              entries. `path` accepts an array of tuples where
                              the first element of each tuple is the slug or ID
                              of a list/object, and the second element is the
                              slug or ID of an attribute on that list/object.
                              The first element of the first tuple must
                              correspond to the list or object that you are
                              querying. For example, if you wanted to sort by
                              the name of the parent record (a company) on a
                              list with the slug "sales", you would pass the
                              value `[['sales', 'parent_record'], ['companies',
                              'name']]`.
                          field:
                            type: string
                            description: >-
                              Which field on the value to sort by e.g.
                              "last_name" on a name value.
                        required:
                          - direction
                          - path
                        description: Sort by path
                  description: >-
                    An object used to sort results. See the [full guide to
                    filtering and sorting
                    here](/rest-api/guides/filtering-and-sorting).
                  example:
                    - direction: asc
                      attribute: name
                      field: last_name
                limit:
                  type: number
                  description: >-
                    The maximum number of results to return. Defaults to 500.
                    See the [full guide to pagination
                    here](/rest-api/guides/pagination).
                  example: 500
                offset:
                  type: number
                  description: >-
                    The number of results to skip over before returning.
                    Defaults to 0. See the [full guide to pagination
                    here](/rest-api/guides/pagination).
                  example: 0
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                type: object
                properties:
                  data:
                    type: array
                    items:
                      type: object
                      properties:
                        id:
                          type: object
                          properties:
                            workspace_id:
                              type: string
                              format: uuid
                              description: >-
                                A UUID identifying the workspace this record
                                belongs to.
                              example: 14beef7a-99f7-4534-a87e-70b564330a4c
                            object_id:
                              type: string
                              format: uuid
                              description: >-
                                A UUID identifying the object this record
                                belongs to.
                              example: 97052eb9-e65e-443f-a297-f2d9a4a7f795
                            record_id:
                              type: string
                              format: uuid
                              description: A UUID identifying this record.
                              example: bf071e1f-6035-429d-b874-d83ea64ea13b
                          required:
                            - workspace_id
                            - object_id
                            - record_id
                        created_at:
                          type: string
                          description: When this record was created.
                          example: '2022-11-21T13:22:49.061281000Z'
                        web_url:
                          type: string
                          format: uri
                          description: >-
                            A URL that links directly to the record page in the
                            Attio web application.
                          example: >-
                            https://app.attio.com/salarya/person/bf071e1f-6035-429d-b874-d83ea64ea13b
                        values:
                          type: object
                          properties:
                            workspace_id:
                              type: array
                              items:
                                type: object
                                properties:
                                  active_from:
                                    type: string
                                    format: date-time
                                    description: >-
                                      The point in time at which this value was
                                      made "active". `active_from` can be
                                      considered roughly analogous to
                                      `created_at`.
                                    example: '2023-01-01T15:00:00.000000000Z'
                                  active_until:
                                    type:
                                      - string
                                      - 'null'
                                    format: date-time
                                    description: >-
                                      The point in time at which this value was
                                      deactivated. If `null`, the value is
                                      active.
                                    example: '2023-01-01T15:00:00.000000000Z'
                                  created_by_actor:
                                    type: object
                                    description: The actor that created this value.
                                    properties:
                                      id:
                                        type: string
                                        description: An ID to identify the actor.
                                        nullable: true
                                      type:
                                        type: string
                                        enum:
                                          - api-token
                                          - workspace-member
                                          - system
                                          - app
                                        nullable: true
                                        description: >-
                                          The type of actor. [Read more
                                          information on actor types
                                          here](/docs/actors).
                                    example:
                                      type: workspace-member
                                      id: 50cf242c-7fa3-4cad-87d0-75b1af71c57b
                                  value:
                                    type: string
                                    description: >-
                                      A raw text field. Values are limited to
                                      10MB.
                                    example: >-
                                      Lorem ipsum dolor sit amet, consectetur
                                      adipiscing elit, sed do eiusmod tempor
                                      incididunt ut labore et dolore magna
                                      aliqua.
                                  attribute_type:
                                    type: string
                                    enum:
                                      - text
                                    description: The attribute type of the value.
                                    example: text
                                required:
                                  - active_from
                                  - active_until
                                  - created_by_actor
                                  - value
                                  - attribute_type
                                additionalProperties: false
                            name:
                              type: array
                              items:
                                type: object
                                properties:
                                  active_from:
                                    type: string
                                    format: date-time
                                    description: >-
                                      The point in time at which this value was
                                      made "active". `active_from` can be
                                      considered roughly analogous to
                                      `created_at`.
                                    example: '2023-01-01T15:00:00.000000000Z'
                                  active_until:
                                    type:
                                      - string
                                      - 'null'
                                    format: date-time
                                    description: >-
                                      The point in time at which this value was
                                      deactivated. If `null`, the value is
                                      active.
                                    example: '2023-01-01T15:00:00.000000000Z'
                                  created_by_actor:
                                    type: object
                                    description: The actor that created this value.
                                    properties:
                                      id:
                                        type: string
                                        description: An ID to identify the actor.
                                        nullable: true
                                      type:
                                        type: string
                                        enum:
                                          - api-token
                                          - workspace-member
                                          - system
                                          - app
                                        nullable: true
                                        description: >-
                                          The type of actor. [Read more
                                          information on actor types
                                          here](/docs/actors).
                                    example:
                                      type: workspace-member
                                      id: 50cf242c-7fa3-4cad-87d0-75b1af71c57b
                                  value:
                                    type: string
                                    description: >-
                                      A raw text field. Values are limited to
                                      10MB.
                                    example: >-
                                      Lorem ipsum dolor sit amet, consectetur
                                      adipiscing elit, sed do eiusmod tempor
                                      incididunt ut labore et dolore magna
                                      aliqua.
                                  attribute_type:
                                    type: string
                                    enum:
                                      - text
                                    description: The attribute type of the value.
                                    example: text
                                required:
                                  - active_from
                                  - active_until
                                  - created_by_actor
                                  - value
                                  - attribute_type
                                additionalProperties: false
                            users:
                              type: array
                              items:
                                type: object
                                properties:
                                  active_from:
                                    type: string
                                    format: date-time
                                    description: >-
                                      The point in time at which this value was
                                      made "active". `active_from` can be
                                      considered roughly analogous to
                                      `created_at`.
                                    example: '2023-01-01T15:00:00.000000000Z'
                                  active_until:
                                    type:
                                      - string
                                      - 'null'
                                    format: date-time
                                    description: >-
                                      The point in time at which this value was
                                      deactivated. If `null`, the value is
                                      active.
                                    example: '2023-01-01T15:00:00.000000000Z'
                                  created_by_actor:
                                    type: object
                                    description: The actor that created this value.
                                    properties:
                                      id:
                                        type: string
                                        description: An ID to identify the actor.
                                        nullable: true
                                      type:
                                        type: string
                                        enum:
                                          - api-token
                                          - workspace-member
                                          - system
                                          - app
                                        nullable: true
                                        description: >-
                                          The type of actor. [Read more
                                          information on actor types
                                          here](/docs/actors).
                                    example:
                                      type: workspace-member
                                      id: 50cf242c-7fa3-4cad-87d0-75b1af71c57b
                                  target_object:
                                    type: string
                                    description: >-
                                      A slug identifying the object that the
                                      referenced record belongs to.
                                    example: people
                                  target_record_id:
                                    type: string
                                    format: uuid
                                    description: A UUID to identify the referenced record.
                                    example: 891dcbfc-9141-415d-9b2a-2238a6cc012d
                                  attribute_type:
                                    type: string
                                    enum:
                                      - record-reference
                                    description: The attribute type of the value.
                                    example: record-reference
                                required:
                                  - active_from
                                  - active_until
                                  - created_by_actor
                                  - target_object
                                  - target_record_id
                                  - attribute_type
                                additionalProperties: false
                            company:
                              type: array
                              items:
                                type: object
                                properties:
                                  active_from:
                                    type: string
                                    format: date-time
                                    description: >-
                                      The point in time at which this value was
                                      made "active". `active_from` can be
                                      considered roughly analogous to
                                      `created_at`.
                                    example: '2023-01-01T15:00:00.000000000Z'
                                  active_until:
                                    type:
                                      - string
                                      - 'null'
                                    format: date-time
                                    description: >-
                                      The point in time at which this value was
                                      deactivated. If `null`, the value is
                                      active.
                                    example: '2023-01-01T15:00:00.000000000Z'
                                  created_by_actor:
                                    type: object
                                    description: The actor that created this value.
                                    properties:
                                      id:
                                        type: string
                                        description: An ID to identify the actor.
                                        nullable: true
                                      type:
                                        type: string
                                        enum:
                                          - api-token
                                          - workspace-member
                                          - system
                                          - app
                                        nullable: true
                                        description: >-
                                          The type of actor. [Read more
                                          information on actor types
                                          here](/docs/actors).
                                    example:
                                      type: workspace-member
                                      id: 50cf242c-7fa3-4cad-87d0-75b1af71c57b
                                  target_object:
                                    type: string
                                    description: >-
                                      A slug identifying the object that the
                                      referenced record belongs to.
                                    example: people
                                  target_record_id:
                                    type: string
                                    format: uuid
                                    description: A UUID to identify the referenced record.
                                    example: 891dcbfc-9141-415d-9b2a-2238a6cc012d
                                  attribute_type:
                                    type: string
                                    enum:
                                      - record-reference
                                    description: The attribute type of the value.
                                    example: record-reference
                                required:
                                  - active_from
                                  - active_until
                                  - created_by_actor
                                  - target_object
                                  - target_record_id
                                  - attribute_type
                                additionalProperties: false
                            avatar_url:
                              type: array
                              items:
                                type: object
                                properties:
                                  active_from:
                                    type: string
                                    format: date-time
                                    description: >-
                                      The point in time at which this value was
                                      made "active". `active_from` can be
                                      considered roughly analogous to
                                      `created_at`.
                                    example: '2023-01-01T15:00:00.000000000Z'
                                  active_until:
                                    type:
                                      - string
                                      - 'null'
                                    format: date-time
                                    description: >-
                                      The point in time at which this value was
                                      deactivated. If `null`, the value is
                                      active.
                                    example: '2023-01-01T15:00:00.000000000Z'
                                  created_by_actor:
                                    type: object
                                    description: The actor that created this value.
                                    properties:
                                      id:
                                        type: string
                                        description: An ID to identify the actor.
                                        nullable: true
                                      type:
                                        type: string
                                        enum:
                                          - api-token
                                          - workspace-member
                                          - system
                                          - app
                                        nullable: true
                                        description: >-
                                          The type of actor. [Read more
                                          information on actor types
                                          here](/docs/actors).
                                    example:
                                      type: workspace-member
                                      id: 50cf242c-7fa3-4cad-87d0-75b1af71c57b
                                  value:
                                    type: string
                                    description: >-
                                      A raw text field. Values are limited to
                                      10MB.
                                    example: >-
                                      Lorem ipsum dolor sit amet, consectetur
                                      adipiscing elit, sed do eiusmod tempor
                                      incididunt ut labore et dolore magna
                                      aliqua.
                                  attribute_type:
                                    type: string
                                    enum:
                                      - text
                                    description: The attribute type of the value.
                                    example: text
                                required:
                                  - active_from
                                  - active_until
                                  - created_by_actor
                                  - value
                                  - attribute_type
                                additionalProperties: false
                          description: >-
                            An object with `attribute_slug` keys, and an array
                            of value objects as the values. Attributes slugs
                            (for example `workspace_id` or `name`) can be used,
                            including custom attribute slugs.
                          example:
                            workspace_id:
                              - active_from: '2023-01-01T15:00:00.000000000Z'
                                active_until: null
                                created_by_actor:
                                  type: system
                                  id: null
                                value: '123'
                                attribute_type: text
                            name:
                              - active_from: '2023-01-01T15:00:00.000000000Z'
                                active_until: null
                                created_by_actor:
                                  type: system
                                  id: null
                                value: Fundstack
                                attribute_type: text
                            users:
                              - active_from: '2023-01-01T15:00:00.000000000Z'
                                active_until: null
                                created_by_actor:
                                  type: system
                                  id: null
                                target_object: users
                                target_record_id: 5e3fb280-007b-495a-a530-9354bde01de1
                                attribute_type: record-reference
                            company:
                              - active_from: '2023-01-01T15:00:00.000000000Z'
                                active_until: null
                                created_by_actor:
                                  type: system
                                  id: null
                                target_object: companies
                                target_record_id: 99a03ff3-0435-47da-95cc-76b2caeb4dab
                                attribute_type: record-reference
                            avatar_url:
                              - active_from: '2023-01-01T15:00:00.000000000Z'
                                active_until: null
                                created_by_actor:
                                  type: system
                                  id: null
                                value: https://example.com/avatar.png
                                attribute_type: text
                      required:
                        - id
                        - created_at
                        - web_url
                        - values
                required:
                  - data
                description: Success
        '400':
          description: Bad Request
          content:
            application/json:
              schema:
                type: object
                properties:
                  status_code:
                    type: number
                    enum:
                      - 400
                  type:
                    type: string
                    enum:
                      - invalid_request_error
                  code:
                    type: string
                    enum:
                      - filter_error
                  message:
                    type: string
                    example: Error in filter.
                required:
                  - status_code
                  - type
                  - code
                  - message
                description: Bad Request
        '404':
          description: Not Found
          content:
            application/json:
              schema:
                type: object
                properties:
                  status_code:
                    type: number
                    enum:
                      - 404
                  type:
                    type: string
                    enum:
                      - invalid_request_error
                  code:
                    type: string
                    enum:
                      - not_found
                  message:
                    type: string
                    example: The referenced object was not found.
                required:
                  - status_code
                  - type
                  - code
                  - message
                description: Not Found
      security:
        - oauth2:
            - record_permission:read
            - object_configuration:read
components:
  securitySchemes:
    oauth2:
      type: oauth2
      description: This API uses OAuth 2.0 with the authorization code grant flow.
      flows:
        authorizationCode:
          authorizationUrl: https://app.attio.com/authorize
          tokenUrl: https://app.attio.com/oauth/token
          scopes:
            user_management:read: View workspace members.
            user_management:read-write: View workspace members.
            record_permission:read: View, and optionally write, records.
            record_permission:read-write: View, and optionally write, records.
            object_configuration:read: >-
              View, and optionally write, the configuration and attributes of
              objects.
            object_configuration:read-write: >-
              View, and optionally write, the configuration and attributes of
              objects.
            list_entry:read: View, and optionally write, the entries in a list.
            list_entry:read-write: View, and optionally write, the entries in a list.
            list_configuration:read: >-
              View, and optionally write, the configuration and attributes of
              lists.
            list_configuration:read-write: >-
              View, and optionally write, the configuration and attributes of
              lists.
            public_collection:read: >-
              View, and optionally write, both the settings and information
              within public collections.
            public_collection:read-write: >-
              View, and optionally write, both the settings and information
              within public collections.
            private_collection:read: >-
              View, and optionally modify, both the settings and information of
              all collections within the workspace, regardless of their access
              settings.
            private_collection:read-write: >-
              View, and optionally modify, both the settings and information of
              all collections within the workspace, regardless of their access
              settings.
            comment:read: View comments (and threads), and optionally write comments.
            comment:read-write: View comments (and threads), and optionally write comments.
            task:read: View, and optionally write, tasks.
            task:read-write: View, and optionally write, tasks.
            note:read: View, and optionally write, notes.
            note:read-write: View, and optionally write, notes.
            meeting:read: View, and optionally write, meetings.
            meeting:read-write: View, and optionally write, meetings.
            call_recording:read: >-
              View, and optionally write, call recordings, transcripts and
              speakers for meetings.
            call_recording:read-write: >-
              View, and optionally write, call recordings, transcripts and
              speakers for meetings.
            webhook:read: View, and optionally manage, webhooks.
            webhook:read-write: View, and optionally manage, webhooks.
            file:read: View, and upload files.
            file:read-write: View, and upload files.

````