CorefinityCorefinityDocs
Open the Control PanelControl Panel
Deployment pipeline · 6 of 15

Check a stage's lines before saving

Says what the platform makes of each line of a stage: whether it only touches files or needs the environment's services, and whether a build with these lines would open a tunnel to them. It stores nothing and runs nothing.

POST/api/corestack/sites/{site}/deployments/pipeline/check

Path parameters

siteintegerRequired

The id of a site row. A website's production site and each of its environments has its own id. Digits only. At least 1.

Body

binding_idinteger

One of the environment's pipelines. The default pipeline when left out. At least 1.

linesarray of stringsRequired

Up to 200 items.

stagestringRequired
builddatabasepost_deploy

Returns

200 What the platform makes of each line, in the order sent.

Fields of the 200 answer
linesarray of objectsRequired
Fields of each item
badgesarray of objectsRequired
Fields of each item
idstringRequired
labelstringRequired
severitystring
rulestring or null

The rule that recognised the line.

suggestionstring or null
verdictstringRequired

Such as files for a line that only touches files, or services for one that needs the environment's services.

warningsarrayRequired
stagestringRequired
tunnelsobjectRequired

Whether a build with these lines opens a tunnel to the environment's services, and to which.

If it is refused

StatusReasonWhat to do
401noneSend a valid token as Authorization: Bearer <token>.
403company_unavailableYour company is unavailable.
403scope_requiredUse a token with the scope named in scope.
403two_factor_requiredTurn on two-factor on your account, then send again.
404feature_offThis feature is not on for your organisation yet.
422invalidFix the field named in field; errors says why.
429rate_limitedWait for the seconds in Retry-After.

Reasons are listed by name in Errors and refusals.

The same task elsewhere

curl -X POST https://manage.corefinity.com/api/corestack/sites/1042/deployments/pipeline/check \
  -H "Authorization: Bearer $COREFINITY_TOKEN" \
  -H "Accept: application/json" \
  -H "Content-Type: application/json" \
  -d '{
    "lines": [
      "composer install --no-dev",
      "php artisan migrate --force"
    ],
    "stage": "build"
  }'
{
  "lines": [
    {
      "badges": [],
      "rule": "composer.install",
      "suggestion": null,
      "verdict": "files",
      "warnings": []
    },
    {
      "badges": [
        {
          "id": "uses_services",
          "label": "Uses this environment's services",
          "severity": "info"
        }
      ],
      "rule": "laravel.migrate",
      "suggestion": null,
      "verdict": "services",
      "warnings": []
    }
  ],
  "stage": "build",
  "tunnels": {
    "declared_by": [
      2
    ],
    "open": true,
    "services": [
      {
        "key": "database",
        "label": "MariaDB"
      },
      {
        "key": "redis",
        "label": "Valkey"
      }
    ]
  }
}
Try it
Held in this tab's memory only. Never stored or sent to us.

This sends a real POST request and changes your account.

Use a token with only the read scope. How to make one

Was this helpful?
Open in ClaudeOpen in ChatGPT