Create File Tool
create_file_toolCreates a new file in a GitLab repository by committing specified content to a branch with a commit message.
Instructions
Create a new file in a GitLab repository.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"project_id": "<project_id>",
"file_path": "<file_path>",
"branch": "<branch>",
"content": "<content>",
"commit_message": "<commit_message>"
},
"name": "create_file_tool"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| branch | Yes | Branch to commit to | |
| content | Yes | File content (text or base64 depending on encoding) | |
| encoding | No | Content encoding - "text" or "base64" (default: text) | text |
| file_path | Yes | Path for the new file | |
| project_id | Yes | Project ID or path | |
| commit_message | Yes | Commit message |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||