---
title: "Validate a DAG specification"
method: POST
path: "/dags/validate"
tags: ["dags"]
---

# Validate a DAG specification

`POST /dags/validate`

Validates a DAG YAML specification without persisting any changes.

Returns a list of validation errors. When the spec can be partially parsed,
the response may also include parsed DAG details built with error-tolerant loading.

## Query parameters

- `remoteNode` string

## Request body

- object
  - `spec` string, required — DAG specification in YAML format
  - `name` string — Optional name to use when the spec omits a name

## Response `200`

Validation result

- object
  - `valid` boolean, required — True if the spec is valid (no errors)
  - `dag` DAGDetails — unresolved $ref
  - `errors` string[], required — List of validation errors

## Other responses

- `default` — Generic error response

---

[API](https://skmtc.net/dagucloud/apis/dagu.md) · [All operations](https://skmtc.net/dagucloud/apis/dagu/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/dagucloud/dagu/revisions/f8982f33e540/schema)
