---
title: "Search DAG match snippets"
method: GET
path: "/search/dags/{fileName}/matches"
tags: ["search"]
---

# Search DAG match snippets

`GET /search/dags/{fileName}/matches`

Returns cursor-based snippets for one matching DAG definition.

## Path parameters

- `fileName` string, regex, required — Name of the DAG file

## Query parameters

- `remoteNode` string
- `q` string, required
- `labels` string
- `workspace` string
- `cursor` string
- `limit` integer

## Response `200`

Cursor-based DAG match snippets

- SearchMatchesResponse — Cursor-based search match snippets
  - `matches` SearchMatchItem[], required
    - `line` string, required — Matching line content
    - `lineNumber` integer, required — Line number where match was found
    - `startLine` integer, required — Start line for context
  - `hasMore` boolean, required
  - `nextCursor` string

## Other responses

- `400` — Invalid request
- `404` — DAG not found
- `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/93cc41f2018a/schema)
