Skip to main content

events

Creates, updates, deletes, gets or lists an events resource.

Overview

Nameevents
TypeResource
Idvercel.deployments.events

Fields

The following fields are returned by SELECT queries:

A stream of jsonlines where each line is a deployment log item.
Array of deployment logs for the provided query.

NameDatatypeDescription

Methods

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
get_deployment_eventsselectidOrUrl, teamIddirection, follow, limit, name, since, until, statusCode, delimiter, buildsGet the build logs of a deployment by deployment ID and build ID. It can work as an infinite stream of logs or as a JSON endpoint depending on the input parameters.

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
idOrUrlstringThe unique identifier or hostname of the deployment.
teamIdstringThe Team identifier or slug to perform the request on behalf of.
buildsnumber
delimiternumber
directionstringOrder of the returned events based on the timestamp.
follownumberWhen enabled, this endpoint will return live events as they happen.
limitnumberMaximum number of events to return. Provide -1 to return all available logs.
namestringDeployment build ID.
sincenumberTimestamp for when build logs should be pulled from.
statusCodeHTTP status code range to filter events by.
untilnumberTimestamp for when the build logs should be pulled up until.

SELECT examples

Get the build logs of a deployment by deployment ID and build ID. It can work as an infinite stream of logs or as a JSON endpoint depending on the input parameters.

SELECT
*
FROM vercel.deployments.events
WHERE idOrUrl = '{{ idOrUrl }}' -- required
AND teamId = '{{ teamId }}' -- required
AND direction = '{{ direction }}'
AND follow = '{{ follow }}'
AND limit = '{{ limit }}'
AND name = '{{ name }}'
AND since = '{{ since }}'
AND until = '{{ until }}'
AND statusCode = '{{ statusCode }}'
AND delimiter = '{{ delimiter }}'
AND builds = '{{ builds }}'
;