---
title: "Read an exact line range from a node's content"
method: GET
path: "/api/v1/nodes/{nodeId}/lines"
tags: ["Nodes"]
---

# Read an exact line range from a node's content

`GET /api/v1/nodes/{nodeId}/lines`

## Request

- Base URL: `https://api-docs.busabase.com`
- URL: `https://api-docs.busabase.com/api/v1/nodes/{nodeId}/lines`
- Auth: none declared

## Path parameters

- `nodeId` string, required

## Query parameters

- `startLine` integer, required: First line to read. 1-indexed, and INCLUSIVE.
- `endLine` integer, required: Last line to read, INCLUSIVE. A range wider than 2000 lines is silently narrowed to the first 2000 rather than rejected — the response reports `lineCountCapped` when that happened, so check it before concluding the file ends there.

## Response `200`

Lines [startLine, endLine] (range capped at 2000 lines / ~2MB response) from any node type that stores content — doc, html, whiteboard, workflow. The follow-up to a Unified Grep match with `source: "nodes"`, so an agent can read just the lines around a match instead of `nodes.get`'s entire document. Line numbers mean whatever they mean for that node type: real source lines for doc/html, positions within the extracted text for the JSON-backed types. Replaces `GET /docs/{nodeId}/lines`, which resolved doc nodes only.

- object
  - `lines` string[], required
  - `totalLines` integer, required
  - `truncated` boolean, required

---

[API](https://skmtc.dev/busabase/apis/busabase-api.md) · [All operations](https://skmtc.dev/busabase/apis/busabase-api/llms.txt) · [OpenAPI document](https://skmtc.dev/busabase/apis/busabase-api/revisions/bc6a7d5ff4c1?raw)
