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

# Start an async skill run

> Start a skill run in the background and get a run id at once. Supports Idempotency-Key and signed webhooks.

The rows are not in this response. Poll [`GET /v1/runs/{run_id}`](/api-reference/runs/get-skill-run) until `status` is no longer `queued` or `running`, or set `webhook_url` to receive the finished run as a signed `POST`. See [Webhooks](/guides/web-to-api#webhooks) for how to verify the signature.


## OpenAPI

````yaml POST /v1/skills/{slug}/runs
openapi: 3.0.3
info:
  title: Valendata REST API
  version: 1.0.0
  description: >-
    Trigger Skills, manage Workflows, retrieve Runs, and stream structured
    results from any language using JSON over HTTPS.
servers:
  - url: https://api.valendata.com
    description: Production
security:
  - ApiKeyAuth: []
tags:
  - name: Skills
    description: Execute and inspect published Skills.
  - name: Workflows
    description: Trigger multi-step Workflows and list them.
  - name: Runs
    description: Start async Skill runs and read Skill and Workflow run results.
  - name: Skill creation
    description: Create a Skill from a plain-language task.
  - name: Skill improvement
    description: >-
      Fix a Skill, add fields to it or re-learn its detail steps, poll the
      result, and read its change history.
  - name: Versions
    description: List, diff, restore, and pin a Skill's recipe versions.
  - name: Webhooks
    description: Signed delivery of finished async runs.
paths:
  /v1/skills/{slug}/runs:
    post:
      tags:
        - Runs
      summary: Start an async Skill run
      description: >-
        Validate the inputs, start the run, and answer at once with a `run_id`.
        If your account is at its limit of runs in progress, the run queues.
        Poll `GET /v1/runs/{run_id}` or pass `webhook_url`.
      operationId: startSkillRun
      parameters:
        - name: slug
          in: path
          required: true
          schema:
            type: string
          description: URL-safe slug of the Skill.
          example: austin-dentists
        - name: Idempotency-Key
          in: header
          required: false
          schema:
            type: string
          description: >-
            Retry-safe key. The same key from the same account returns what it
            already started.
      requestBody:
        required: false
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/StartRunRequest'
      responses:
        '202':
          description: Run queued (or the existing one, for a repeated Idempotency-Key).
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/StartRunResponse'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '403':
          $ref: '#/components/responses/Forbidden'
        '404':
          $ref: '#/components/responses/NotFound'
        '422':
          $ref: '#/components/responses/Unprocessable'
        '429':
          $ref: '#/components/responses/RateLimited'
        '500':
          $ref: '#/components/responses/InternalError'
      security:
        - ApiKeyAuth: []
components:
  schemas:
    StartRunRequest:
      type: object
      properties:
        inputs:
          type: object
          additionalProperties: true
          description: The Skill's inputs (see `input_schema`).
          example:
            city: Houston
        parameters:
          type: object
          additionalProperties: true
          description: Accepted as another name for `inputs`.
        max_results:
          type: integer
          minimum: 0
          maximum: 500
          description: Max rows; 0 returns the whole list.
        max_pages:
          type: integer
          minimum: 0
          description: Page limit; 0 means all pages.
        browser_type:
          type: string
          description: >-
            `remote`, `extension`, `local_profile`, or `none`. Omit for the
            Skill's saved setting.
        proxy_config:
          type: string
          description: Region for this run (country code, `random`, or `none`).
        profile_id:
          type: string
          description: Browser profile to use for this run.
        scrape_mode:
          type: string
          description: '`deep` or `flash`, for Skills that support it.'
        webhook_url:
          type: string
          description: Public http(s) URL that receives the finished run as a signed POST.
        version:
          type: integer
          minimum: 1
          description: Recipe version to replay. Omit for the pinned or live one.
    StartRunResponse:
      type: object
      properties:
        run_id:
          type: string
          example: run_8c1d2e3f4a5b
        status:
          type: string
          example: queued
        poll_url:
          type: string
          example: /v1/runs/run_8c1d2e3f4a5b
        idempotent_replay:
          type: boolean
    Error:
      type: object
      properties:
        detail:
          oneOf:
            - type: string
            - type: object
              additionalProperties: true
          description: >-
            Error message. Usually a plain string; may be a structured object
            for some errors.
      example:
        detail: Invalid or expired API key
  responses:
    Unauthorized:
      description: >-
        Unauthorized. The Authorization header is missing, malformed, or the
        credential is invalid or expired.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
    Forbidden:
      description: >-
        Forbidden. You may not run or change this Skill, or it is not published
        or active.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
    NotFound:
      description: Resource not found in your Workspace.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
    Unprocessable:
      description: >-
        Invalid request. For bad inputs, `detail` is `{message, errors,
        allowed_inputs}`.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
    RateLimited:
      description: >-
        Too many requests for this API key, too many runs in progress, or too
        many recordings in progress. Check the `Retry-After` header when
        present.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
    InternalError:
      description: Internal server error on Valendata's side.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
  securitySchemes:
    ApiKeyAuth:
      type: http
      scheme: bearer
      bearerFormat: vd_sk_...
      description: >-
        API key with the `vd_sk_` prefix. Create keys from Settings, API Keys in
        the dashboard.

````

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