Skip to main content

deployment_checks

Creates, updates, deletes, gets or lists a deployment_checks resource.

Overview

Namedeployment_checks
TypeResource
Idvercel.checks.deployment_checks

Fields

The following fields are returned by SELECT queries:

NameDatatypeDescription
idstring
namestring
deployment_idstring (wire: deploymentId)
external_idstring (wire: externalId)
integration_idstring (wire: integrationId)
blockingboolean (false, true)
completed_atnumber (wire: completedAt)
conclusionstring (canceled, failed, neutral, skipped, stale, succeeded)
created_atnumber (wire: createdAt)
details_urlstring (wire: detailsUrl)
outputobject
pathstring
rerequestableboolean (false, true)
started_atnumber (wire: startedAt)
statusstring (completed, registered, running)
updated_atnumber (wire: updatedAt)

Methods

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
getselectdeployment_id, check_idteam_id, slugReturn a detailed response for a single check.
listselectdeployment_idteam_id, slugList all of the checks created for a deployment.
createinsertdeployment_id, name, blockingteam_id, slugCreates a new check. This endpoint must be called with an OAuth2 or it will produce a 400 error.
updateupdatedeployment_id, check_idteam_id, slugUpdate an existing check. This endpoint must be called with an OAuth2 or it will produce a 400 error.
rerequestexecdeployment_id, check_idautoUpdate, teamId, slugRerequest a selected check that has failed.

Parameters

Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.

NameDatatypeDescription
check_idstringThe check to rerun
deployment_idstringThe deployment to rerun the check for.
autoUpdatebooleanMark the check as running
slugstringThe Team slug to perform the request on behalf of.
teamIdstringThe Team identifier to perform the request on behalf of.
team_idstringThe Team identifier to perform the request on behalf of. (wire: teamId)

SELECT examples

Return a detailed response for a single check.

SELECT
id,
name,
deployment_id,
external_id,
integration_id,
blocking,
completed_at,
conclusion,
created_at,
details_url,
output,
path,
rerequestable,
started_at,
status,
updated_at
FROM vercel.checks.deployment_checks
WHERE deployment_id = '{{ deployment_id }}' -- required
AND check_id = '{{ check_id }}' -- required
AND team_id = '{{ team_id }}'
AND slug = '{{ slug }}'
;

INSERT examples

Creates a new check. This endpoint must be called with an OAuth2 or it will produce a 400 error.

INSERT INTO vercel.checks.deployment_checks (
name,
path,
blocking,
details_url,
external_id,
rerequestable,
deployment_id,
team_id,
slug
)
SELECT
'{{ name }}' /* required */,
'{{ path }}',
{{ blocking }} /* required */,
'{{ details_url }}',
'{{ external_id }}',
{{ rerequestable }},
'{{ deployment_id }}',
'{{ team_id }}',
'{{ slug }}'
RETURNING
id,
name,
deployment_id,
external_id,
integration_id,
blocking,
completed_at,
conclusion,
created_at,
details_url,
output,
path,
rerequestable,
started_at,
status,
updated_at
;

UPDATE examples

Update an existing check. This endpoint must be called with an OAuth2 or it will produce a 400 error.

UPDATE vercel.checks.deployment_checks
SET
name = '{{ name }}',
path = '{{ path }}',
status = '{{ status }}',
conclusion = '{{ conclusion }}',
details_url = '{{ details_url }}',
output = '{{ output }}',
external_id = '{{ external_id }}'
WHERE
deployment_id = '{{ deployment_id }}' --required
AND check_id = '{{ check_id }}' --required
AND team_id = '{{ team_id}}'
AND slug = '{{ slug}}'
RETURNING
id,
name,
deployment_id,
external_id,
integration_id,
blocking,
completed_at,
conclusion,
created_at,
details_url,
output,
path,
rerequestable,
started_at,
status,
updated_at;

Lifecycle Methods

EXEC variables use wire (API) names.

Rerequest a selected check that has failed.

EXEC vercel.checks.deployment_checks.rerequest
@deployment_id='{{ deployment_id }}' --required,
@check_id='{{ check_id }}' --required,
@autoUpdate={{ autoUpdate }},
@teamId='{{ teamId }}',
@slug='{{ slug }}'
;