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

# Search enrollees

> People enrolled in the campaign with their status, current step, next step time, opens, clicks and reply intent. Filter by status group, person, job, enrollment batch, source, enrollment date, current step, reply intent, opens, clicks, or name and email; sort by enrollment date, name, status, next step time, opens or clicks. Needs `campaigns:read`.



## OpenAPI

````yaml /api-reference/openapi-v1.json post /v1/campaigns/{id}/enrollments/search
openapi: 3.1.0
info:
  title: Stardex API (v1)
  version: 1.0.0
  description: >-
    Stardex ATS API — manage candidates, jobs, companies, and recruiting
    workflows.
servers:
  - url: https://api.stardex.ai
    description: Production API server
security:
  - bearerAuth: []
tags:
  - name: Persons
    description: Manage person records — contacts, work history, and custom fields.
  - name: Jobs
    description: Manage job postings — pipeline stages, team members, and custom fields.
  - name: Candidates
    description: Manage candidate records and pipeline stage transitions.
  - name: Companies
    description: Browse and retrieve company records.
  - name: Lists
    description: Create, search, and retrieve saved person and company lists.
  - name: Person Activities
    description: Create and manage activity records (notes, emails, meetings) for persons.
  - name: Team Members
    description: List team members for use in search filters and assignments.
  - name: Custom Fields
    description: Retrieve custom field definitions and tag options for search filters.
  - name: Campaigns
    description: >-
      Create and edit email campaigns, enroll people through enrollment batches,
      and manage who is enrolled.
paths:
  /v1/campaigns/{id}/enrollments/search:
    post:
      tags:
        - Campaigns
      summary: Search enrollees
      description: >-
        People enrolled in the campaign with their status, current step, next
        step time, opens, clicks and reply intent. Filter by status group,
        person, job, enrollment batch, source, enrollment date, current step,
        reply intent, opens, clicks, or name and email; sort by enrollment date,
        name, status, next step time, opens or clicks. Needs `campaigns:read`.
      operationId: searchCampaignEnrollments
      parameters:
        - schema:
            type: string
            format: uuid
            description: Campaign ID.
          required: true
          description: Campaign ID.
          name: id
          in: path
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/EnrollmentsSearchBody'
            example:
              status: running
              batch_id: eb8d2f41-3c7a-4e19-b5d2-7f0a1c9e6b34
              sort_by: next_step_at
              sort_order: asc
      responses:
        '200':
          description: Enrollees found
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/EnrollmentsSearchResponse'
              example:
                success: true
                data:
                  - id: e7b1d3f5-9a2c-4e6b-8d0f-3a5c7e9b1d42
                    person_id: 2f6b9d1e-4a8c-4e3f-b7d2-1c5a9e3b7f40
                    name: Sam Patel
                    email: sam@gmail.com
                    status: active
                    status_group: running
                    from_email: riya@acmetalent.com
                    sender_team_member_id: 7c1e4a9b-3d6f-4b2e-8a5c-9f1d3b7e5a20
                    job_id: b21d7e4a-5c9f-4e3b-a1d6-8f2c4e7b9a13
                    enrolled_at: '2026-10-13T11:31:05.000Z'
                    current_step: 2
                    next_step_at: '2026-10-22T09:14:00.000Z'
                    opens: 0
                    clicks: 1
                    reply_intent: null
                    batch_id: eb8d2f41-3c7a-4e19-b5d2-7f0a1c9e6b34
                    source: api
                meta:
                  total: 1
                  offset: 0
                  limit: 100
        '400':
          description: Validation error
          content:
            application/json:
              schema:
                type: object
                properties:
                  success:
                    type: boolean
                    enum:
                      - false
                    description: Always false for error responses.
                  error:
                    type: object
                    properties:
                      code:
                        type: string
                        description: >-
                          Machine-readable error code (e.g. "VALIDATION_ERROR",
                          "NOT_FOUND").
                      message:
                        type: string
                        description: Human-readable error description.
                      details:
                        type: object
                        additionalProperties: {}
                        description: >-
                          Extra facts about the error when they help you fix it,
                          such as a limit and when it resets.
                    required:
                      - code
                      - message
                required:
                  - success
                  - error
        '403':
          description: No access to campaigns, or the API key lacks the permission
          content:
            application/json:
              schema:
                type: object
                properties:
                  success:
                    type: boolean
                    enum:
                      - false
                    description: Always false for error responses.
                  error:
                    type: object
                    properties:
                      code:
                        type: string
                        description: >-
                          Machine-readable error code (e.g. "VALIDATION_ERROR",
                          "NOT_FOUND").
                      message:
                        type: string
                        description: Human-readable error description.
                      details:
                        type: object
                        additionalProperties: {}
                        description: >-
                          Extra facts about the error when they help you fix it,
                          such as a limit and when it resets.
                    required:
                      - code
                      - message
                required:
                  - success
                  - error
        '404':
          description: Resource not found
          content:
            application/json:
              schema:
                type: object
                properties:
                  success:
                    type: boolean
                    enum:
                      - false
                    description: Always false for error responses.
                  error:
                    type: object
                    properties:
                      code:
                        type: string
                        description: >-
                          Machine-readable error code (e.g. "VALIDATION_ERROR",
                          "NOT_FOUND").
                      message:
                        type: string
                        description: Human-readable error description.
                      details:
                        type: object
                        additionalProperties: {}
                        description: >-
                          Extra facts about the error when they help you fix it,
                          such as a limit and when it resets.
                    required:
                      - code
                      - message
                required:
                  - success
                  - error
        '500':
          description: Internal server error
          content:
            application/json:
              schema:
                type: object
                properties:
                  success:
                    type: boolean
                    enum:
                      - false
                    description: Always false for error responses.
                  error:
                    type: object
                    properties:
                      code:
                        type: string
                        description: >-
                          Machine-readable error code (e.g. "VALIDATION_ERROR",
                          "NOT_FOUND").
                      message:
                        type: string
                        description: Human-readable error description.
                      details:
                        type: object
                        additionalProperties: {}
                        description: >-
                          Extra facts about the error when they help you fix it,
                          such as a limit and when it resets.
                    required:
                      - code
                      - message
                required:
                  - success
                  - error
