---
title: "Sync Deployment To Git Internal"
method: POST
path: "/internal/deployments/{deployment_id}/sync-to-git"
tags: ["internal"]
---

# Sync Deployment To Git Internal

`POST /internal/deployments/{deployment_id}/sync-to-git`

## Request

- Base URL: `https://api.mengi.cloud` (the document declares no server; this is the origin it was published from)
- URL: `https://api.mengi.cloud/internal/deployments/{deployment_id}/sync-to-git`
- Auth: none declared. Required headers: `x-service-token`

Sync deployment values.yaml to Git (internal, called by worker).

This endpoint:
- Updates the deployment's values.yaml
- Syncs to the Git repository
- Updates git_sync_status and deployment status

## Path parameters

- `deployment_id` string, uuid, required

## Headers

- `x-service-token` string, required

## Request body

- SyncDeploymentRequest: Request to sync deployment to Git (worker calls this).
  - `values_yaml` string, required

## Response `200`

Successful Response

- unknown

## Other responses

- `422`: Validation Error

---

[API](https://skmtc.dev/mengi/apis/mengi-cloud.md) · [All operations](https://skmtc.dev/mengi/apis/mengi-cloud/llms.txt) · [OpenAPI document](https://skmtc.dev/mengi/apis/mengi-cloud/revisions/4ae9b375cdbb?raw)
