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

# Manual Enroll

> Manually enroll a contact into an active automation.

Respects the automation's re-entry policy.  Returns 409 when the
automation is not active, 404 when the contact is not found in the team.
Returns 201 with the enrollment resource on success, or 200 (no body)
when the re-entry policy suppresses the enrollment.



## OpenAPI

````yaml /openapi/mio-openapi.json post /api/v1/teams/{team_id}/hubs/{hub_id}/automations/{automation_id}/enrollments
openapi: 3.1.0
info:
  description: >-
    Production API reference for Membership.io. Use the authored guides for
    workflows and the generated endpoint pages for exact parameters and schemas.
  title: Membership.io API
  version: 0.1.0
servers:
  - description: Production
    url: https://api.member.dev
security:
  - bearerAuth: []
paths:
  /api/v1/teams/{team_id}/hubs/{hub_id}/automations/{automation_id}/enrollments:
    post:
      tags:
        - automations
      summary: Manual Enroll
      description: |-
        Manually enroll a contact into an active automation.

        Respects the automation's re-entry policy.  Returns 409 when the
        automation is not active, 404 when the contact is not found in the team.
        Returns 201 with the enrollment resource on success, or 200 (no body)
        when the re-entry policy suppresses the enrollment.
      operationId: >-
        automations.post_automations_post_teams_by_team_id_hubs_by_hub_id_automations_by_automation_id_enrollments
      parameters:
        - in: path
          name: team_id
          required: true
          schema:
            title: Team Id
            type: string
        - in: path
          name: hub_id
          required: true
          schema:
            title: Hub Id
            type: string
        - in: path
          name: automation_id
          required: true
          schema:
            title: Automation Id
            type: string
      requestBody:
        content:
          application/vnd.api+json:
            schema:
              $ref: '#/components/schemas/ManualEnrollBody'
        required: true
      responses:
        '201':
          content:
            application/vnd.api+json:
              schema:
                $ref: '#/components/schemas/AutomationEnrollmentResponse'
          description: Successful Response
        '400':
          content:
            application/vnd.api+json:
              schema:
                $ref: '#/components/schemas/JsonApiErrorResponse'
          description: Bad request
        '401':
          content:
            application/vnd.api+json:
              schema:
                $ref: '#/components/schemas/JsonApiErrorResponse'
          description: Not authenticated
        '403':
          content:
            application/vnd.api+json:
              schema:
                $ref: '#/components/schemas/JsonApiErrorResponse'
          description: Forbidden
        '404':
          content:
            application/vnd.api+json:
              schema:
                $ref: '#/components/schemas/JsonApiErrorResponse'
          description: Not found
        '409':
          content:
            application/vnd.api+json:
              schema:
                $ref: '#/components/schemas/JsonApiErrorResponse'
          description: Status conflict
        '415':
          content:
            application/vnd.api+json:
              schema:
                $ref: '#/components/schemas/JsonApiErrorResponse'
          description: Unsupported media type (requires application/vnd.api+json)
        '422':
          content:
            application/vnd.api+json:
              schema:
                $ref: '#/components/schemas/JsonApiErrorResponse'
          description: Graph validation error
      security:
        - HTTPBearer: []
components:
  schemas:
    ManualEnrollBody:
      additionalProperties: false
      properties:
        data:
          $ref: '#/components/schemas/ManualEnrollResource'
      required:
        - data
      title: ManualEnrollBody
      type: object
    AutomationEnrollmentResponse:
      additionalProperties: false
      properties:
        data:
          $ref: '#/components/schemas/AutomationEnrollmentResource'
      required:
        - data
      title: AutomationEnrollmentResponse
      type: object
    JsonApiErrorResponse:
      description: Error JSON:API response.
      properties:
        errors:
          items:
            $ref: '#/components/schemas/JsonApiError'
          title: Errors
          type: array
        meta:
          anyOf:
            - additionalProperties: true
              type: object
            - type: 'null'
          title: Meta
      required:
        - errors
      title: JsonApiErrorResponse
      type: object
    ManualEnrollResource:
      additionalProperties: false
      properties:
        attributes:
          $ref: '#/components/schemas/ManualEnrollAttributes'
        type:
          const: automation_enrollments
          title: Type
          type: string
      required:
        - type
        - attributes
      title: ManualEnrollResource
      type: object
    AutomationEnrollmentResource:
      additionalProperties: false
      properties:
        attributes:
          $ref: '#/components/schemas/AutomationEnrollmentAttributes'
        id:
          title: Id
          type: string
        type:
          const: automation_enrollments
          default: automation_enrollments
          title: Type
          type: string
      required:
        - id
        - attributes
      title: AutomationEnrollmentResource
      type: object
    JsonApiError:
      properties:
        code:
          anyOf:
            - type: string
            - type: 'null'
          title: Code
        detail:
          anyOf:
            - type: string
            - type: 'null'
          title: Detail
        id:
          anyOf:
            - type: string
            - type: 'null'
          title: Id
        meta:
          anyOf:
            - additionalProperties: true
              type: object
            - type: 'null'
          title: Meta
        source:
          anyOf:
            - additionalProperties:
                type: string
              type: object
            - type: 'null'
          title: Source
        status:
          title: Status
          type: string
        title:
          title: Title
          type: string
      required:
        - status
        - title
      title: JsonApiError
      type: object
    ManualEnrollAttributes:
      additionalProperties: false
      properties:
        team_contact_id:
          title: Team Contact Id
          type: string
      required:
        - team_contact_id
      title: ManualEnrollAttributes
      type: object
    AutomationEnrollmentAttributes:
      additionalProperties: false
      description: Read-only attributes for an ``automation_enrollments`` resource.
      properties:
        automation_id:
          title: Automation Id
          type: string
        automation_version_id:
          title: Automation Version Id
          type: string
        contact_id:
          title: Contact Id
          type: string
        created_at:
          format: date-time
          title: Created At
          type: string
        current_node_id:
          title: Current Node Id
          type: string
        entered_at:
          format: date-time
          title: Entered At
          type: string
        exit_reason:
          anyOf:
            - type: string
            - type: 'null'
          title: Exit Reason
        exited_at:
          anyOf:
            - format: date-time
              type: string
            - type: 'null'
          title: Exited At
        hub_id:
          title: Hub Id
          type: string
        next_due_at:
          anyOf:
            - format: date-time
              type: string
            - type: 'null'
          title: Next Due At
        run_attributes:
          additionalProperties: true
          title: Run Attributes
          type: object
        status:
          title: Status
          type: string
        step_execution_count:
          title: Step Execution Count
          type: integer
        team_contact_id:
          title: Team Contact Id
          type: string
        team_id:
          title: Team Id
          type: string
        trigger_context:
          additionalProperties: true
          title: Trigger Context
          type: object
        updated_at:
          format: date-time
          title: Updated At
          type: string
      required:
        - automation_id
        - automation_version_id
        - team_id
        - hub_id
        - team_contact_id
        - contact_id
        - current_node_id
        - status
        - step_execution_count
        - entered_at
        - created_at
        - updated_at
      title: AutomationEnrollmentAttributes
      type: object
  securitySchemes:
    bearerAuth:
      bearerFormat: JWT or mio_sk API key
      description: >-
        Send platform JWTs, contact JWTs, or team API keys as `Authorization:
        Bearer <token>`.
      scheme: bearer
      type: http
    HTTPBearer:
      scheme: bearer
      type: http

````