All skills
openai avatar

/netlify-deploy

@bf9e226 official
by openaiopenai/skills28k stars
1,891

Deploy web projects to Netlify using the Netlify CLI (`npx netlify`). Use when the user asks to deploy, host, publish, or link a site/repo on Netlify, including preview and production deploys.

Use this Skill: https://skilld.dev/gh/openai/skills/netlify-deploy

This session only. Nothing lands on disk.

referencescli-commands.md

≈663 tokens on demand. Your agent reads this file only when SKILL.md points to it.

Netlify CLI Commands Reference

Quick reference for common Netlify CLI commands used in deployments.

Authentication

# Login via browser OAuth
npx netlify login

# Check authentication status and site link
npx netlify status

# Logout
npx netlify logout

Site Management

# Link current directory to existing site
npx netlify link

# Link by Git remote URL
npx netlify link --git-remote-url <url>

# Create and link new site
npx netlify init

# Unlink from current site
npx netlify unlink

# Open site in Netlify dashboard
npx netlify open

# Open site admin panel
npx netlify open:admin

# Open site in browser
npx netlify open:site

Deployment

# Deploy preview/draft (safe for testing)
npx netlify deploy

# Deploy to production
npx netlify deploy --prod

# Deploy with specific directory
npx netlify deploy --dir=dist

# Deploy with message
npx netlify deploy --message="Deploy message"

# List all deploys
npx netlify deploy:list

Development

# Run local dev server with Netlify features
npx netlify dev

# Run local dev server on specific port
npx netlify dev --port 3000

Site Information

# Get site info
npx netlify sites:list

# Get current site info
npx netlify api getSite --data '{"site_id": "YOUR_SITE_ID"}'

Environment Variables

# List environment variables
npx netlify env:list

# Set environment variable
npx netlify env:set KEY value

# Get environment variable value
npx netlify env:get KEY

# Import env vars from file
npx netlify env:import .env

Build

# Show build settings
npx netlify build --dry

# Run build locally
npx netlify build

Functions (Serverless)

# List functions
npx netlify functions:list

# Invoke function locally
npx netlify functions:invoke FUNCTION_NAME

# Create new function
npx netlify functions:create FUNCTION_NAME

Logs

# Stream function logs
npx netlify logs

# View logs for specific function
npx netlify logs:function FUNCTION_NAME

Troubleshooting Commands

# Check CLI version
npx netlify --version

# Get help for any command
npx netlify help [command]

# Check status with verbose output
npx netlify status --verbose

Exit Codes

  • 0 - Success
  • 1 - General error
  • 2 - Authentication error
  • 3 - Site not found
  • 4 - Build failed

Common Flags

  • --json - Output as JSON
  • --silent - Suppress output
  • --debug - Show debug information
  • --force - Skip confirmation prompts

Resources

Source: SKILL.md on GitHub

1 warning16d5 checks · Risk SAFE
  • Gen Agent Trust Hub16d

    This skill automates web project deployments to Netlify using the Netlify CLI. It includes routine security considerations such as executing local build commands and requesting escalated network permissions when required by the environment. These actions are aligned with the skill's intended purpose of hosting and publishing web content. See the detailed analysis for a breakdown of these operational patterns.

  • Socket16d

    No alerts

  • Snyk16d

    Risk: LOW · No issues

  • Runlayer7mo

    6/6 files flagged

  • ZeroLeaks5mo

    Score: 93/100 · 2 sections analyzed

Signed by skilld at bf9e226. This ties the file your Agent reads to that commit on GitHub. It does not review the instructions.

Last checked against GitHub 2 months ago.

Activeupdated 8 months ago
  • CLI
  • netlify
  • deployment
  • hosting
  • web
  • preview-deploy
  • production-deploy
  • netlify-cli

README badge

README badge for openai/skills/netlify-deploy

Deploys web projects to Netlify using the Netlify CLI, handling authentication, site linking, and build configuration detection. Covers preview and production deploys, and works with any framework that has a build command and publish directory.

Generated from the current SKILL.md.

Does this skill require a global Netlify CLI install?
No. The skill uses npx netlify, which downloads and runs the CLI on-demand without requiring a global installation.
What authentication methods does this skill support?
Browser-based OAuth via netlify login (primary) and API key authentication via the NETLIFY_AUTH_TOKEN environment variable.
Can this skill deploy to production and preview environments?
Yes. Use npx netlify deploy for preview/draft deploys and npx netlify deploy --prod for production deployments to the live site URL.
What happens if the project isn't linked to a Netlify site?
The skill attempts to link by Git remote URL, or falls back to npx netlify init to create a new site interactively.
What should I do if deployment fails due to network restrictions?
Rerun the deploy command with sandbox_permissions=require_escalated to grant the skill escalated network access for outbound requests to Netlify.

Generated from the current SKILL.md. These answers refresh after source changes.