Stage Git files
Add the current contents of the given paths to the index, ready for the next commit. Works only on a development app: any other app answers 403 `read_only`. Runs git in the app's running container and returns its output.
Authorization
cloady Personal API token (cldy_…)
In: header
Path Parameters
Query Parameters
Value in
- "production"
- "preview"
- "development"
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
application/json
application/json
application/json
application/json
application/json
curl -X POST "https://example.com/api/workspaces/string/apps/string/git/stage" \ -H "Content-Type: application/json" \ -d '{ "paths": [ "string" ] }'{ "ok": true, "output": "string"}Check out a Git branch POST
Switch the working tree to a branch with `git switch`, so the name is never read as a path. A branch that exists only on the remote is checked out tracking it, and `create` makes a new branch at the current commit. Refuses when uncommitted changes would be overwritten; other uncommitted changes come along. Works only on a development app: any other app answers 403 `read_only`. Runs git in the app's running container and returns its output.
Unstage Git files POST
Take the given paths out of the index; their changes stay in the working tree. Works only on a development app: any other app answers 403 `read_only`. Runs git in the app's running container and returns its output.