---
title: "Validate Protocol Endpoint"
method: POST
path: "/protocols/validate"
tags: ["protocols"]
---

# Validate Protocol Endpoint

`POST /protocols/validate`

Validate a protocol dictionary.

Runs the full backend validation (Pydantic model checks, termination
condition inheritance, operator consistency, duplicate names, etc.)
and returns the result.

Parameters
----------
body : ValidateProtocolRequest
    Request containing the protocol dict to validate

Returns
-------
dict
    ``{"valid": true}`` on success, or
    ``{"valid": false, "error": "..."}`` on failure.

## Request body

- ValidateProtocolRequest — Request body for validating a protocol.
  - `protocol` union, required — Protocol as a YAML-format dictionary with 'steps' and optional 'global', 'safety_limits', or a YAML string.
    - object
    - string

## Response `200`

Successful Response

- object

## Other responses

- `422` — Validation Error

---

[API](https://skmtc.dev/ionworks/apis/fastapi.md) · [All operations](https://skmtc.dev/ionworks/apis/fastapi/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/ionworks/fastapi/revisions/7337a3cbdaf2/schema)
