Skip to main content
GET
/
api
/
v1
/
git
/
file
/
{filepath}
Get file at commit
curl --request GET \
  --url http://localhost:3000/api/v1/git/file/{filepath} \
  --cookie nut-session=
{
  "success": true,
  "data": {
    "content": "<string>"
  }
}

Authorizations

nut-session
string
cookie
required

Session cookie authentication

Path Parameters

filepath
string
required

File path

Query Parameters

ref
string
default:HEAD

Git reference (commit SHA, branch, tag)

Response

File content

success
boolean
required
data
object