components:
  schemas:
    EnrollmentsSearchBody:
      type: object
      properties:
        offset:
          type:
            - integer
            - 'null'
          minimum: 0
          default: 0
          description: Records to skip for pagination. Defaults to 0.
        limit:
          type: integer
          minimum: 1
          maximum: 100
          default: 100
          description: Max records per page (1–100). Defaults to 100.
        status:
          type: string
          enum:
            - running
            - awaiting_task
            - replied
            - meeting_booked
            - bounced
            - completed
            - stopped
          description: >-
            Only people in this status group. See GET
            /v1/campaigns/enrollment-statuses.
        person_id:
          type: string
          format: uuid
          description: Only enrollments of this person.
        job_id:
          type: string
          format: uuid
          description: Only people enrolled with this job.
        batch_id:
          type: string
          format: uuid
          description: Only people enrolled by this enrollment batch.
        source:
          type: string
          enum:
            - api
            - mcp
            - copilot
            - app
          description: >-
            Only people enrolled through an enrollment batch from this source:
            api (an API key), mcp (an AI assistant connected over MCP), copilot
            (Ask Dex) or app (a signed-in user calling the API). People enrolled
            in the Stardex app have no source and are left out.
        enrolled_after:
          type: string
          format: date-time
          description: Only people enrolled at or after this time.
        enrolled_before:
          type: string
          format: date-time
          description: Only people enrolled at or before this time.
        current_step:
          type: integer
          minimum: 1
          maximum: 20
          description: >-
            Only people currently on this step, counting from 1. Only running
            people have a current step.
        reply_intent:
          type: string
          enum:
            - positive
            - neutral
            - negative
          description: >-
            Only people whose reply was read as positive (interested), neutral
            or negative (not interested).
        min_opens:
          type: integer
          minimum: 0
          maximum: 32767
          description: Only people who opened the emails at least this many times.
        max_opens:
          type: integer
          minimum: 0
          maximum: 32767
          description: >-
            Only people who opened the emails at most this many times. 0 finds
            people who never opened, including bounced people.
        min_clicks:
          type: integer
          minimum: 0
          maximum: 32767
          description: Only people who clicked links at least this many times.
        max_clicks:
          type: integer
          minimum: 0
          maximum: 32767
          description: >-
            Only people who clicked links at most this many times. 0 finds
            people who never clicked.
        search:
          type: string
          minLength: 1
          maxLength: 200
          description: Only people whose name or email contains this text.
        sort_by:
          type: string
          enum:
            - enrolled_at
            - name
            - status
            - next_step_at
            - opens
            - clicks
          default: enrolled_at
          description: Defaults to enrolled_at.
        sort_order:
          type: string
          enum:
            - asc
            - desc
          default: desc
          description: Defaults to desc.
    EnrollmentsSearchResponse:
      type: object
      properties:
        success:
          type: boolean
          enum:
            - true
        data:
          type: array
          items:
            $ref: '#/components/schemas/CampaignEnrollment'
        meta:
          type: object
          properties:
            total:
              type: number
              description: Total matching records across all pages.
            offset:
              type: number
              description: Current pagination offset.
            limit:
              type: number
              description: Page size used for this request.
          required:
            - total
            - offset
            - limit
      required:
        - success
        - data
        - meta
    CampaignEnrollment:
      type: object
      properties:
        id:
          type: string
          format: uuid
        person_id:
          type: string
          format: uuid
        name:
          type:
            - string
            - 'null'
        email:
          type:
            - string
            - 'null'
        status:
          type: string
          description: >-
            Detailed status: active, pending, replied, event_scheduled, bounced,
            exited, stopped, cancelled, failed or access_revoked. status_group
            groups these.
        status_group:
          type:
            - string
            - 'null'
          enum:
            - running
            - awaiting_task
            - replied
            - meeting_booked
            - bounced
            - completed
            - stopped
          description: >-
            The status group of status. People held by a task step show as
            running or bounced here; search with status awaiting_task to find
            them.
        from_email:
          type:
            - string
            - 'null'
        sender_team_member_id:
          type:
            - string
            - 'null'
          format: uuid
        job_id:
          type:
            - string
            - 'null'
          format: uuid
        enrolled_at:
          type: string
        current_step:
          type:
            - integer
            - 'null'
          description: 1-based step the person is on, while running.
        next_step_at:
          type:
            - string
            - 'null'
        opens:
          type: integer
        clicks:
          type: integer
        reply_intent:
          type:
            - string
            - 'null'
          enum:
            - positive
            - neutral
            - negative
          description: >-
            How their reply was read: positive (interested), neutral or negative
            (not interested). null until they reply.
        batch_id:
          type:
            - string
            - 'null'
          format: uuid
        source:
          type:
            - string
            - 'null'
          enum:
            - api
            - mcp
            - copilot
            - app
          description: >-
            Where the enrollment batch that enrolled them was made: api (an API
            key), mcp (an AI assistant connected over MCP), copilot (Ask Dex) or
            app (a signed-in user calling the API). null for people enrolled in
            the Stardex app.
      required:
        - id
        - person_id
        - name
        - email
        - status
        - status_group
        - from_email
        - sender_team_member_id
        - job_id
        - enrolled_at
        - current_step
        - next_step_at
        - opens
        - clicks
        - reply_intent
        - batch_id
        - source
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      bearerFormat: JWT
      description: >-
        Authenticate with a Bearer token: API key, OAuth token, or session
        token.

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.