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

# Validate a team manifest

> Validates a team manifest without installing it. Returns structured errors,
warnings and a summary of the manifest content (name, version, phase count,
agents referenced).

Checks performed:
1. YAML syntax and schema validation (phase graph, inputs, agents).
2. Unused inputs — inputs declared at the top level but not consumed by any phase.
3. Dependencies file (if supplied) — must be a valid YAML array.
4. Orphan phases — phases not reachable from the graph root.

The response always has `valid: true/false`, an `errors` array, a `warnings`
array and a `summary` object. When `valid` is `false`, the manifest would be
rejected by `teams/install`.

From the CLI: `cliq team validate ./path/to/team`.

No credential is needed from this machine. From another host, send `Authorization: Bearer` with a dispatch token CliqHub signed for this daemon or a `cliq_tok_…` personal token of a user in the daemon's realm; this only works once the daemon is connected to CliqHub. See [Authentication](/daemon-api/overview#authentication).



## OpenAPI

````yaml /openapi/daemon-by-tag/daemon-teams.yaml post /v1/teams/validate
openapi: 3.1.0
info:
  title: cliqd API
  version: 1.9.48
  description: >-
    HTTP API of `cliqd`, the local Cliq daemon. Generated from the daemon source
    by `scripts/generate_daemon_openapi.mjs` — do not edit by hand. See the
    [overview](/daemon-api/overview).
servers:
  - url: http://127.0.0.1:4900
    description: Local daemon (default port; `CLIQ_DAEMON_PORT` changes it)
security: []
tags:
  - name: Daemon Teams
    description: >-
      The daemon's **local team catalog**: the teams this cliqd can run. Install
      a team

      from a manifest you hold (`teams/install`) or from CliqHub
      (`teams/hub_install`),

      read it back, update it, remove it, and publish manifests to CliqHub.


      A team is addressed by **scope + slug** (`@acme/code-review` → `scope:
      "acme"`,

      `slug: "code-review"`). The scope `local` is offline-only: it needs no
      CliqHub

      sign-in and can never be published. Every other scope needs `cliq login`
      first.
paths:
  /v1/teams/validate:
    post:
      tags:
        - Daemon Teams
      summary: Validate a team manifest
      description: >-
        Validates a team manifest without installing it. Returns structured
        errors,

        warnings and a summary of the manifest content (name, version, phase
        count,

        agents referenced).


        Checks performed:

        1. YAML syntax and schema validation (phase graph, inputs, agents).

        2. Unused inputs — inputs declared at the top level but not consumed by
        any phase.

        3. Dependencies file (if supplied) — must be a valid YAML array.

        4. Orphan phases — phases not reachable from the graph root.


        The response always has `valid: true/false`, an `errors` array, a
        `warnings`

        array and a `summary` object. When `valid` is `false`, the manifest
        would be

        rejected by `teams/install`.


        From the CLI: `cliq team validate ./path/to/team`.


        No credential is needed from this machine. From another host, send
        `Authorization: Bearer` with a dispatch token CliqHub signed for this
        daemon or a `cliq_tok_…` personal token of a user in the daemon's realm;
        this only works once the daemon is connected to CliqHub. See
        [Authentication](/daemon-api/overview#authentication).
      operationId: daemon_post_teams_validate
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                manifest:
                  type: string
                  minLength: 1
                  description: Team manifest (YAML)
                dependencies:
                  type: string
                  minLength: 1
                  description: Dependency manifest (YAML) — optional
              required:
                - manifest
            examples:
              minimal:
                summary: Validate a manifest
                value:
                  manifest: |
                    name: hello-world
                    version: 1.0.0
                    phases:
                      go:
                        agent: echo
                        command: echo hello
      responses:
        '200':
          description: Validation result (always returned — even when invalid)
          content:
            application/json:
              schema:
                type: object
                properties:
                  ok:
                    type: boolean
                    const: true
                  valid:
                    type: boolean
                    description: '`true` when the manifest passes all checks'
                  errors:
                    type: array
                    description: >-
                      Issues that would prevent install (empty when `valid:
                      true`)
                    items:
                      type: object
                      properties:
                        level:
                          type: string
                          enum:
                            - error
                        message:
                          type: string
                      required:
                        - level
                        - message
                  warnings:
                    type: array
                    description: Non-fatal observations (orphan phases, etc.)
                    items:
                      type: object
                      properties:
                        level:
                          type: string
                          enum:
                            - warning
                        message:
                          type: string
                      required:
                        - level
                        - message
                  summary:
                    type: object
                    description: Parsed manifest metadata (null fields when parsing failed)
                    properties:
                      name:
                        type: string
                        nullable: true
                      description:
                        type: string
                        nullable: true
                      version:
                        type: string
                        nullable: true
                      phase_count:
                        type: integer
                      agents_referenced:
                        type: array
                        items:
                          type: string
                required:
                  - ok
                  - valid
                  - errors
                  - warnings
                  - summary
              examples:
                valid:
                  summary: A valid manifest
                  value:
                    ok: true
                    valid: true
                    errors: []
                    warnings: []
                    summary:
                      name: hello-world
                      description: null
                      version: 1.0.0
                      phase_count: 1
                      agents_referenced:
                        - echo
                invalid:
                  summary: A manifest with errors
                  value:
                    ok: true
                    valid: false
                    errors:
                      - level: error
                        message: 'phases: must have at least one phase'
                    warnings: []
                    summary:
                      name: null
                      description: null
                      version: null
                      phase_count: 0
                      agents_referenced: []
        '500':
          description: >-
            `INTERNAL_ERROR` — An unexpected daemon fault. The message names the
            request id; the cause is in the cliqd log.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorReply'
              examples:
                INTERNAL_ERROR:
                  summary: INTERNAL_ERROR
                  value:
                    ok: false
                    error:
                      code: INTERNAL_ERROR
                      message: >-
                        cliqd hit an unexpected error (request 7f3a…). Details
                        are in the cliqd log.
      security:
        - {}
        - DaemonBearer: []
components:
  schemas:
    ErrorReply:
      type: object
      description: >-
        Every failure. Switch on `error.code` — it is stable; `message` is for
        people and may change.
      required:
        - ok
        - error
      properties:
        ok:
          type: boolean
          const: false
        error:
          type: object
          required:
            - code
            - message
          properties:
            code:
              type: string
              description: Stable error code. See [Errors](/daemon-api/errors).
              example: TEAM_NOT_FOUND
            message:
              type: string
              description: What went wrong and, where possible, what to do.
              example: Team 'acme/code-review' not found
            details:
              description: >-
                Structured detail when there is some: the list of schema issues
                for `PAYLOAD_INVALID`, the agent problems for
                `TEAM_AGENT_CONFIG_REQUIRED`, …
  securitySchemes:
    DaemonBearer:
      type: http
      scheme: bearer
      description: >-
        Not needed from the same machine. From another host: a dispatch JWT
        CliqHub signed for this daemon, or a `cliq_tok_…` personal token whose
        user is in the daemon's realm.

````

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