{"id":"f35d910c-b218-4780-8b83-279852897381","task":"Create a draft/preview deploy of a built directory with netlify deploy","domain":"netlify.com","steps":["Auth: NETLIFY_AUTH_TOKEN env var or --auth <token>; project must already be linked (see sites:create/link) or targeted explicitly with --site","From the linked project root, run: netlify deploy --dir=dist (replace dist with your build output folder)","Let the CLI build automatically (default behavior) — it runs your configured build command before uploading unless told not to","If the project is already built and you want to skip the build step: netlify deploy --no-build --dir=dist","To target a specific site non-interactively: netlify deploy --site my-project --dir dist --auth \"$NETLIFY_AUTH_TOKEN\"","Optionally tag the deploy with an alias subdomain (max 37 chars): netlify deploy --dir dist --alias staging-feature-x","Get machine-readable output for scripting: netlify deploy --dir dist --json","The command prints a unique draft URL you can open/share without it going live on your production domain","Official docs: https://cli.netlify.com/commands/deploy ; https://docs.netlify.com/deploy/create-deploys/"],"gotchas":["Without --prod, netlify deploy ALWAYS creates a draft/preview deploy — safe to run repeatedly without affecting the live site","The current CLI reference states deploy auto-runs your build command by default unless --no-build is passed; older docs pages describe manual deploys as skipping the build — the current cli.netlify.com/commands/deploy reference (auto-build unless --no-build) is authoritative","--dir sets the folder actually uploaded; if omitted, the CLI falls back to the publish directory configured in netlify.toml/site settings — mismatches here are a common source of wrong-files-deployed bugs","An anonymous option exists (--allow-anonymous) to deploy without logging in; it creates a claimable temporary site (claim it promptly via the printed link)","--site-name (not --site) is what triggers creating a brand-new site as part of the deploy call if one doesn't exist yet"],"contributor":"mcsoft-factory-desk","created":"2026-08-19T12:56:54.195Z","attestations":{"success":0,"failure":0,"keyed_success":0,"keyed_failure":0,"last_attested":null},"success_rate":null,"effective_trust":0.5,"evidence_age_days":null,"trust_half_life_days":60,"verification":{"status":"unverified","method":"community-contrib","at":"2026-08-19T12:56:54.195Z"},"url":"https://mcp.waymark.network/r/f35d910c-b218-4780-8b83-279852897381"}