Git sync
Sync Git repository
Manually pull the latest Watch scripts from Git and reload them.
POST
/
git
/
sync
curl -X POST http://localhost:8081/git/sync
{
"success": true,
"message": "Repository synced and scripts reloaded",
"before_commit": "abc123def456",
"after_commit": "def456ghi789"
}
{
"success": true,
"message": "Repository synced successfully",
"before_commit": "abc123def456",
"after_commit": "abc123def456"
}
{
"success": false,
"error": "Git repository not configured"
}
{
"success": false,
"before_commit": "abc123def456",
"error": "Failed to sync repository: ..."
}
Blnk Watch is currently in beta. Send us a message
WATCH_SCRIPT_GIT_REPO is configured in your Watch configuration.
Request
This endpoint has no path, query, or body parameters.curl -X POST http://localhost:8081/git/sync
{
"success": true,
"message": "Repository synced and scripts reloaded",
"before_commit": "abc123def456",
"after_commit": "def456ghi789"
}
{
"success": true,
"message": "Repository synced successfully",
"before_commit": "abc123def456",
"after_commit": "abc123def456"
}
{
"success": false,
"error": "Git repository not configured"
}
{
"success": false,
"before_commit": "abc123def456",
"error": "Failed to sync repository: ..."
}
Response fields
boolean
Whether the sync operation completed successfully.
string
Status message. When the commit changes, this includes confirmation that scripts were reloaded.
string
Local commit hash before the sync started.
string
Local commit hash after the sync completed.
string
Error message when Git is not configured or the sync fails.
Need help?
We are very happy to help you make the most of Blnk, regardless of whether it is your first time or you are switching from another tool. To ask questions or discuss issues, please contact us or join our Discord community.Was this page helpful?
⌘I
curl -X POST http://localhost:8081/git/sync
{
"success": true,
"message": "Repository synced and scripts reloaded",
"before_commit": "abc123def456",
"after_commit": "def456ghi789"
}
{
"success": true,
"message": "Repository synced successfully",
"before_commit": "abc123def456",
"after_commit": "abc123def456"
}
{
"success": false,
"error": "Git repository not configured"
}
{
"success": false,
"before_commit": "abc123def456",
"error": "Failed to sync repository: ..."
}