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

# Get test entities by test ID

> Gets a list of tested items (entities) for a test by test ID. An entity is a tested item that can have its own outcome.
For example, for a test that makes sure that all S3 buckets are versioned, an individual S3 bucket would be an entity.



## OpenAPI

````yaml /reference/manage-vanta.json get /tests/{testId}/entities
openapi: 3.0.0
info:
  title: Manage Vanta
  version: 1.0.0
  description: >-
    The REST API lets customers query and mutate Vanta's data. Use this API to
    automate bulk actions, query data for custom workflows and dashboards, and
    bolster your security operations


    **Note for Vanta Gov (FedRAMP) customers:** Select `Vanta Gov (FedRAMP)`
    from the server dropdown to issue requests against
    `https://api.vanta-gov.com`. The OAuth token URL shown below defaults to the
    commercial host — replace it with `https://api.vanta-gov.com/oauth/token`.
  termsOfService: https://www.vanta.com/terms
  license:
    name: UNLICENSED
  contact:
    name: API Support
    url: https://help.vanta.com/
    email: support@vanta.com
servers:
  - url: https://api.vanta.com/v1
    description: Vanta (Commercial)
  - url: https://api.vanta-gov.com/v1
    description: Vanta Gov (FedRAMP)
security: []
paths:
  /tests/{testId}/entities:
    get:
      tags:
        - Tests
      summary: Get test entities by test ID
      description: >-
        Gets a list of tested items (entities) for a test by test ID. An entity
        is a tested item that can have its own outcome.

        For example, for a test that makes sure that all S3 buckets are
        versioned, an individual S3 bucket would be an entity.
      operationId: GetTestEntities
      parameters:
        - in: path
          name: testId
          required: true
          schema:
            type: string
          example: aws-account-access-removed-on-termination
        - description: |-
            The status of the test entities. Defaults to FAILING.
            Possible values: FAILING, DEACTIVATED
          in: query
          name: entityStatus
          required: false
          schema:
            $ref: '#/components/schemas/EntityStatus'
        - in: query
          name: pageSize
          required: false
          schema:
            $ref: '#/components/schemas/PageSize'
        - in: query
          name: pageCursor
          required: false
          schema:
            $ref: '#/components/schemas/PageCursor'
      responses:
        '200':
          description: Ok
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/PaginatedResponse_TestResourceEntity_'
              examples:
                Example 1:
                  value:
                    results:
                      pageInfo:
                        hasNextPage: false
                        hasPreviousPage: false
                        endCursor: YXJyYXljb25uZWN0aW9uOjA=
                        startCursor: YXJyYXljb25uZWN0aW9uOjE=
                      data:
                        - id: 65fc81a3359c8508c9af880f
                          entityStatus: FAILING
                          displayName: account-123456789012
                          responseType: AWS account
                          deactivatedReason: null
                          lastUpdatedDate: '2024-06-18T20:17:38.463Z'
                          createdDate: '2024-06-18T20:17:38.463Z'
      security:
        - bearerAuth: []
components:
  schemas:
    EntityStatus:
      enum:
        - FAILING
        - DEACTIVATED
      type: string
    PageSize:
      type: integer
      format: int32
      default: 10
      description: >-
        Controls the maximum number of items returned in one response from the
        API.
      minimum: 1
      maximum: 100
    PageCursor:
      type: string
      description: >-
        A marker or pointer, telling the API where to start fetching items for
        the subsequent page in a paginated dataset.

        Note that the requested page will not include the item that corresponds
        to this cursor but will start from the one immediately

        after this cursor.
    PaginatedResponse_TestResourceEntity_:
      properties:
        results:
          properties:
            data:
              items:
                $ref: '#/components/schemas/TestResourceEntity'
              type: array
            pageInfo:
              $ref: '#/components/schemas/PageInfo'
          required:
            - data
            - pageInfo
          type: object
      required:
        - results
      type: object
      additionalProperties: false
    TestResourceEntity:
      properties:
        id:
          type: string
          description: The identifier for the entity.
        entityStatus:
          $ref: '#/components/schemas/EntityStatus'
          description: |-
            The status of the entity.
            Supports either FAILING or DEACTIVATED entities.
        displayName:
          type: string
          description: The display name of the entity.
        responseType:
          type: string
          description: The response type of the entity.
        deactivatedReason:
          type: string
          nullable: true
          description: The reason for deactivation.
        lastUpdatedDate:
          type: string
          format: date-time
          description: |-
            The date of the last update to the test entity.
            Falls back to the test run date if there is no remediation timeline.
        createdDate:
          type: string
          format: date-time
          description: |-
            The date where the test entity was first detected.
            Falls back to the test run date if there is no remediation timeline.
      required:
        - id
        - entityStatus
        - displayName
        - responseType
        - deactivatedReason
        - lastUpdatedDate
        - createdDate
      type: object
      additionalProperties: false
    PageInfo:
      description: Provides information about the pagination of a dataset.
      properties:
        endCursor:
          type: string
          nullable: true
          description: >-
            The cursor that points to the end of the current page, or null if
            there is no such cursor.
        hasNextPage:
          type: boolean
          description: Indicates if there is another page after the current page.
        hasPreviousPage:
          type: boolean
          description: Indicates if there is a page before the current page.
        startCursor:
          type: string
          nullable: true
          description: >-
            The cursor that points to the start of the current page, or null if
            there is no such cursor.
      required:
        - endCursor
        - hasNextPage
        - hasPreviousPage
        - startCursor
      type: object
      additionalProperties: false
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer

````