---
title: "Line Info"
method: GET
path: "/line/{line_code}/info"
---

# Line Info

`GET /line/{line_code}/info`

## Path parameters

- `line_code` string, required

## Response `200`

Successful Response

- LineInfo
  - `line_code` string, required
  - `line_id` integer, required
  - `line_name` string, required
  - `routes` RouteInfo[], required
    - `line_code` string, required
    - `line_id` integer, required
    - `line_description` string, nullable, required
    - `line_name` string, required
    - `route_code` string, required
    - `route_id` integer, required
    - `route_description` string, nullable, required
    - `route_name` string, required
    - `route_direction` 'outbound' | 'inbound', required
    - `stops` LineStop[], required
      - `stop_name` string, required
      - `stop_code` integer, required
      - `coordinates` Coordinates, required
        - `x` number, required
        - `y` number, required
      - `direction` string, required
      - `line_code` string, required
      - `route_code` string, required
      - `route_order` integer, required
      - `route_direction` 'outbound' | 'inbound', required
    - `trips` TimetableTrip[], required
      - `line_code` string, required
      - `route_code` string, required
      - `time` string, time, required
      - `day_type` 'working_day' | 'saturday' | 'sunday', required
      - `direction` 'outbound' | 'inbound', required

## Other responses

- `422` — Validation Error

## Changes

- **2024-12-06** `1f272d11e862` — 1 breaking
  - removed the required property `routes/items/stops/items/line_id` from the response with the `200` status

[Change history](https://skmtc.dev/styrowolf/apis/fastapi/changes/line/:line_code/info/get.md)

---

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