Get current deployment
See how an application is wired for Git deploys with GET /v2/apps/:app_id/deployments/current: its GitHub App repository, a legacy webhook, or both.
GET
Get current deployment
string
required
The API key for your account. You can find this in your account settings.
apps:read scope.
This endpoint reports how the application is currently wired for Git-based deploys: a GitHub App repository linkage, a legacy webhook URL, or both, depending on how the integration was set up. Use it to check the tracked repository and branch before troubleshooting a deploy, or to confirm whether a webhook still needs to be generated.
The response is cached for 5 minutes per owner and application, so changes made through Set GitHub Webhook may take a few minutes to show up here. On workspace-shared applications, the caller needs the manager or admin role, or ownership. To see deploy history rather than the current configuration, use List Deployments.
The webhook URL works as a deploy credential, so it is returned in full only to a caller that can configure it: an API key with the apps:deploy scope (or full access) or, on a workspace-shared application, the admin role or ownership. Anyone else, such as an apps:read key or a manager, gets it masked (https://api.squarecloud.app/v2/git/webhook/********), which still tells you a webhook is configured.
Parameters
string
required
The ID of the application. You can find this in the URL of your application’s dashboard.
Response
string
Indicates whether the call was successful:
success if it was, error if not.object
The contents of the response.
Related
- CLI:
squarecloud app deploy current - SDKs:
api.apps.deploys.current()(JavaScript),client.apps.deploys.current()(Python),c.Apps.Deploys.Current()(Go)

