Skip to content

Multi-language (Aspire Type System)

Aspire.Hosting.Netlify is annotated with the Aspire Type System attributes so a TypeScript AppHost can consume it directly.

C# memberTS surfaceNotes
PublishAsNetlifySite(builder, NetlifyDeployOptions, authToken)publishAsNetlifySite(jsApp, options, authToken)Canonical export — full options shape.
PublishAsNetlifySite(builder, string dir, authToken)(C# only)Marked [AspireExportIgnore]; TS users pass { dir, noBuild: true } to the canonical overload.
WithNpmCommand(builder, string args)withNpmCommand(npm, args)The no-callback variant.
WithNpmRunCommand(builder, string scriptName)withNpmRunCommand(npm, scriptName)The no-callback variant.
AddNetlifyDeployPipeline(pipeline)addNetlifyDeployPipeline(pipeline)Registers the deploy steps on a pipeline.
NetlifyDeployOptionsNetlifyDeployOptions (DTO)Marked [AspireDto].
NetlifyDeploymentResourceNetlifyDeploymentResourceProperties: name, workingDirectory, options, buildDirectory, siteName, deploymentEnvironment.
NpmCommandResourceNpmCommandResourceSingle property: scriptName.
  • Callback-form overloads of WithNpmCommand / WithNpmRunCommand — inline C# Action<...> callbacks aren’t ATS-friendly.
  • Annotations collections on resources — they’re attached via separate builder methods, not exposed as exported properties.
Terminal window
# In your TypeScript AppHost folder.
aspire restore # regenerates .modules/ from referenced integrations
aspire run # boots the AppHost

If .modules/ is missing or stale, aspire restore is the way back to a known-good state. Inspect .modules/aspire.ts to see the current exported surface.