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

# List census status

> List retirement plans with census status information for a specific plan year. Filters by search, PYE, client, type, tags, status, census status, and payroll status. Includes client information and plan details.



## OpenAPI

````yaml /api-reference/cx/swagger.json post /packages/retirement/participants/{py}/_census_status
openapi: 3.0.0
info:
  description: CX API.
  title: CX API
  contact:
    name: API Support
    url: https://stax.ai
    email: support@stax.ai
  version: '1.0'
servers:
  - url: https://api.cx.stax.ai
security: []
paths:
  /packages/retirement/participants/{py}/_census_status:
    post:
      tags:
        - packages
      summary: List census status
      description: >-
        List retirement plans with census status information for a specific plan
        year. Filters by search, PYE, client, type, tags, status, census status,
        and payroll status. Includes client information and plan details.
      parameters:
        - description: Plan year
          name: py
          in: path
          required: true
          schema:
            type: integer
      requestBody:
        content:
          application/json:
            schema:
              $ref: >-
                #/components/schemas/pkg_routes_packages_retirement_participants.CensusStatusRequest
        description: Census status request with filters, sort, and pagination
        required: true
      responses:
        '200':
          description: List of plans with census status
          content:
            application/json:
              schema:
                $ref: >-
                  #/components/schemas/pkg_routes_packages_retirement_participants.CensusStatusResponse
        '400':
          description: Bad request - invalid plan year or request body
          content:
            application/json:
              schema:
                type: object
                additionalProperties: true
        '500':
          description: Internal server error
          content:
            application/json:
              schema:
                type: object
                additionalProperties: true
      security:
        - ApiKeyAuth: []
