---
title: "Get Sub-DAG Run Specification"
method: GET
path: "/dag-runs/{name}/{dagRunId}/sub-dag-runs/{subDAGRunId}/spec"
tags: ["dag-runs"]
---

# Get Sub-DAG Run Specification

`GET /dag-runs/{name}/{dagRunId}/sub-dag-runs/{subDAGRunId}/spec`

Returns the YAML specification used for a specific sub-DAG run

## Path parameters

- `name` string, regex, required — Name of the DAG
- `dagRunId` string, required — Unique identifier for the DAG-run. The special value 'latest' can be used to reference the most recent DAG-run.
- `subDAGRunId` string, required

## Query parameters

- `remoteNode` string

## Response `200`

Sub-DAG specification retrieved successfully

- object
  - `spec` string, required — YAML specification of the sub-DAG

## Other responses

- `404` — Sub-DAG run not found
- `default` — Generic error response

## Changes

- **2026-05-24** (v1) `8a2d5d3e9608` — 2 warning
  - added the new `rate_limited` enum value to the `code` response property for the response status `404`
  - added the new `rate_limited` enum value to the `code` response property for the response status `default`
- **2026-04-30** (v1) `50e1d517afc1` — 2 info
  - removed the `rate_limited` enum value from the `code` response property for the response status `404`
  - removed the `rate_limited` enum value from the `code` response property for the response status `default`

[Change history](https://skmtc.dev/dagucloud/apis/dagu/changes/dag-runs/:name/:dagRunId/sub-dag-runs/:subDAGRunId/spec/get.md)

---

[API](https://skmtc.dev/dagucloud/apis/dagu.md) · [All operations](https://skmtc.dev/dagucloud/apis/dagu/llms.txt) · [OpenAPI document](https://skmtc.dev/dagucloud/apis/dagu/revisions/c5b8d495669e?raw)
