Netlify
List sites and trigger deploys on Netlify. In Appbricx, your workflows and server functions call it by name once it is connected.
What you can do
4 actions, each one call from a workflow or a server function. Triggers come from your app: a row changing, a schedule or a webhook.
- Start DeployTriggers a new build for a site on Netlify. Supports clearing build cache.
start_deploy - Get SiteGet a specified site. Note: Environment variable keys and values have moved from build_settings.env and repo.env to a new endpoint. Please use getEnvVars to retrieve site environment variables.
get_site - List FilesReturns a list of all the files in the current deploy.
list_files - List Site DeploysReturns a list of all deploys for a specific site.
list_site_deploys
Set it up
About two minutes, once per project or once for the whole workspace.
- Open Integrations in the builder
Backend panel, Integrations tab, then Netlify. To connect it for every project, use Workspace settings, Integrations.
- Add your credentials
An API key (or token) from your Netlify account, pasted once. It is stored encrypted and only read on the server when an action runs.
- API key From Netlify's settings
- Call an action
From a workflow, by integration id and action name. The call answers with success, output and, when it fails, the reason.
Workflow // .workflow.js (native ctx) export async function run(ctx) { const res = await ctx.integrations.invoke("netlify", "start_deploy", { "siteId": "<siteId>" }); if (!res.success) throw new Error(res.error); ctx.log.info("Netlify answered", { output: res.output }); }
More in Developer tools
Netlify and its logo are trademarks of their owner, shown only to identify the service this integration connects to. Their use does not imply endorsement by, or affiliation with, that company.