editor

View File Contents

Changed on

Retrieves the contents of a file, optionally within a specified line range.

post/api/editor/view

Request

  • Base URL
    http://localhost:4242/your-computer-name
  • URL
    http://localhost:4242/your-computer-name/api/editor/view
  • Auth
    none declared

Request body

pathstring required

File path to view

view_rangeinteger[] nullable

Line range to view [start, end]

Example request

{
  "path": "/path/to/file.txt",
  "view_range": [
    1,
    10
  ]
}

Response

Successfully retrieved file contents

string required

Changes