components:
  schemas:
    pkg_routes_packages_retirement_participants.CensusStatusRequest:
      type: object
      properties:
        filters:
          $ref: >-
            #/components/schemas/pkg_routes_packages_retirement_participants.CensusStatusFilters
        page:
          $ref: '#/components/schemas/types.ListPagination'
        sort:
          $ref: '#/components/schemas/types.ListSort'
    pkg_routes_packages_retirement_participants.CensusStatusResponse:
      type: object
      properties:
        clients:
          type: array
          items:
            $ref: '#/components/schemas/types.Client'
        plans:
          type: array
          items:
            $ref: '#/components/schemas/types.RetirementPlan'
        total:
          type: integer
    pkg_routes_packages_retirement_participants.CensusStatusFilters:
      type: object
      properties:
        census_status:
          description: Census Status
          type: array
          items:
            type: string
        client:
          description: Client IDs
          type: array
          items:
            type: string
        payroll_status:
          description: Payroll Status
          type: array
          items:
            type: string
        pye: {}
        search:
          description: Plan Name/Code
          type: string
        status:
          description: Plan Status
          type: array
          items:
            type: string
        tags:
          description: Client Tags
          type: array
          items:
            type: string
        type:
          description: Plan Types
          type: array
          items:
            type: string
    types.ListPagination:
      type: object
      properties:
        limit:
          type: integer
        skip:
          type: integer
    types.ListSort:
      type: object
      properties:
        field:
          type: string
        last: {}
        order:
          type: integer
    types.Client:
      type: object
      properties:
        _id:
          type: string
        activity:
          type: array
          items:
            $ref: '#/components/schemas/types.Activity'
        address:
          type: array
          items:
            $ref: '#/components/schemas/types.Address'
        allow_multiple_payrolls:
          type: boolean
        assignee_tasks:
          type: array
          items:
            $ref: '#/components/schemas/types.AssigneeTasks'
        assignees:
          type: array
          items:
            $ref: '#/components/schemas/types.Assignee'
        billing:
          description: >-
            Billing for services the team provides to this company and its
            plans.
          allOf:
            - $ref: '#/components/schemas/types.ClientBilling'
        billing_list_metrics:
          $ref: '#/components/schemas/types.BillingListMetrics'
        business_type:
          description: Business details
          type: string
        census_collection_columns:
          description: >-
            CensusCollectionColumns overrides the team default. Nil means
            inherit.
          type: array
          items:
            $ref: '#/components/schemas/sharedtypes.CensusColumnKey'
        census_status:
          type: string
        census_task:
          type: string
        comments:
          type: array
          items:
            $ref: '#/components/schemas/types.Comment'
        contacts:
          type: array
          items:
            $ref: '#/components/schemas/types.ClientContact'
        created_at:
          type: string
        deals:
          type: array
          items:
            $ref: '#/components/schemas/types.Deal'
        deleted_at:
          type: string
        directory:
          type: string
        efast:
          description: EFAST
          allOf:
            - $ref: '#/components/schemas/types.Efast'
        ein:
          type: string
        ein_normalized:
          description: >-
            EINNormalized is sharedtypes.NormalizeEIN(EIN): 9 digits, or empty
            when

            EIN is blank or malformed. Written with every EIN change; match on
            this.
          type: string
        employees:
          type: integer
        external:
          type: array
          items:
            $ref: '#/components/schemas/types.ExternalContact'
        fields:
          type: array
          items:
            $ref: '#/components/schemas/types.Field'
        financial_advisor:
          $ref: '#/components/schemas/types.Person'
        fye:
          description: Fiscal year end
          type: string
        history:
          type: array
          items:
            $ref: '#/components/schemas/types.ClientSummary'
        ignore_emails:
          type: boolean
        last_follow_up:
          description: Automated reminders
          type: string
        locations:
          type: array
          items:
            $ref: '#/components/schemas/types.Location'
        meetings:
          type: array
          items:
            $ref: '#/components/schemas/types.Meeting'
        messages:
          type: array
          items:
            $ref: '#/components/schemas/types.Message'
        n_active_projects:
          type: integer
        n_plans:
          type: integer
        naics_code:
          type: string
        name:
          type: string
        notes:
          type: string
        notices:
          type: array
          items:
            $ref: '#/components/schemas/types.NoticeProgress'
        payroll:
          description: Payroll
          allOf:
            - $ref: '#/components/schemas/types.PayrollConfig'
        payroll_status:
          type: string
        phone:
          type: string
        plan_consultant:
          $ref: '#/components/schemas/types.Person'
        plans:
          type: array
          items:
            $ref: '#/components/schemas/types.RetirementPlan'
        primary_contact:
          description: Resolved list/table cells (not stored)
          allOf:
            - $ref: '#/components/schemas/types.Person'
        primary_id:
          type: string
        primary_team:
          description: >-
            Cross-team collaboration

            When collaborations for clients/plans are accepted, the resources
            are copied over to the team that accepted the collaboration.

            The clients/plans will have unique IDs but will be linked to the
            original client/plan to maintain a 2-way sync.
          type: string
        primary_team_name:
          description: >-
            If the above properties are nil or omitted, the client/plan is owned
            by the team that created it.
          type: string
        projects:
          type: array
          items:
            $ref: '#/components/schemas/types.Project'
        pulse:
          $ref: '#/components/schemas/types.Pulse'
        pulse_total:
          description: For returning when loading
          type: integer
        shared:
          type: string
        shared_folders:
          type: array
          items:
            $ref: '#/components/schemas/stax_ai_cx_utils_types.File'
        skipped_census_fields:
          description: Census Scrubbing Config
          type: array
          items:
            type: string
        status:
          type: string
        suggested_tasks:
          type: array
          items:
            type: string
        summary:
          type: array
          items:
            type: string
        summary_for_client:
          type: array
          items:
            type: string
        summary_stale:
          type: boolean
        tags:
          type: array
          items:
            type: string
        tasks:
          type: array
          items:
            $ref: '#/components/schemas/types.Task'
        team:
          type: string
        total_value:
          type: number
        view:
          type: string
        website:
          type: string
        won_value:
          description: Calculated values
          type: number
    types.RetirementPlan:
      type: object
      properties:
        _id:
          type: string
        accounts:
          description: Investment accounts
          type: array
          items:
            $ref: '#/components/schemas/types.InvestmentAccount'
        activity:
          description: For returning when loading
          type: array
          items:
            $ref: '#/components/schemas/types.Activity'
        assignee_tasks:
          type: array
          items:
            $ref: '#/components/schemas/types.AssigneeTasks'
        audit_requested_at:
          description: Audit
          type: string
        billing:
          $ref: '#/components/schemas/types.PlanBilling'
        billing_list_metrics:
          $ref: '#/components/schemas/types.BillingListMetrics'
        bond:
          type: number
        carrier:
          type: string
        client:
          type: string
        client_name:
          description: Resolved list/table cells (not stored)
          type: string
        client_pulse:
          $ref: '#/components/schemas/types.Pulse'
        client_pulse_total:
          type: integer
        client_status:
          type: string
        code:
          type: string
        comments:
          type: array
          items:
            $ref: '#/components/schemas/types.Comment'
        created_at:
          type: string
        data:
          type: array
          items:
            $ref: '#/components/schemas/types.PlanYearData'
        deleted_at:
          type: string
        effective_on:
          type: string
        employees:
          type: integer
        fields:
          description: Custom fields
          type: array
          items:
            $ref: '#/components/schemas/types.Field'
        financial_advisor:
          $ref: '#/components/schemas/types.Person'
        ftw_census_grid:
          description: Very specific stuff...
          type: string
        name:
          type: string
        notes:
          type: string
        owner_id:
          type: string
        owner_team:
          description: >-
            Cross-team collaboration

            When collaborations for clients/plans are accepted, the resources
            are copied over to the team that accepted the collaboration.

            The clients/plans will have unique IDs but will be linked to the
            original client/plan to maintain a 2-way sync.
          type: string
        participants:
          description: Cached data to avoid re-computation
          type: integer
        plan_consultant:
          $ref: '#/components/schemas/types.Person'
        plan_structure:
          type: string
        plan_years:
          description: Plan year-specific projects to store details
          type: array
          items:
            $ref: '#/components/schemas/types.PlanYearProject'
        primary_contact:
          $ref: '#/components/schemas/types.Person'
        primary_team_name:
          description: >-
            If the above properties are nil or omitted, the client/plan is owned
            by the team that created it.
          type: string
        projects:
          type: array
          items:
            $ref: '#/components/schemas/types.Project'
        provisions:
          description: Provisions
          type: array
          items:
            $ref: '#/components/schemas/types.Provision'
        pye:
          description: Plan specifics
          type: string
        rk:
          description: Record-keeper
          type: object
          properties:
            _id:
              type: string
            contract_number:
              type: string
            login:
              type: string
            name:
              description: Overrides for non-supported record-keepers
              type: string
            payroll_integration_provider:
              type: string
            payroll_integration_type:
              description: Manually set payroll integration with the record-keeper
              type: string
            tpa_login:
              type: string
        sequence:
          type: integer
        status:
          type: string
        tags:
          type: array
          items:
            type: string
        tasks:
          type: array
          items:
            $ref: '#/components/schemas/types.Task'
        team:
          type: string
        template_instantiation:
          description: >-
            TemplateInstantiation records the immutable source and idempotency
            key

            used when this operational plan was created from a template.
          allOf:
            - $ref: '#/components/schemas/types.RetirementPlanTemplateInstantiation'
        totals:
          type: array
          items:
            $ref: '#/components/schemas/types.TransactionTotals'
        tye:
          description: Tax Year End
          type: string
        type:
          type: string
        view:
          type: string
    types.Activity:
      type: object
      properties:
        _id:
          type: string
        action:
          type: string
        changes:
          type: array
          items:
            $ref: '#/components/schemas/types.Change'
        client:
          type: string
        on_id:
          type: string
        on_py:
          type: integer
        on_type:
          type: string
        team:
          type: string
        timestamp:
          type: string
        user:
          type: string
    types.Address:
      type: object
      properties:
        attn:
          type: string
        city:
          type: string
        country:
          type: string
        desc:
          type: string
        state:
          type: string
        street:
          type: string
        street2:
          type: string
        unit:
          type: string
        zip:
          type: string
    types.AssigneeTasks:
      type: object
      properties:
        _id:
          type: string
        completed_tasks:
          type: integer
        projects:
          type: array
          items:
            type: string
        started_tasks:
          type: integer
        total_tasks:
          type: integer
    types.Assignee:
      type: object
      properties:
        deal:
          type: string
        hide_from_client:
          type: boolean
        plan:
          description: Is the assignee specifically tied to a plan or deal?
          type: string
        role:
          type: string
        shared:
          description: For returning
          type: boolean
        user:
          type: string
    types.ClientBilling:
      type: object
      properties:
        accounting:
          $ref: '#/components/schemas/types.ClientBillingAccounting'
        billing_contact_role:
          type: string
        currency:
          type: string
        invoice_grouping:
          type: string
        payer_client:
          type: string
        revision:
          type: integer
        status:
          type: string
        terms_days:
          type: integer
    types.BillingListMetrics:
      type: object
      properties:
        annual_recurring_revenue_minor:
          type: integer
        currency:
          type: string
        fee_schedule:
          type: string
        fee_schedule_name:
          type: string
        fee_schedule_version:
          type: integer
        last_invoice:
          type: string
        next_invoice_date:
          type: string
        total_billed_minor:
          type: integer
        total_collected_minor:
          type: integer
        unbilled_minor:
          type: integer
    sharedtypes.CensusColumnKey:
      type: string
      enum:
        - first_name
        - last_name
        - ssn
        - birth_date
        - hire_date
        - terminated
        - termination_date
        - termination_reason
        - rehire_date
        - hours_worked
        - employment_type
        - employee_category
        - gross_compensation
        - statutory_compensation
        - gross_minus_exclusions
        - hpi_compensation
        - new_compensation_group
        - prevailing_wage
        - compensation_from_entry
        - pre_tax_deferral
        - roth_deferral
        - match_contribution
        - safe_harbor_match
        - qaca_match
        - safe_harbor_non_elective
        - profit_sharing
        - division_code
        - ct_group_code
      x-enum-varnames:
        - CensusColumnFirstName
        - CensusColumnLastName
        - CensusColumnSSN
        - CensusColumnBirthDate
        - CensusColumnHireDate
        - CensusColumnTerminated
        - CensusColumnTerminationDate
        - CensusColumnTerminationReason
        - CensusColumnRehireDate
        - CensusColumnHoursWorked
        - CensusColumnEmploymentType
        - CensusColumnEmployeeCategory
        - CensusColumnGrossCompensation
        - CensusColumnStatutoryCompensation
        - CensusColumnGrossMinusExclusions
        - CensusColumnHPICompensation
        - CensusColumnNewCompensationGroup
        - CensusColumnPrevailingWage
        - CensusColumnCompensationFromEntry
        - CensusColumnPreTaxDeferral
        - CensusColumnRothDeferral
        - CensusColumnMatchContribution
        - CensusColumnSafeHarborMatch
        - CensusColumnQACAMatch
        - CensusColumnSafeHarborNonElective
        - CensusColumnProfitSharing
        - CensusColumnDivisionCode
        - CensusColumnCTGroupCode
    types.Comment:
      type: object
      properties:
        _id:
          type: string
        client:
          type: string
        content:
          type: string
        deleted_at:
          type: string
        likes:
          type: array
          items:
            type: string
        on_id:
          type: string
        on_type:
          type: string
        reply_to:
          type: string
        team:
          type: string
        timestamp:
          type: string
        user:
          type: string
    types.ClientContact:
      type: object
      properties:
        contact:
          $ref: '#/components/schemas/types.Contact'
        deal:
          type: string
        ignore_emails:
          type: boolean
        inactive:
          type: boolean
        invite:
          $ref: '#/components/schemas/types.Invitation'
        plan:
          description: Are the contacts specifically tied to a plan or deal?
          type: string
        role:
          type: string
        shared:
          type: boolean
        user:
          description: For returning
          allOf:
            - $ref: '#/components/schemas/types.User'
    types.Deal:
      type: object
      properties:
        _id:
          type: string
        client:
          type: string
        close_date:
          type: string
        close_probability:
          description: Override values
          type: number
        closed_at:
          description: >-
            Set when the deal status changes to Won/Lost/Abandoned; cleared when
            reopened
          type: string
        closed_reason:
          description: >-
            Deal status is one of: "Open", "Won", "Lost", "Abandoned"

            Set when the deal is Lost or Abandoned; cleared when reopened or
            marked Won
          type: string
        closed_reason_detail:
          type: string
        created_at:
          type: string
        deleted_at:
          type: string
        ein:
          type: string
        funnel:
          type: string
        last_activity:
          type: string
        n_messages:
          type: integer
        n_tasks:
          type: integer
        name:
          type: string
        owner:
          type: string
        plan:
          type: string
        plan_number:
          type: string
        proposal_count:
          type: integer
        proposals:
          type: array
          items:
            $ref: '#/components/schemas/types.LinkedProposalSummary'
        pulse:
          description: For returning
          type: integer
        source:
          type: string
        stage:
          type: string
        status:
          type: string
        tags:
          type: array
          items:
            type: string
        team:
          type: string
        unread:
          type: boolean
        value:
          type: number
    types.Efast:
      type: object
      properties:
        admin:
          $ref: '#/components/schemas/types.EfastCreds'
        dfe:
          $ref: '#/components/schemas/types.EfastCreds'
        electronic:
          $ref: '#/components/schemas/types.EfastCreds'
        sponsor:
          $ref: '#/components/schemas/types.EfastCreds'
    types.ExternalContact:
      type: object
      properties:
        collaborator:
          description: Cross-team collaboration
          allOf:
            - $ref: '#/components/schemas/types.Collaborator'
        contact:
          $ref: '#/components/schemas/types.Contact'
        deal:
          type: string
        hide_from_client:
          type: boolean
        inactive:
          type: boolean
        plan:
          description: Are the contacts specifically tied to a plan or deal?
          type: string
        role:
          type: string
        shared:
          description: For returning
          type: boolean
    types.Field:
      type: object
      properties:
        key:
          type: string
        value: {}
    types.Person:
      type: object
      properties:
        _id:
          type: string
        email:
          type: string
        name:
          type: string
        role:
          type: string
    types.ClientSummary:
      type: object
      properties:
        _id:
          type: string
        client:
          type: string
        date:
          type: string
        factors:
          type: object
          additionalProperties:
            $ref: '#/components/schemas/types.ClientFactor'
        pulse:
          $ref: '#/components/schemas/types.Pulse'
        team:
          type: string
    types.Location:
      type: object
      properties:
        address:
          $ref: '#/components/schemas/types.Address'
        client_payroll:
          type: string
        code:
          type: string
        external_id:
          description: provider location id
          type: string
        name:
          type: string
        plan:
          description: MEP/PEP location → plan
          type: string
        source:
          description: provider | manual
          type: string
    types.Meeting:
      type: object
      properties:
        _id:
          type: string
        added_tasks:
          type: array
          items:
            type: string
        attendees:
          type: array
          items:
            $ref: '#/components/schemas/types.MeetingAttendee'
        client:
          type: string
        created_at:
          type: string
        date:
          type: string
        deleted_at:
          type: string
        duration:
          type: number
        format:
          type: string
        location:
          type: string
        notes:
          type: string
        raw_transcript:
          type: string
        tasks:
          type: array
          items:
            type: string
        team:
          type: string
        transcript:
          type: array
          items:
            $ref: '#/components/schemas/types.MeetingTranscriptSpeech'
    types.Message:
      type: object
      properties:
        _id:
          type: string
        attachments:
          type: array
          items:
            $ref: '#/components/schemas/types.Attachment'
        bcc:
          type: string
        bookmark:
          type: boolean
        brief:
          description: Single-line summary
          type: string
        cc:
          type: string
        checksum:
          description: Checksum for de-duplication
          type: string
        clients:
          description: Is this message to/from a client?
          type: array
          items:
            type: string
        created_at:
          type: string
        date:
          type: string
        deleted_at:
          type: string
        domains:
          type: array
          items:
            type: string
        draft:
          type: boolean
        from:
          type: string
        html:
          type: string
        importance:
          type: integer
        in_reply_to:
          type: string
        internal:
          description: Is this message to/from only internal users?
          type: boolean
        message_folders:
          description: >-
            MessageFolders references the `folders` catalog rows this message
            belongs to

            (by their local ObjectID) — the per-mailbox equivalent of Tags
            (which is a

            team-wide label system). Each catalog row carries the provider's
            external_id;

            storing the local _id keeps renames free and gives referential
            integrity.

            Gmail = multi-label, Outlook = single-folder; the array models both.
          type: array
          items:
            type: string
        outbox:
          description: Magical stuff
          type: boolean
        private:
          description: >-
            The private flag is used if the message is from/to only internal
            admins (regardless of how many external users) that have the
            memberships.email.private flag set.

            This prevents other users from seeing external messages that may be
            private.
          type: boolean
        read:
          type: string
        references:
          type: string
        reply:
          type: string
        requires_response:
          type: boolean
        responses:
          type: array
          items:
            type: string
        safe_for_everyone:
          type: boolean
        schedule_id:
          description: >-
            ScheduleID is the Nylas message-schedule id returned by a native
            send_at

            (scheduled) send, used to reconcile the eventual Sent-folder message
            back

            onto this row (Nylas migration, Stage 4). Mirror of
            legacytypes.Message.
          type: string
        schedule_send_at:
          description: Schedule sending this at a specific time
          type: string
        secure:
          type: boolean
        send_failed:
          description: >-
            SendFailed marks a message whose provider-side send failed (Nylas

            message.send_failed webhook — typically a scheduled send) so the UI
            can

            flag it for the user to retry. Mirror of legacytypes.Message.
          type: boolean
        send_scheduled:
          type: boolean
        send_state:
          description: >-
            SendState records the provider-reported delivery state. Mirror of
            legacytypes.Message.
          type: string
        sentiment:
          type: integer
        source:
          type: string
        source_history_id:
          type: string
        source_id:
          type: string
        subject:
          type: string
        summary:
          type: array
          items:
            type: string
        tags:
          type: array
          items:
            type: string
        tasks:
          type: array
          items:
            type: string
        team:
          type: string
        text:
          type: string
        thread:
          type: string
        to:
          type: string
        unique_key:
          type: string
        user:
          type: string
    types.NoticeProgress:
      type: object
      properties:
        _id:
          type: string
        date:
          type: string
        file:
          type: string
        name:
          type: string
        opened:
          type: integer
        total:
          type: integer
    types.PayrollConfig:
      type: object
      properties:
        active:
          type: boolean
        connect360:
          type: boolean
        connection_id:
          description: Finch Connect ID
          type: string
        credentials:
          type: string
        error:
          type: string
        frequency:
          type: string
        integration:
          type: string
        last_sync:
          type: string
        mapping:
          type: array
          items:
            $ref: '#/components/schemas/types.PayrollAPIMapping'
        message:
          type: string
        pending_reports:
          type: integer
        providers:
          type: array
          items:
            type: string
        session_expires_at:
          description: Finch Connect Session Expiry
          type: string
        session_id:
          description: Finch Connect Session ID
          type: string
        source:
          type: string
        statuses:
          type: array
          items:
            type: string
        trigger:
          description: The trigger that initiated the sync
          type: string
    types.Project:
      type: object
      properties:
        _id:
          type: string
        access:
          description: >-
            Access control - this is essentially just a list of user IDs who
            have tasks in this project that are assigned to them.

            R/W access is controlled by the individual use scopes
          type: array
          items:
            type: string
        activity:
          description: For returning when loading
          type: array
          items:
            $ref: '#/components/schemas/types.Activity'
        billing:
          $ref: '#/components/schemas/types.ProjectBilling'
        category:
          description: Category - inherited from project template (e.g. "plan_audit")
          type: string
        client:
          type: string
        client_name:
          type: string
        comments:
          type: array
          items:
            $ref: '#/components/schemas/types.Comment'
        completed_at:
          type: string
        created_at:
          description: Time tracking
          type: string
        deal:
          type: string
        deal_name:
          type: string
        deal_object:
          $ref: '#/components/schemas/types.Deal'
        deleted_at:
          type: string
        description:
          type: string
        due:
          type: string
        effective_billing_fee_item:
          description: >-
            EffectiveBillingFeeItem is resolved from a project override or its
            source template.
          type: string
        effective_billing_fee_item_name:
          type: string
        fields:
          type: array
          items:
            $ref: '#/components/schemas/types.Field'
        hours_logged:
          type: integer
        in_queue:
          type: boolean
        incomplete_tasks:
          type: integer
        lead:
          type: string
        lead_group:
          description: Queue routing
          type: string
        next:
          description: Return variables for list
          allOf:
            - $ref: '#/components/schemas/types.Task'
        plan:
          type: string
        plan_name:
          type: string
        queued_at:
          type: string
        starred:
          type: array
          items:
            type: string
        status:
          description: Status (this is based on the status of tasks within the project)
          type: string
        tags:
          type: array
          items:
            type: string
        tasks:
          type: array
          items:
            $ref: '#/components/schemas/types.Task'
        team:
          type: string
        team_wide_access:
          description: >-
            Team-wide access - if true, all team members have access to this
            project
          type: boolean
        template:
          type: string
        title:
          type: string
        total_tasks:
          type: integer
        view:
          type: string
    types.Pulse:
      type: object
      properties:
        calculated_at:
          description: Last Todo/Client calculation
          type: string
        client:
          description: 0-3
          type: integer
        messages:
          description: 0-4
          type: integer
        messages_reason:
          type: string
        override:
          description: '-2 to +2'
          type: integer
        todo:
          description: 0-3
          type: integer
    stax_ai_cx_utils_types.File:
      type: object
      properties:
        _id:
          type: string
        absolute_path:
          type: string
        access:
          type: array
          items:
            $ref: '#/components/schemas/types.FileAccess'
        activity:
          type: array
          items:
            $ref: '#/components/schemas/types.Activity'
        client:
          $ref: '#/components/schemas/types.Client'
        collaborators:
          type: array
          items:
            $ref: '#/components/schemas/types.CollaboratorAccess'
        comments:
          type: array
          items:
            $ref: '#/components/schemas/types.Comment'
        context:
          description: Context is used to process the file
          type: string
        cp_upload:
          description: >-
            If the file was uploaded by a client or collaborator, we'll have a
            client upload record for tracking notifications
          allOf:
            - $ref: '#/components/schemas/types.ExternalUpload'
        created_at:
          type: string
        created_by:
          type: string
        created_by_type:
          type: string
        deleted_at:
          type: string
        favorite:
          type: boolean
        fields:
          type: array
          items:
            $ref: '#/components/schemas/types.Field'
        form:
          $ref: '#/components/schemas/types.FormTemplate'
        hidden:
          type: boolean
        lock:
          description: For Office 365 file editing/WOPI
          allOf:
            - $ref: '#/components/schemas/types.FileLock'
        locked:
          type: boolean
        mime_type:
          type: string
        modified_at:
          type: string
        name:
          type: string
        parent:
          type: string
        path:
          description: For returning
          type: array
          items:
            $ref: '#/components/schemas/types.Parent'
        responses:
          type: array
          items:
            $ref: '#/components/schemas/types.FormResponse'
        share_root:
          type: string
        share_token:
          type: string
        size:
          type: integer
        team:
          type: string
        type:
          description: File mimetype or "folder"
          type: string
        upload_completed_at:
          type: string
        upload_keys:
          description: >-
            If this is a folder and this is set, then users can anonymously
            upload to this folder if they have the link
          type: array
          items:
            $ref: '#/components/schemas/types.UploadKey'
        url:
          description: Presigned URL to download the file
          type: string
        writeable:
          description: True if this user is able to write to the file
          type: boolean
    types.Task:
      type: object
      properties:
        _id:
          type: string
        access:
          description: >-
            Access control - this is essentially just a list of user IDs who
            have tasks the project this task belongs to that are assigned to
            them.
          type: array
          items:
            type: string
        activity:
          type: array
          items:
            $ref: '#/components/schemas/types.Activity'
        assignee:
          type: string
        automation:
          description: An automation may be used to complete the task
          type: string
        automation_config:
          type: array
          items:
            $ref: '#/components/schemas/types.Field'
        automation_data: {}
        automation_logs:
          type: array
          items:
            $ref: '#/components/schemas/types.AutomationLog'
        automation_timing:
          description: >-
            AutomationTiming, when non-nil, schedules the automation to run
            later

            instead of immediately (nil = immediate). See AutomationTiming in

            project_template.go.
          allOf:
            - $ref: '#/components/schemas/types.AutomationTiming'
        billable:
          type: boolean
        blocked_fields:
          description: >-
            BlockingFields are project field keys that must be populated before
            the

            task can be completed. Unlike FieldsToComplete, these cannot be
            overridden.
          type: array
          items:
            type: string
        client:
          type: string
        client_task_data:
          description: JSON data for the client task
          allOf:
            - $ref: '#/components/schemas/types.ClientTaskData'
        client_task_type:
          description: >-
            If this is a task for the client to do, a client task type should be
            set - eg. "Census Data Collection", "Census Data Review",
            "Participant Notices", "Fill Web or Document Form", "Testing
            Corrections", "Other"
          type: string
        completed_at:
          type: string
        created_at:
          description: Time tracking
          type: string
        deleted_at:
          type: string
        description:
          type: string
        due:
          type: string
        fields_to_complete:
          description: >-
            If the task belongs to a project, it can require collecting
            specified fields for the project
          type: array
          items:
            type: string
        flagged_at:
          description: By automation
          type: string
        in_queue:
          type: boolean
        internal_task_data:
          description: JSON data for the internal task
          allOf:
            - $ref: '#/components/schemas/types.InternalTaskData'
        internal_task_type:
          description: >-
            If this is a special type (eg. payroll mapping, form selection,
            etc.), an internal task type should be set.
          type: string
        log_completion_to:
          type: string
        log_completion_type:
          description: Log completion time to project variable?
          type: string
        meeting:
          $ref: '#/components/schemas/types.Meeting'
        message:
          description: For returning when loading
          allOf:
            - $ref: '#/components/schemas/types.Message'
        next_at:
          type: string
        notes:
          type: string
        order:
          description: If the task is part of a project, the order should be tracked
          type: integer
        plan:
          type: string
        priority:
          type: integer
        project:
          type: string
        queue_group:
          description: Queue routing
          type: string
        queued_at:
          type: string
        scheduled_at:
          description: >-
            ScheduledAt is the absolute UTC instant a scheduled automation
            should fire,

            computed once from AutomationTiming at scheduling time (ENG-8103).

            Semantics: {ScheduledAt set, StartedAt nil} = pending;

            StartedAt set = claimed/fired; AutomationTiming nil = immediate.
          type: string
        started_at:
          type: string
        suggestion:
          type: integer
        team:
          type: string
        team_wide_access:
          description: >-
            Team-wide access - if true, all team members have access to this
            project
          type: boolean
        template:
          type: string
        work_logs:
          description: Work logs
          type: array
          items:
            $ref: '#/components/schemas/types.WorkLog'
    types.InvestmentAccount:
      type: object
      properties:
        _id:
          type: string
        closed_at:
          type: string
        created_at:
          type: string
        deleted_at:
          type: string
        employee:
          type: string
        format:
          description: Data extraction format
          type: string
        name:
          description: Payee/FBO
          type: string
        notes:
          type: string
        number:
          description: Account details
          type: string
        opened_at:
          type: string
        plan:
          type: string
        provider:
          type: string
        remote_id:
          type: string
        remote_source:
          description: Reference to external system
          type: string
        status:
          type: string
        team:
          type: string
        type:
          type: string
    types.PlanBilling:
      type: object
      properties:
        accounting:
          $ref: '#/components/schemas/types.PlanBillingAccounting'
        assignments:
          type: array
          items:
            $ref: '#/components/schemas/types.PlanBillingAssignment'
        quantity_selections:
          type: array
          items:
            $ref: '#/components/schemas/types.PlanBillingQuantitySelection'
        revenue_share_override:
          $ref: '#/components/schemas/types.RevenueSharePolicyOverride'
        revision:
          type: integer
        service_end:
          type: string
        service_start:
          type: string
        service_status:
          type: string
    types.PlanYearData:
      type: object
      properties:
        assets:
          type: number
        ee_contributions:
          type: number
        er_contributions:
          type: number
        withdrawals:
          type: number
        year:
          type: integer
    types.PlanYearProject:
      type: object
      properties:
        project:
          type: string
        year:
          type: integer
    types.Provision:
      type: object
      properties:
        _id:
          type: string
        ai_provenance:
          $ref: '#/components/schemas/types.AIPlanDocumentProvenance'
        amendment:
          description: ID for amendment document
          type: string
        client:
          type: string
        created_at:
          type: string
        deleted_at:
          type: string
        document_customer_id:
          type: string
        document_provider:
          type: string
        document_provider_id:
          type: string
        effective_on:
          type: string
        effective_until:
          type: string
        parent_provision:
          description: MEPS/PEPS
          type: string
        plan:
          type: string
        raw:
          description: Raw Provisions
          type: object
          additionalProperties: true
        specs:
          description: DC Standard (401(k), 403(b), MPP)
          type: object
          additionalProperties: true
        team:
          type: string
        type:
          description: Original, Amendment, Variation
          type: string
        variables:
          description: >-
            List of keys allowed to be changed. Only parent provisions have
            variables
          type: array
          items:
            type: string
        version:
          type: string
        year:
          description: Versioning
          type: integer
    types.RetirementPlanTemplateInstantiation:
      type: object
      properties:
        created_at:
          type: string
        created_by:
          type: string
        request_key:
          type: string
        template:
          type: string
    types.TransactionTotals:
      type: object
      properties:
        ee:
          type: number
        er:
          type: number
        gc:
          type: number
        year:
          type: integer
    types.Change:
      type: object
      properties:
        data:
          type: string
        field:
          type: string
        from:
          type: string
        to:
          type: string
    types.ClientBillingAccounting:
      type: object
      properties:
        customer_id:
          type: string
        customer_version:
          type: string
        integration:
          type: string
        last_synced_at:
          type: string
        mapping_status:
          type: string
    types.Contact:
      type: object
      properties:
        _id:
          description: Unique identifier
          type: string
        address:
          $ref: '#/components/schemas/types.Address'
        client:
          $ref: '#/components/schemas/types.ShortClient'
        clients:
          description: For searching
          type: array
          items:
            $ref: '#/components/schemas/types.ClientRole'
        company:
          type: string
        confirmed:
          type: boolean
        created_at:
          type: string
        email:
          type: array
          items:
            type: string
        fields:
          type: array
          items:
            $ref: '#/components/schemas/types.Field'
        n_companies:
          type: integer
        n_deals:
          type: integer
        n_employers:
          type: integer
        n_plans:
          type: integer
        name:
          type: string
        notes:
          type: string
        phone:
          type: array
          items:
            $ref: '#/components/schemas/types.Phone'
        phone_number:
          description: >-
            Resolved list/table cells (not stored). PhoneNumber/PhoneType are
            the

            first phone on the record. The n_* counts are association totals.
          type: string
        phone_type:
          type: string
        preferred_name:
          type: string
        suffix:
          type: string
        tags:
          type: array
          items:
            type: string
        team:
          description: What team does this contact belong to?
          type: string
        title:
          type: string
    types.Invitation:
      type: object
      properties:
        _id:
          type: string
        accepted_on:
          type: string
        client:
          description: >-
            If the invitation is to join a team, the client ID is not set. If
            it's to join a client, the client ID is set
          type: string
        contact:
          description: >-
            Contact the client portal invitation was sent to, so it can follow
            that contact's email changes
          type: string
        deleted_at:
          type: string
        email:
          type: string
        from:
          description: User ID
          type: string
        last_follow_up:
          type: string
        name:
          description: Invitation user details
          type: string
        scopes:
          type: array
          items:
            type: string
        sent_on:
          type: string
        team:
          type: string
        title:
          type: string
        user:
          type: string
    types.User:
      type: object
      properties:
        _id:
          type: string
        clients:
          type: array
          items:
            $ref: '#/components/schemas/types.ClientAccess'
        community:
          description: Community role (eg. "Moderator")
          type: string
        created_on:
          type: string
        deleted_at:
          type: string
        email:
          type: string
        memberships:
          type: array
          items:
            $ref: '#/components/schemas/types.Membership'
        mfa_enabled:
          description: Is MFA enabled?
          type: boolean
        mfa_secret:
          description: The secret for MFA TOTP
          type: string
        mfa_verified_at:
          type: string
        name:
          type: string
        out_of_office:
          description: Availability for queue routing (user-level, not per-team)
          type: array
          items:
            $ref: '#/components/schemas/types.OOOWindow'
        password:
          type: string
        phone:
          type: string
        signature:
          type: string
        team:
          description: The team the user is logged in to
          type: string
        timezone:
          type: string
        validation_code:
          description: The validation code for the user
          type: string
    types.LinkedProposalSummary:
      type: object
      properties:
        _id:
          type: string
        created_at:
          type: string
        name:
          type: string
        plan_type:
          type: string
        progress:
          type: number
        status:
          type: string
        updated_at:
          type: string
    types.EfastCreds:
      type: object
      properties:
        pin:
          type: string
        user_id:
          type: string
    types.Collaborator:
      type: object
      properties:
        accepted_at:
          type: string
        cp_access:
          type: boolean
        declined_at:
          type: string
        participant_data_access_approved_at:
          type: string
        participant_data_access_approved_by:
          type: string
        participant_data_access_requested_at:
          description: Special sharing permissions for participant data access
          type: string
        read_only:
          type: boolean
        shared_at:
          type: string
        shared_by_user:
          type: string
        shared_with_email:
          type: string
        shared_with_team:
          type: string
        shared_with_user:
          type: string
    types.ClientFactor:
      type: object
      properties:
        score:
          type: number
        summary:
          type: array
          items:
            type: string
    types.MeetingAttendee:
      type: object
      properties:
        address:
          type: string
        name:
          type: string
        user:
          type: string
    types.MeetingTranscriptSpeech:
      type: object
      properties:
        speaker:
          type: string
        text:
          type: string
        timestamp:
          description: in seconds
          type: number
    types.Attachment:
      type: object
      properties:
        content_id:
          type: string
        file:
          type: string
        filename:
          type: string
        isInline:
          type: boolean
        size:
          type: integer
        source_id:
          type: string
        url:
          type: string
    types.PayrollAPIMapping:
      type: object
      properties:
        ee_pre_tax:
          type: array
          items:
            $ref: '#/components/schemas/types.PayrollAPIMappingSource'
        ee_roth:
          type: array
          items:
            $ref: '#/components/schemas/types.PayrollAPIMappingSource'
        er_match:
          type: array
          items:
            $ref: '#/components/schemas/types.PayrollAPIMappingSource'
        er_non_elective:
          type: array
          items:
            $ref: '#/components/schemas/types.PayrollAPIMappingSource'
        er_qaca_match:
          type: array
          items:
            $ref: '#/components/schemas/types.PayrollAPIMappingSource'
        er_safe_harbor_match:
          type: array
          items:
            $ref: '#/components/schemas/types.PayrollAPIMappingSource'
        er_safe_harbor_non_elective:
          type: array
          items:
            $ref: '#/components/schemas/types.PayrollAPIMappingSource'
        hpi_compensation:
          type: array
          items:
            $ref: '#/components/schemas/types.PayrollAPIMappingSource'
        ignore:
          description: >-
            Fields to ignore - if there is a new field that's not in this list,
            we will flag for review
          type: array
          items:
            type: string
        loan_repayment:
          description: >-
            Loan repayments (spec 5.10): collected into
            employee_census.loan_payments, not compensation.
          type: array
          items:
            $ref: '#/components/schemas/types.PayrollAPIMappingSource'
        plan:
          description: For each field, we take the sum of all sources
          type: string
        plan_compensation:
          type: array
          items:
            $ref: '#/components/schemas/types.PayrollAPIMappingSource'
        prevailing_wage:
          type: array
          items:
            $ref: '#/components/schemas/types.PayrollAPIMappingSource'
        statutory_compensation:
          description: This is the base salary
          type: array
          items:
            $ref: '#/components/schemas/types.PayrollAPIMappingSource'
    types.ProjectBilling:
      type: object
      properties:
        amount_override_minor:
          type: integer
        billable:
          type: boolean
        charge:
          type: string
        configuration_source:
          type: string
        contract_amount_minor:
          type: integer
        decision_at:
          type: string
        decision_by:
          type: string
        decision_reason:
          type: string
        default_quantity:
          $ref: '#/components/schemas/bson.Decimal128'
        fee_item:
          type: string
        invoice:
          type: string
        occurrence_key:
          type: string
        override_at:
          type: string
        override_by:
          type: string
        override_reason:
          type: string
        quantity:
          $ref: '#/components/schemas/bson.Decimal128'
        quantity_field_key:
          type: string
        revision:
          type: integer
        service_date:
          type: string
        status:
          type: string
    types.FileAccess:
      type: object
      properties:
        scope:
          type: string
        target:
          description: user | team | client
          type: string
        type:
          type: string
    types.CollaboratorAccess:
      type: object
      properties:
        email:
          type: string
        scope:
          type: string
        shared_at:
          type: string
        shared_by:
          type: string
        team:
          type: string
    types.ExternalUpload:
      type: object
      properties:
        client:
          type: string
        notified_at:
          type: string
        type:
          type: string
        user:
          type: string
    types.FormTemplate:
      type: object
      properties:
        _id:
          type: string
        created_at:
          type: string
        deleted_at:
          type: string
        description:
          type: string
        fields:
          type: string
        hidden:
          type: boolean
        incomplete:
          type: integer
        info:
          type: object
          additionalProperties: true
        most_recent:
          description: For returning
          type: string
        pdf:
          type: string
        public:
          type: boolean
        questions:
          type: array
          items:
            $ref: '#/components/schemas/types.FormQuestion'
        replace_pdf:
          type: boolean
        tags:
          type: array
          items:
            type: string
        team:
          type: string
        title:
          type: string
        total:
          type: integer
        type:
          type: string
    types.FileLock:
      type: object
      properties:
        expires_at:
          type: string
        key:
          type: string
        owner:
          type: string
    types.Parent:
      type: object
      properties:
        _id:
          type: string
        name:
          type: string
    types.FormResponse:
      type: object
      properties:
        _id:
          type: string
        client:
          description: If filled out by client
          type: string
        completed_at:
          type: integer
        contact:
          description: If filled out by contact
          type: string
        deleted_at:
          type: integer
        device_agent:
          type: string
        fields:
          type: string
        form:
          type: string
        ip:
          type: string
        opened_at:
          type: integer
        pdf:
          description: Keep track of responses
          type: string
        responder:
          description: If filled out by unauthenticated user
          allOf:
            - $ref: '#/components/schemas/types.FormResponder'
        responses:
          type: array
          items:
            $ref: '#/components/schemas/types.Response'
        sent_at:
          type: integer
        team:
          type: string
        user:
          type: string
    types.UploadKey:
      type: object
      properties:
        email:
          type: string
        key:
          type: string
    types.AutomationLog:
      type: object
      properties:
        code:
          description: |-
            Code is a stable machine-readable reason (e.g. "missing_fields") so
            clients can branch on it without parsing Message.
          type: string
        execution_time:
          type: number
        message:
          type: string
        timestamp:
          type: string
        traceback:
          type: string
        type:
          type: string
    types.AutomationTiming:
      type: object
      properties:
        anchor:
          type: string
        date:
          description: YYYY-MM-DD, team-local; anchor "date" only
          type: string
        run_after_days:
          description: >-
            anchor "": >= 0 after the trigger; "project_due": signed, negative
            is before
          type: integer
        run_hour:
          description: 0..23, wall-clock in the team's local timezone
          type: integer
    types.ClientTaskData:
      type: object
      properties:
        allow_skip_census_upload:
          type: string
        census_upload_instructions:
          type: string
        census_v2_employee_data_policy:
          $ref: '#/components/schemas/sharedtypes.CensusV2EmployeeDataPolicy'
        census_v2_export_field:
          type: string
        census_v2_export_file_type:
          type: string
        census_v2_flow_preset:
          $ref: '#/components/schemas/sharedtypes.CensusV2FlowPreset'
        destination:
          type: string
        download_file:
          type: string
        file_upload:
          type: string
        follow_up_interval:
          type: integer
        follow_up_to:
          type: array
          items:
            type: string
        form_file:
          type: string
        form_response:
          description: Results
          type: string
        form_template:
          type: string
        last_follow_up:
          type: string
        notice_file:
          type: string
        payroll_connect_instructions:
          type: string
        payroll_enabled:
          type: string
        payroll_upload_instructions:
          type: string
        py:
          type: string
        url:
          type: string
        w2_upload_instructions:
          type: string
    types.InternalTaskData:
      type: object
      properties:
        efast_data:
          $ref: '#/components/schemas/types.EFastData'
        form_id:
          type: string
        py:
          type: string
        task_type:
          type: string
        url:
          type: string
    types.WorkLog:
      type: object
      properties:
        _id:
          type: string
        ended_at:
          type: string
        notes:
          type: string
        started_at:
          type: string
        time_spent:
          type: integer
        user:
          type: string
    types.PlanBillingAccounting:
      type: object
      properties:
        customer_id:
          type: string
        dimension_id:
          type: string
        integration:
          type: string
        last_synced_at:
          type: string
        plan_external_id:
          type: string
    types.PlanBillingAssignment:
      type: object
      properties:
        agreement_file:
          type: string
        effective_from:
          type: string
        effective_to:
          type: string
        key:
          type: string
        override_revisions:
          type: array
          items:
            $ref: '#/components/schemas/types.PlanBillingOverrideRevision'
        schedule:
          type: string
    types.PlanBillingQuantitySelection:
      type: object
      properties:
        period:
          $ref: '#/components/schemas/types.BillingPeriod'
        purpose:
          type: string
        rule_key:
          type: string
        snapshot:
          type: string
    types.RevenueSharePolicyOverride:
      type: object
      properties:
        effective_from:
          type: string
        patches:
          type: array
          items:
            $ref: '#/components/schemas/types.BillingPatch'
        policy:
          type: string
        policy_version:
          type: integer
    types.AIPlanDocumentProvenance:
      type: object
      properties:
        coverage:
          $ref: '#/components/schemas/types.AIPlanDocumentCoverage'
        extraction_id:
          type: string
        issues:
          type: array
          items:
            $ref: '#/components/schemas/types.AIPlanDocumentReviewIssue'
        model_version:
          type: string
        prompt_version:
          type: string
        requires_review:
          type: boolean
        source_file_id:
          type: string
        source_sha256:
          type: string
        target_catalog_id:
          type: string
        target_catalog_version:
          type: string
        warnings:
          $ref: '#/components/schemas/types.AIPlanDocumentWarningSummary'
    types.ShortClient:
      type: object
      properties:
        _id:
          type: string
        name:
          type: string
    types.ClientRole:
      type: object
      properties:
        _id:
          type: string
        inactive:
          type: boolean
        name:
          type: string
        role:
          type: string
    types.Phone:
      type: object
      properties:
        number:
          type: string
        type:
          type: string
    types.ClientAccess:
      type: object
      properties:
        accepted_on:
          type: string
        client:
          type: string
        contact:
          type: string
        invited_on:
          type: string
        scopes:
          type: array
          items:
            type: string
        team:
          type: string
    types.Membership:
      type: object
      properties:
        about:
          type: string
        accepted_on:
          type: string
        api_keys:
          type: array
          items:
            $ref: '#/components/schemas/types.APIKey'
        email:
          $ref: '#/components/schemas/types.EmailConfig'
        email_signature:
          type: string
        filters:
          $ref: '#/components/schemas/types.Filters'
        invited_on:
          type: string
        preferences:
          $ref: '#/components/schemas/types.Preferences'
        scopes:
          type: array
          items:
            type: string
        starred_pages:
          type: array
          items:
            type: string
        suspended:
          type: boolean
        team:
          type: string
        title:
          type: string
        working_hours:
          description: Per-team working hours override for queue routing capacity
          allOf:
            - $ref: '#/components/schemas/types.WorkingHoursConfig'
    types.OOOWindow:
      type: object
      properties:
        end:
          type: string
        note:
          type: string
        start:
          type: string
    types.PayrollAPIMappingSource:
      type: object
      properties:
        minus:
          description: >-
            If any of these are empty, we won't look at them. At least one has
            to be set
          type: boolean
        name:
          description: The name of the source
          type: string
        type:
          description: 'The type of source: Earnings, Taxes, Contributions'
          type: string
    bson.Decimal128:
      type: object
    types.FormQuestion:
      type: object
      properties:
        _id:
          type: string
        conditions:
          type: array
          items:
            $ref: '#/components/schemas/types.Condition'
        data:
          type: object
          additionalProperties: true
        default: {}
        hint:
          type: string
        key:
          type: string
        link:
          type: string
        multiple:
          type: boolean
        on_type:
          type: string
        options:
          type: array
          items:
            type: string
        required:
          type: boolean
        title:
          type: string
        type:
          type: string
    types.FormResponder:
      type: object
      properties:
        email:
          type: string
        name:
          type: string
    types.Response:
      type: object
      properties:
        key:
          type: string
        link:
          type: string
        on_type:
          type: string
        question:
          type: string
        timestamp:
          type: string
        title:
          type: string
        type:
          type: string
        value: {}
    sharedtypes.CensusV2EmployeeDataPolicy:
      type: string
      enum:
        - any
        - payroll_or_census
        - census_only
        - census_or_w2
        - w2_only
      x-enum-varnames:
        - CensusV2EmployeeDataPolicyAny
        - CensusV2EmployeeDataPolicyPayrollOrCensus
        - CensusV2EmployeeDataPolicyCensusOnly
        - CensusV2EmployeeDataPolicyCensusOrW2
        - CensusV2EmployeeDataPolicyW2Only
    sharedtypes.CensusV2FlowPreset:
      type: string
      enum:
        - company_contacts_ownership_payroll_census
        - company_contacts_ownership
        - payroll_census_only
      x-enum-varnames:
        - CensusV2FlowPresetCompanyContactsOwnershipPayrollCensus
        - CensusV2FlowPresetCompanyContactsOwnership
        - CensusV2FlowPresetPayrollCensusOnly
    types.EFastData:
      type: object
      properties:
        attachments:
          type: array
          items: {}
        dcg_attachments:
          type: array
          items: {}
        file_names:
          type: array
          items:
            type: string
        form:
          type: string
        schedule_instances:
          type: object
          additionalProperties:
            type: array
            items: {}
        schedules:
          type: array
          items:
            type: string
    types.PlanBillingOverrideRevision:
      type: object
      properties:
        additional_rules:
          type: array
          items:
            $ref: '#/components/schemas/types.FeeScheduleRule'
        effective_from:
          type: string
        number:
          type: integer
        published_at:
          type: string
        published_by:
          type: string
        reason:
          type: string
        rule_patches:
          type: array
          items:
            $ref: '#/components/schemas/types.PlanBillingRulePatch'
        schedule_patch:
          type: array
          items:
            $ref: '#/components/schemas/types.BillingPatch'
    types.BillingPeriod:
      type: object
      properties:
        end:
          type: string
        start:
          type: string
    types.BillingPatch:
      type: object
      properties:
        path:
          type: string
        value: {}
    types.AIPlanDocumentCoverage:
      type: object
      properties:
        all:
          $ref: '#/components/schemas/types.AIPlanDocumentCoverageCount'
        catalog_id:
          type: string
        catalog_version:
          type: string
        key:
          $ref: '#/components/schemas/types.AIPlanDocumentCoverageCount'
    types.AIPlanDocumentReviewIssue:
      type: object
      properties:
        citations:
          type: array
          items:
            $ref: '#/components/schemas/types.AIPlanDocumentCitation'
        domain:
          type: string
        field:
          type: string
        group:
          type: string
        message:
          type: string
        review:
          type: string
        status:
          type: string
    types.AIPlanDocumentWarningSummary:
      type: object
      properties:
        by_domain:
          type: object
          additionalProperties:
            type: array
            items:
              type: string
        by_field:
          type: object
          additionalProperties:
            type: array
            items:
              type: string
        by_page:
          type: object
          additionalProperties:
            type: array
            items:
              type: string
        by_status:
          type: object
          additionalProperties:
            type: array
            items:
              type: string
        items:
          type: array
          items:
            $ref: '#/components/schemas/types.AIPlanDocumentWarning'
    types.APIKey:
      type: object
      properties:
        created_by:
          type: string
        created_on:
          type: string
        name:
          type: string
        secret:
          type: string
    types.EmailConfig:
      type: object
      properties:
        access_token:
          description: >-
            AccessToken/RefreshToken are the legacy provider OAuth tokens. Kept
            dormant

            during the Nylas migration for rollback safety — Nylas owns token
            refresh

            once a grant exists, so these are not written for Backend == "nylas"
            accounts.
          type: string
        address:
          type: string
        auto_reply:
          type: boolean
        auto_reply_body:
          type: string
        auto_reply_from:
          type: string
        auto_reply_subject:
          type: string
        auto_reply_to:
          type: string
        backend:
          type: string
        connected_at:
          type: string
        error:
          type: string
        errored_at:
          type: string
        grant_id:
          description: >-
            Nylas migration fields. GrantID is the Nylas grant scoping all
            per-account

            API calls; GrantStatus mirrors the Nylas grant state
            (valid|invalid|expired);

            Backend == "nylas" is the per-account switch every send/sync code
            path checks.
          type: string
        grant_status:
          type: string
        last_sync:
          type: string
        private:
          type: boolean
        provider:
          type: string
        refresh_token:
          type: string
        status:
          type: string
        sync_mutex:
          type: boolean
    types.Filters:
      type: object
      properties:
        client:
          type: object
          additionalProperties: true
        message:
          type: object
          additionalProperties: true
        plan:
          type: object
          additionalProperties: true
        project:
          type: object
          additionalProperties: true
        task:
          type: object
          additionalProperties: true
    types.Preferences:
      type: object
      properties:
        email_on_assignments:
          type: boolean
        email_on_assists:
          type: boolean
        email_on_client_actions:
          type: boolean
        email_on_client_updates:
          type: boolean
        email_on_community:
          type: boolean
        email_on_mentions:
          type: boolean
        email_on_overdue:
          type: boolean
        email_on_shared_files:
          type: boolean
    types.WorkingHoursConfig:
      type: object
      properties:
        schedule:
          type: array
          items:
            $ref: '#/components/schemas/types.WorkingHoursSchedule'
        timezone:
          type: string
        use_user_timezone:
          type: boolean
    types.Condition:
      type: object
      properties:
        expression:
          type: string
        op:
          type: string
        value:
          type: string
    types.FeeScheduleRule:
      type: object
      properties:
        basis:
          type: string
        billing_type:
          type: string
        enabled:
          type: boolean
        estimate:
          $ref: '#/components/schemas/types.FeeEstimateConfig'
        fee_item:
          type: string
        invoice_description:
          type: string
        invoice_frequency:
          type: string
        key:
          type: string
        maximum_minor:
          type: integer
        minimum_minor:
          type: integer
        pricing:
          $ref: '#/components/schemas/types.FeePricing'
        project_invoice_timing:
          type: string
        proposal_one_time:
          type: boolean
        proration:
          type: string
        quantity_policy:
          $ref: '#/components/schemas/types.FeeQuantityPolicy'
        quoted_period:
          type: string
        revenue_stream:
          type: string
        sort_order:
          type: integer
        trigger:
          type: string
    types.PlanBillingRulePatch:
      type: object
      properties:
        fields:
          type: array
          items:
            $ref: '#/components/schemas/types.BillingPatch'
        rule_key:
          type: string
    types.AIPlanDocumentCoverageCount:
      type: object
      properties:
        denominator:
          type: integer
        numerator:
          type: integer
        percent:
          type: integer
    types.AIPlanDocumentCitation:
      type: object
      properties:
        page:
          type: integer
    types.AIPlanDocumentWarning:
      type: object
      properties:
        domain:
          type: string
        field:
          type: string
        id:
          type: string
        message:
          type: string
        pages:
          type: array
          items:
            type: integer
        review:
          type: string
        status:
          type: string
    types.WorkingHoursSchedule:
      type: object
      properties:
        end_time:
          type: string
        start_time:
          type: string
        weekday:
          type: string
    types.FeeEstimateConfig:
      type: object
      properties:
        enabled:
          type: boolean
        quantity_policy:
          $ref: '#/components/schemas/types.FeeQuantityPolicy'
        true_up:
          $ref: '#/components/schemas/types.FeeTrueUpConfiguration'
    types.FeePricing:
      type: object
      properties:
        amount_minor:
          type: integer
        method:
          type: string
        tiers:
          type: array
          items:
            $ref: '#/components/schemas/types.FeePricingTier'
        unit_rate:
          $ref: '#/components/schemas/bson.Decimal128'
    types.FeeQuantityPolicy:
      type: object
      properties:
        as_of:
          type: string
        maximum_age_days:
          type: integer
        metric:
          type: string
        require_approval:
          type: boolean
        source:
          type: string
    types.FeeTrueUpConfiguration:
      type: object
      properties:
        actual_quantity_policy:
          $ref: '#/components/schemas/types.FeeQuantityPolicy'
        enabled:
          type: boolean
        negative_treatment:
          type: string
        positive_timing:
          type: string
        trigger:
          type: string
    types.FeePricingTier:
      type: object
      properties:
        amount_minor:
          type: integer
        rate:
          $ref: '#/components/schemas/bson.Decimal128'
        up_to:
          $ref: '#/components/schemas/bson.Decimal128'
  securitySchemes:
    ApiKeyAuth:
      description: CX API key. Create one in CX under Settings → Advanced → API Keys.
      in: header
      name: x-api-key
      type: apiKey

````

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