Netlify
App · Website Builders · 20 actions
Host and deploy websites on Netlify. Manage sites and their build settings, trigger deploys with build hooks, check whether the latest deploy succeeded, set environment variables, inject snippets, and read form submissions.
Actions
| Action | What it does |
|---|---|
| Create build hook | Create a build hook and return its URL. |
| Create environment variable | Create an environment variable for a team, or for one site when you pick a site. |
| Create site | Create a Netlify site. |
| Create site snippet | Inject HTML into this site's pages without redeploying it - an analytics tag, a chat widget, a meta tag. |
| Delete build hook | Delete a build hook. |
| Delete environment variable | Delete an environment variable and every deploy-context value it holds. |
| Delete site | Delete a site permanently, along with every deploy, form submission and environment variable belonging to it. |
| Delete site snippet | Stop injecting a snippet and remove it. |
| Get site | Read one site in full: its name and URLs, custom domain and domain aliases, team, build command and publish directory, SSL settings, and the deploy currently published on it. |
| List build hooks | List a site's build hooks. |
| List environment variables | List a team's environment variables, or one site's when you pick a site. |
| List form submissions | List every submission across all of a site's forms, newest first. |
| List site deploys | List a site's deploys, newest first. |
| List site forms | List the forms Netlify detected in this site's deployed HTML, with each form's name, the paths it appears on, the fields it collects and how many submissions it has received. |
| List site snippets | List the HTML snippets Netlify injects into this site's pages after each deploy - analytics tags, chat widgets and the like - with the code each one injects and where it goes. |
| List sites | List the sites the connected Netlify account can see. |
| Set environment variable value | Change an existing variable's value for one deploy context, leaving its other contexts alone. |
| Update build hook | Rename a build hook or point it at a different branch. |
| Update site | Change a site's settings: rename it, set or clear its custom domain and domain aliases, put it behind a password, change where build notifications go, force HTTPS, or change the build command, publish directory and functions directory. |
| Update site snippet | Change an injected snippet - its code, where that code goes, or its name. |
Create build hook
Create a build hook and return its URL. POSTing to that URL rebuilds and redeploys the site with no credentials, which is how a workflow triggers a Netlify deploy: create the hook once, then call its URL whenever the content it publishes changes. Treat the URL as a secret - anyone who has it can trigger a deploy.
Inputs
- Site
site_idtextRequired - The site to act on. Pick one, or paste a site ID, a site domain such as my-site.netlify.app, or a Netlify admin URL.
- Title
titletextRequired - What this hook is for, shown in the Netlify UI, such as 'Nightly rebuild'.
- Branch
branchtext - The branch to build. Defaults to the site's production branch.
Outputs
branchtextcreated_attextdrafttrue/falseidtextmsgtextsite_idtexttitletexturltext
Example output
{
"branch": "main",
"created_at": "2026-02-02T17:02:24.000Z",
"draft": false,
"id": "67a4c2f09f0b2c00081234cd",
"msg": "POST https://api.netlify.com/build_hooks/67a4c2f09f0b2c00081234cd to trigger a build",
"site_id": "a1b2c3d4-5e6f-7890-abcd-ef1234567890",
"title": "Nightly rebuild",
"url": "https://api.netlify.com/build_hooks/67a4c2f09f0b2c00081234cd"
}Create environment variable
Create an environment variable for a team, or for one site when you pick a site. Set which deploy contexts the value applies to. Builds already running do not pick it up - the next deploy does. Scopes and Secret both need a paid Netlify plan; on a free plan leave them empty and Netlify makes the variable readable everywhere.
Inputs
- Team
account_idtextRequired - The team that owns the variable. Netlify keeps environment variables on the team, not on the site.
- Variable name
keytextRequired - The variable's name. Must start with a letter or underscore and contain only letters, numbers and underscores.
- Value
valuetextRequired - The value to store.
- Site
site_idtext - Limit this to one site's own variables. Leave empty to work with the team-wide variables that every site inherits.
- Deploy context
contexttext - Which deploys this value applies to. Defaults to all of them.One of:
all(All deploy contexts),production,deploy-preview(Deploy previews),branch-deploy(Branch deploys),branch(One specific branch),dev(Local development (netlify dev)). Default:all. - Branch name
context_parametertext - The branch this value applies to. Required when the deploy context is 'One specific branch', and ignored otherwise.
- Scopes
scopeslist - Which parts of the pipeline can read it. Needs a paid Netlify plan - leave empty on a free plan, which gives it all four.One or more of:
builds,functions,runtime,post-processing(Post processing). - Secret
is_secrettrue/false - Hide the value from the Netlify UI, the API and build logs; it cannot be read back afterwards. Needs a paid Netlify plan, because a secret has to have its scopes restricted.
Outputs
is_secrettrue/falsekeytextscopeslistupdated_attextupdated_byobjectvalueslist
Example output
{
"is_secret": false,
"key": "API_BASE_URL",
"scopes": [
"builds",
"functions",
"runtime",
"post-processing"
],
"updated_at": "2026-02-02T17:05:53.000Z",
"values": [
{
"context": "all",
"id": "67a4c3419f0b2c00081234ef",
"value": "https://api.example.com"
}
]
}Create site
Create a Netlify site. The name becomes its netlify.app subdomain and must be unique across all of Netlify; leave it empty to let Netlify invent one. Leave the team empty to create it in the token owner's own team. The site starts with no deploys - link a repository, or use a build hook, to give it one.
Inputs
- Site name
nametext - Lowercase letters, numbers and hyphens, up to 63 characters. Becomes <name>.netlify.app, so it must be free across all of Netlify. Leave empty for a generated name.
- Team
account_slugtext - The team to create it in. Leave empty for your own.
- Custom domain
custom_domaintext - A domain you already own, to serve the site on.
- Password
passwordtext - Require this password to view the site. Leave empty for a public site.
- Force HTTPS
force_ssltrue/false - Redirect every HTTP request to HTTPS.
- Build command
build_commandtext - The command Netlify runs to build the site, such as 'npm run build'. Leave empty to leave it alone.
- Publish directory
publish_directorytext - The directory the build writes the finished site into, such as 'dist' or 'build'.
- Functions directory
functions_directorytext - The directory holding the site's serverless functions.
Outputs
account_idtextaccount_nametextaccount_slugtextadmin_urltextbranch_deploy_custom_domaintextbuild_imagetextbuild_settingsobjectcreated_attextcustom_domaintextdeploy_hooktextdeploy_preview_custom_domaintextdeploy_urltextdomain_aliaseslistforce_ssltrue/falsefunctions_regiontextgit_providertextidtextid_domaintextmanaged_dnstrue/falsenametextnotification_emailtextpasswordtextplantextprerendertextprevent_non_git_prod_deploystrue/falsepublished_deployobjectscreenshot_urltextsession_idtextssltrue/falsessl_urltextstatetextupdated_attexturltextuser_idtext
Example output
{
"account_id": "5f2c9a1b3d4e5f6a7b8c9d0e",
"account_name": "Ada's team",
"account_slug": "adas-team",
"admin_url": "https://app.netlify.com/projects/lodol-demo",
"build_settings": {
"cmd": "npm run build",
"dir": "dist"
},
"created_at": "2026-01-14T09:12:44.000Z",
"id": "a1b2c3d4-5e6f-7890-abcd-ef1234567890",
"name": "lodol-demo",
"plan": "nf_team_dev",
"ssl_url": "https://lodol-demo.netlify.app",
"state": "current",
"updated_at": "2026-02-02T16:41:08.000Z",
"url": "http://lodol-demo.netlify.app"
}Create site snippet
Inject HTML into this site's pages without redeploying it - an analytics tag, a chat widget, a meta tag. 'Code' goes into every page; 'Thank-you page code' goes only into the page a form submission lands on. Give at least one of the two. The code is injected on the next deploy and on every page served after it.
Inputs
- Site
site_idtextRequired - The site to act on. Pick one, or paste a site ID, a site domain such as my-site.netlify.app, or a Netlify admin URL.
- Title
titletextRequired - What this snippet is for, shown in the Netlify UI.
- Code
generaltext - HTML to inject into every page, such as a <script> tag. Leave empty to inject only into the thank-you page.
- Position
general_positiontext - Where the code goes in every page. Defaults to the head element.One of:
head(In the <head> element),footer(Before the closing </body> tag). Default:head. - Thank-you page code
goaltext - HTML to inject only into the page shown after a form is submitted - a conversion tag, typically.
- Thank-you page position
goal_positiontext - Where the thank-you page code goes. Defaults to the head element.One of:
head(In the <head> element),footer(Before the closing </body> tag). Default:head.
Outputs
generaltextgeneral_positiontextgoaltextgoal_positiontextidtextsite_idtexttitletext
Example output
{
"general": "<script defer src=\"https://example.com/a.js\"></script>",
"general_position": "head",
"id": "1",
"site_id": "a1b2c3d4-5e6f-7890-abcd-ef1234567890",
"title": "Analytics"
}Delete build hook
Delete a build hook. Its URL stops working immediately, so anything still calling it will start failing.
Inputs
- Site
site_idtextRequired - The site to act on. Pick one, or paste a site ID, a site domain such as my-site.netlify.app, or a Netlify admin URL.
- Build hook ID
build_hook_idtextRequired - The build hook to act on, from 'List build hooks'.
Outputs
account_idtextdeletedtrue/falseidtextresourcetextsite_idtext
Example output
{
"deleted": true,
"id": "67a4c2f09f0b2c00081234cd",
"resource": "build_hook",
"site_id": "a1b2c3d4-5e6f-7890-abcd-ef1234567890"
}Delete environment variable
Delete an environment variable and every deploy-context value it holds. Builds after this one will not see it, which will break anything that reads it.
Inputs
- Team
account_idtextRequired - The team that owns the variable. Netlify keeps environment variables on the team, not on the site.
- Variable name
keytextRequired - The variable's name. Must start with a letter or underscore and contain only letters, numbers and underscores.
- Site
site_idtext - Limit this to one site's own variables. Leave empty to work with the team-wide variables that every site inherits.
Outputs
account_idtextdeletedtrue/falseidtextresourcetextsite_idtext
Example output
{
"account_id": "5f2c9a1b3d4e5f6a7b8c9d0e",
"deleted": true,
"id": "API_BASE_URL",
"resource": "environment_variable"
}Delete site
Delete a site permanently, along with every deploy, form submission and environment variable belonging to it. This cannot be undone, and the site's netlify.app subdomain becomes available for anyone to claim.
Inputs
- Site
site_idtextRequired - The site to act on. Pick one, or paste a site ID, a site domain such as my-site.netlify.app, or a Netlify admin URL.
Outputs
account_idtextdeletedtrue/falseidtextresourcetextsite_idtext
Example output
{
"deleted": true,
"id": "a1b2c3d4-5e6f-7890-abcd-ef1234567890",
"resource": "site"
}Delete site snippet
Stop injecting a snippet and remove it. The code disappears from the site's pages on the next deploy.
Inputs
- Site
site_idtextRequired - The site to act on. Pick one, or paste a site ID, a site domain such as my-site.netlify.app, or a Netlify admin URL.
- Snippet ID
snippet_idtextRequired - The snippet to act on, from 'List site snippets'.
Outputs
account_idtextdeletedtrue/falseidtextresourcetextsite_idtext
Example output
{
"deleted": true,
"id": "481920",
"resource": "snippet",
"site_id": "a1b2c3d4-5e6f-7890-abcd-ef1234567890"
}Get site
Read one site in full: its name and URLs, custom domain and domain aliases, team, build command and publish directory, SSL settings, and the deploy currently published on it.
Inputs
- Site
site_idtextRequired - The site to act on. Pick one, or paste a site ID, a site domain such as my-site.netlify.app, or a Netlify admin URL.
Outputs
account_idtextaccount_nametextaccount_slugtextadmin_urltextbranch_deploy_custom_domaintextbuild_imagetextbuild_settingsobjectcreated_attextcustom_domaintextdeploy_hooktextdeploy_preview_custom_domaintextdeploy_urltextdomain_aliaseslistforce_ssltrue/falsefunctions_regiontextgit_providertextidtextid_domaintextmanaged_dnstrue/falsenametextnotification_emailtextpasswordtextplantextprerendertextprevent_non_git_prod_deploystrue/falsepublished_deployobjectscreenshot_urltextsession_idtextssltrue/falsessl_urltextstatetextupdated_attexturltextuser_idtext
Example output
{
"account_id": "5f2c9a1b3d4e5f6a7b8c9d0e",
"account_name": "Ada's team",
"account_slug": "adas-team",
"admin_url": "https://app.netlify.com/projects/lodol-demo",
"build_settings": {
"cmd": "npm run build",
"dir": "dist"
},
"created_at": "2026-01-14T09:12:44.000Z",
"id": "a1b2c3d4-5e6f-7890-abcd-ef1234567890",
"name": "lodol-demo",
"plan": "nf_team_dev",
"ssl_url": "https://lodol-demo.netlify.app",
"state": "current",
"updated_at": "2026-02-02T16:41:08.000Z",
"url": "http://lodol-demo.netlify.app"
}List build hooks
List a site's build hooks. Each one carries the URL that triggers a deploy of its branch when something POSTs to it, with no credentials needed.
Inputs
- Site
site_idtextRequired - The site to act on. Pick one, or paste a site ID, a site domain such as my-site.netlify.app, or a Netlify admin URL.
Outputs
The site's build hooks
countnumber- How many were returned
itemslist
Example output
{
"count": 1,
"items": [
{
"branch": "main",
"created_at": "2026-02-02T17:02:24.000Z",
"draft": false,
"id": "67a4c2f09f0b2c00081234cd",
"msg": "POST https://api.netlify.com/build_hooks/67a4c2f09f0b2c00081234cd to trigger a build",
"site_id": "a1b2c3d4-5e6f-7890-abcd-ef1234567890",
"title": "Nightly rebuild",
"url": "https://api.netlify.com/build_hooks/67a4c2f09f0b2c00081234cd"
}
]
}List environment variables
List a team's environment variables, or one site's when you pick a site. Each one reports its value per deploy context, which parts of the pipeline can read it, and who changed it last. A variable marked secret comes back without its value - Netlify never reads a secret back.
Inputs
- Team
account_idtextRequired - The team that owns the variable. Netlify keeps environment variables on the team, not on the site.
- Site
site_idtext - Limit this to one site's own variables. Leave empty to work with the team-wide variables that every site inherits.
- Deploy context
context_nametext - Only variables set for this deploy context.One of:
all(All deploy contexts),production,deploy-preview(Deploy previews),branch-deploy(Branch deploys),dev(Local development (netlify dev)). - Scope
scopetext - Only variables readable at this point in the pipeline.One of:
builds,functions,runtime,post-processing(Post processing).
Outputs
The environment variables
countnumber- How many were returned
itemslist
Example output
{
"count": 1,
"items": [
{
"is_secret": false,
"key": "API_BASE_URL",
"scopes": [
"builds",
"functions",
"runtime",
"post-processing"
],
"updated_at": "2026-02-02T17:05:53.000Z",
"values": [
{
"context": "all",
"id": "67a4c3419f0b2c00081234ef",
"value": "https://api.example.com"
}
]
}
]
}List form submissions
List every submission across all of a site's forms, newest first. Each one carries the submitter's name, email and company where Netlify recognised those fields, and the whole submitted payload under 'data'. Use it to push new form submissions into a CRM or a spreadsheet.
Inputs
- Site
site_idtextRequired - The site to act on. Pick one, or paste a site ID, a site domain such as my-site.netlify.app, or a Netlify admin URL.
- Page
pagenumber - Which page to read. Defaults to the first.From 1 to 1000000. Default:
1. - Results per page
per_pagenumber - How many to return, 1-100. Defaults to 50.From 1 to 100. Default:
50.
Outputs
The site's form submissions, newest first
countnumber- Records on this page
has_moretrue/false- Whether Netlify has another page
itemslistnext_pagenumber- The page to ask for next, or empty at the end
pagenumber- The page that was read
per_pagenumber- The page size used
Example output
{
"count": 1,
"has_more": false,
"items": [
{
"created_at": "2026-02-01T08:44:02.000Z",
"data": {
"email": "ada@example.com",
"message": "Hello from the contact form"
},
"email": "ada@example.com",
"id": "67a4c3e29f0b2c0008123511",
"name": "Ada Lovelace",
"number": 12,
"site_url": "https://lodol-demo.netlify.app",
"summary": "Hello from the contact form"
}
],
"next_page": null,
"page": 1,
"per_page": 50
}List site deploys
List a site's deploys, newest first. Each one reports its state ('ready', 'building', 'error' and so on), the branch and commit it came from, its own preview URL, when it was created and published, and the error message if it failed. Read the first one to check whether the latest deploy worked.
Inputs
- Site
site_idtextRequired - The site to act on. Pick one, or paste a site ID, a site domain such as my-site.netlify.app, or a Netlify admin URL.
- Page
pagenumber - Which page to read. Defaults to the first.From 1 to 1000000. Default:
1. - Results per page
per_pagenumber - How many to return, 1-100. Defaults to 50.From 1 to 100. Default:
50.
Outputs
The site's deploys, newest first
countnumber- Records on this page
has_moretrue/false- Whether Netlify has another page
itemslistnext_pagenumber- The page to ask for next, or empty at the end
pagenumber- The page that was read
per_pagenumber- The page size used
Example output
{
"count": 1,
"has_more": false,
"items": [
{
"branch": "main",
"context": "production",
"created_at": "2026-02-02T16:40:11.000Z",
"deploy_ssl_url": "https://67a4c1de.lodol-demo.netlify.app",
"id": "67a4c1de9f0b2c00081234ab",
"name": "lodol-demo",
"published_at": "2026-02-02T16:41:08.000Z",
"site_id": "a1b2c3d4-5e6f-7890-abcd-ef1234567890",
"state": "ready"
}
],
"next_page": null,
"page": 1,
"per_page": 50
}List site forms
List the forms Netlify detected in this site's deployed HTML, with each form's name, the paths it appears on, the fields it collects and how many submissions it has received. A form only appears here after a deploy that contains it.
Inputs
- Site
site_idtextRequired - The site to act on. Pick one, or paste a site ID, a site domain such as my-site.netlify.app, or a Netlify admin URL.
Outputs
The site's forms
countnumber- How many were returned
itemslist
Example output
{
"count": 1,
"items": [
{
"created_at": "2026-01-20T11:03:19.000Z",
"id": "67a4c3b19f0b2c0008123500",
"name": "contact",
"paths": [
"/contact"
],
"site_id": "a1b2c3d4-5e6f-7890-abcd-ef1234567890",
"submission_count": 12
}
]
}List site snippets
List the HTML snippets Netlify injects into this site's pages after each deploy - analytics tags, chat widgets and the like - with the code each one injects and where it goes.
Inputs
- Site
site_idtextRequired - The site to act on. Pick one, or paste a site ID, a site domain such as my-site.netlify.app, or a Netlify admin URL.
Outputs
The site's snippets
countnumber- How many were returned
itemslist
Example output
{
"count": 1,
"items": [
{
"general": "<script defer src=\"https://example.com/a.js\"></script>",
"general_position": "head",
"id": "1",
"site_id": "a1b2c3d4-5e6f-7890-abcd-ef1234567890",
"title": "Analytics"
}
]
}List sites
List the sites the connected Netlify account can see. Returns each site's name, ID, primary and deploy URLs, plan, team, build settings and its currently published deploy. Narrow by name, or to just the sites you own.
Inputs
- Name
nametext - Only sites whose name contains this text. Leave empty for all of them.
- Ownership
filter_bytext - Narrow to the sites you own, or were invited to.One of:
all(Every site I can see),owner(Sites I own),guest(Sites I was invited to). - Page
pagenumber - Which page to read. Defaults to the first.From 1 to 1000000. Default:
1. - Results per page
per_pagenumber - How many to return, 1-100. Defaults to 50.From 1 to 100. Default:
50.
Outputs
The sites, newest first
countnumber- Records on this page
has_moretrue/false- Whether Netlify has another page
itemslistnext_pagenumber- The page to ask for next, or empty at the end
pagenumber- The page that was read
per_pagenumber- The page size used
Example output
{
"count": 1,
"has_more": false,
"items": [
{
"account_id": "5f2c9a1b3d4e5f6a7b8c9d0e",
"account_name": "Ada's team",
"account_slug": "adas-team",
"admin_url": "https://app.netlify.com/projects/lodol-demo",
"build_settings": {
"cmd": "npm run build",
"dir": "dist"
},
"created_at": "2026-01-14T09:12:44.000Z",
"id": "a1b2c3d4-5e6f-7890-abcd-ef1234567890",
"name": "lodol-demo",
"plan": "nf_team_dev",
"ssl_url": "https://lodol-demo.netlify.app",
"state": "current",
"updated_at": "2026-02-02T16:41:08.000Z",
"url": "http://lodol-demo.netlify.app"
}
],
"next_page": null,
"page": 1,
"per_page": 50
}Set environment variable value
Change an existing variable's value for one deploy context, leaving its other contexts alone. The variable must already exist, and you must pick a single context - Netlify does not accept 'all deploy contexts' here. Setting one context on a variable created for all of them splits it into one value per context. The new value takes effect on the next deploy, not on builds already running.
Inputs
- Team
account_idtextRequired - The team that owns the variable. Netlify keeps environment variables on the team, not on the site.
- Variable name
keytextRequired - The variable's name. Must start with a letter or underscore and contain only letters, numbers and underscores.
- Value
valuetextRequired - The value to store.
- Site
site_idtext - Limit this to one site's own variables. Leave empty to work with the team-wide variables that every site inherits.
- Deploy context
contexttextRequired - Which deploys this value applies to. Netlify sets one context at a time here, so pick exactly one - 'all deploy contexts' is only available when the variable is first created.One of:
production,deploy-preview(Deploy previews),branch-deploy(Branch deploys),branch(One specific branch),dev(Local development (netlify dev)). - Branch name
context_parametertext - The branch this value applies to. Required when the deploy context is 'One specific branch', and ignored otherwise.
Outputs
is_secrettrue/falsekeytextscopeslistupdated_attextupdated_byobjectvalueslist
Example output
{
"is_secret": false,
"key": "API_BASE_URL",
"scopes": [
"builds",
"functions",
"runtime",
"post-processing"
],
"updated_at": "2026-02-02T17:05:53.000Z",
"values": [
{
"context": "all",
"id": "67a4c3419f0b2c00081234ef",
"value": "https://api.example.com"
}
]
}Update build hook
Rename a build hook or point it at a different branch. The hook's URL does not change, so anything already calling it keeps working and starts building the new branch.
Inputs
- Site
site_idtextRequired - The site to act on. Pick one, or paste a site ID, a site domain such as my-site.netlify.app, or a Netlify admin URL.
- Build hook ID
build_hook_idtextRequired - The build hook to act on, from 'List build hooks'.
- Title
titletext - A new name for the hook.
- Branch
branchtext - The branch it should build from now on.
Outputs
branchtextcreated_attextdrafttrue/falseidtextmsgtextsite_idtexttitletexturltext
Example output
{
"branch": "main",
"created_at": "2026-02-02T17:02:24.000Z",
"draft": false,
"id": "67a4c2f09f0b2c00081234cd",
"msg": "POST https://api.netlify.com/build_hooks/67a4c2f09f0b2c00081234cd to trigger a build",
"site_id": "a1b2c3d4-5e6f-7890-abcd-ef1234567890",
"title": "Nightly rebuild",
"url": "https://api.netlify.com/build_hooks/67a4c2f09f0b2c00081234cd"
}Update site
Change a site's settings: rename it, set or clear its custom domain and domain aliases, put it behind a password, change where build notifications go, force HTTPS, or change the build command, publish directory and functions directory. Only the fields you fill in are sent; the rest are left alone. Renaming changes the site's netlify.app subdomain.
Inputs
- Site
site_idtextRequired - The site to act on. Pick one, or paste a site ID, a site domain such as my-site.netlify.app, or a Netlify admin URL.
- Site name
nametext - A new name. Lowercase letters, numbers and hyphens; this changes the netlify.app subdomain the site is served on.
- Custom domain
custom_domaintext - The primary domain to serve the site on.
- Domain aliases
domain_aliaseslist - Other domains that should also serve this site. Replaces the current list.
- Password
passwordtext - Require this password to view the site.
- Notification email
notification_emailtext - Where Netlify sends this site's build notifications.
- Force HTTPS
force_ssltrue/false - Redirect every HTTP request to HTTPS.
- Build command
build_commandtext - The command Netlify runs to build the site, such as 'npm run build'. Leave empty to leave it alone.
- Publish directory
publish_directorytext - The directory the build writes the finished site into, such as 'dist' or 'build'.
- Functions directory
functions_directorytext - The directory holding the site's serverless functions.
Outputs
account_idtextaccount_nametextaccount_slugtextadmin_urltextbranch_deploy_custom_domaintextbuild_imagetextbuild_settingsobjectcreated_attextcustom_domaintextdeploy_hooktextdeploy_preview_custom_domaintextdeploy_urltextdomain_aliaseslistforce_ssltrue/falsefunctions_regiontextgit_providertextidtextid_domaintextmanaged_dnstrue/falsenametextnotification_emailtextpasswordtextplantextprerendertextprevent_non_git_prod_deploystrue/falsepublished_deployobjectscreenshot_urltextsession_idtextssltrue/falsessl_urltextstatetextupdated_attexturltextuser_idtext
Example output
{
"account_id": "5f2c9a1b3d4e5f6a7b8c9d0e",
"account_name": "Ada's team",
"account_slug": "adas-team",
"admin_url": "https://app.netlify.com/projects/lodol-demo",
"build_settings": {
"cmd": "npm run build",
"dir": "dist"
},
"created_at": "2026-01-14T09:12:44.000Z",
"id": "a1b2c3d4-5e6f-7890-abcd-ef1234567890",
"name": "lodol-demo",
"plan": "nf_team_dev",
"ssl_url": "https://lodol-demo.netlify.app",
"state": "current",
"updated_at": "2026-02-02T16:41:08.000Z",
"url": "http://lodol-demo.netlify.app"
}Update site snippet
Change an injected snippet - its code, where that code goes, or its name. Only the fields you fill in are sent. The change takes effect on the next deploy.
Inputs
- Site
site_idtextRequired - The site to act on. Pick one, or paste a site ID, a site domain such as my-site.netlify.app, or a Netlify admin URL.
- Snippet ID
snippet_idtextRequired - The snippet to act on, from 'List site snippets'.
- Title
titletext - A new name for the snippet.
- Code
generaltext - New HTML to inject into every page.
- Position
general_positiontext - Where the code goes in every page. Defaults to the head element.One of:
head(In the <head> element),footer(Before the closing </body> tag). Default:head. - Thank-you page code
goaltext - New HTML to inject into the form thank-you page.
- Thank-you page position
goal_positiontext - Where the thank-you page code goes. Defaults to the head element.One of:
head(In the <head> element),footer(Before the closing </body> tag). Default:head.
Outputs
generaltextgeneral_positiontextgoaltextgoal_positiontextidtextsite_idtexttitletext
Example output
{
"general": "<script defer src=\"https://example.com/a.js\"></script>",
"general_position": "head",
"id": "1",
"site_id": "a1b2c3d4-5e6f-7890-abcd-ef1234567890",
"title": "Analytics"
}