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

# Create Workflow



## OpenAPI

````yaml /api/openapi.json post /agent/v1/research/workflows
openapi: 3.1.0
info:
  title: CrowdListen Agent API
  description: >-
    Configure sources, collect and retain originals, run durable analysis, and
    read or revise cited insights. Humans and agents share authorized
    entity/project records, research jobs and evidence history.
  version: 1.0.0
servers:
  - url: https://agent.crowdlisten.com
    description: Production
  - url: http://localhost:8000
    description: Local development
security: []
paths:
  /agent/v1/research/workflows:
    post:
      tags:
        - research
      summary: Create Workflow
      operationId: create_workflow_agent_v1_research_workflows_post
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/ResearchWorkflowCreate'
      responses:
        '202':
          description: Successful Response
          content:
            application/json:
              schema: {}
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
components:
  schemas:
    ResearchWorkflowCreate:
      properties:
        request_id:
          type: string
          maxLength: 128
          minLength: 8
          title: Request Id
        entity_id:
          type: string
          format: uuid
          title: Entity Id
        workspace_id:
          anyOf:
            - type: string
              format: uuid
            - type: 'null'
          title: Workspace Id
        goal:
          type: string
          maxLength: 1000
          minLength: 1
          title: Goal
        source_selection:
          $ref: '#/components/schemas/SourceSelection'
        method_id:
          type: string
          enum:
            - competitive-positioning
            - marketing-strategy
            - affiliate-tracking
            - own-account-performance
            - feedback-synthesis
            - developer-experience
          title: Method Id
        executor:
          $ref: '#/components/schemas/Executor'
        max_charge_cents:
          type: integer
          maximum: 10000
          minimum: 1
          title: Max Charge Cents
      additionalProperties: false
      type: object
      required:
        - request_id
        - entity_id
        - goal
        - source_selection
        - method_id
        - executor
        - max_charge_cents
      title: ResearchWorkflowCreate
    HTTPValidationError:
      properties:
        detail:
          items:
            $ref: '#/components/schemas/ValidationError'
          type: array
          title: Detail
      type: object
      title: HTTPValidationError
    SourceSelection:
      properties:
        x_accounts:
          items:
            type: string
          type: array
          maxItems: 5
          title: X Accounts
        x_account_targets:
          anyOf:
            - items:
                $ref: '#/components/schemas/OnboardingAccountTarget'
              type: array
              maxItems: 5
            - type: 'null'
          title: X Account Targets
        date_range_days:
          type: integer
          enum:
            - 7
            - 30
            - 90
          title: Date Range Days
          default: 30
        saved_content_ids:
          items:
            type: string
            format: uuid
          type: array
          maxItems: 200
          title: Saved Content Ids
        import_text:
          type: string
          maxLength: 100000
          title: Import Text
          default: ''
      additionalProperties: false
      type: object
      title: SourceSelection
    Executor:
      properties:
        kind:
          type: string
          enum:
            - hosted
            - connected
          title: Kind
        client:
          anyOf:
            - type: string
              enum:
                - codex
                - cursor
                - claude-code
                - openclaw
            - type: 'null'
          title: Client
      additionalProperties: false
      type: object
      required:
        - kind
      title: Executor
    ValidationError:
      properties:
        loc:
          items:
            anyOf:
              - type: string
              - type: integer
          type: array
          title: Location
        msg:
          type: string
          title: Message
        type:
          type: string
          title: Error Type
      type: object
      required:
        - loc
        - msg
        - type
      title: ValidationError
    OnboardingAccountTarget:
      properties:
        target:
          type: string
          maxLength: 500
          minLength: 1
          title: Target
        role:
          type: string
          enum:
            - official
            - employee
            - founder
            - advocate
            - affiliate
            - organization_affiliate
            - creator
            - competitor
            - unknown
          title: Role
          default: unknown
        organization_affiliation:
          anyOf:
            - $ref: '#/components/schemas/XAffiliation'
            - type: 'null'
      additionalProperties: false
      type: object
      required:
        - target
      title: OnboardingAccountTarget
    XAffiliation:
      properties:
        organization_id:
          type: string
          pattern: ^[0-9]{1,19}$
          title: Organization Id
        organization_username:
          type: string
          pattern: ^[A-Za-z0-9_]{1,15}$
          title: Organization Username
        account_id:
          type: string
          pattern: ^[0-9]{1,19}$
          title: Account Id
        observed_at:
          type: string
          format: date-time
          title: Observed At
      additionalProperties: false
      type: object
      required:
        - organization_id
        - organization_username
        - account_id
        - observed_at
      title: XAffiliation

````

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