# RuntimeSpec

- Kind: `class`
- Package: [Aspire.TypeSystem](/reference/api/csharp/aspire.typesystem.md)
- Version: `13.4.0`
- Namespace: `Aspire.TypeSystem`
- Target framework: `net8.0`
- Source: [GitHub](https://github.com/microsoft/aspire/blob/a3766e994fd2cba86c8ac60b8a80268cab7e6383/src/Aspire.TypeSystem/RuntimeSpec.cs)

Specifies the runtime execution configuration for a language.

## Definition

```csharp
namespace Aspire.TypeSystem;

public sealed class RuntimeSpec
{
    // ...
}
```

## Constructors

- [RuntimeSpec](/reference/api/csharp/aspire.typesystem/runtimespec/constructors.md#constructor)

## Properties

- [CodeGenLanguage](/reference/api/csharp/aspire.typesystem/runtimespec/properties.md#codegenlanguage) : `string` `get; init` -- Gets the code generation language identifier for the generateCode RPC.
- [DetectionPatterns](/reference/api/csharp/aspire.typesystem/runtimespec/properties.md#detectionpatterns) : `string[]` `get; init` -- Gets the file patterns used to detect this language (e.g., ["apphost.ts"]).
- [DisplayName](/reference/api/csharp/aspire.typesystem/runtimespec/properties.md#displayname) : `string` `get; init` -- Gets the display name for the language (e.g., "TypeScript (Node.js)").
- [Execute](/reference/api/csharp/aspire.typesystem/runtimespec/properties.md#execute) : [CommandSpec](/reference/api/csharp/aspire.typesystem/commandspec.md) `get; init` -- Gets the command to execute the AppHost for run.
- [ExtensionLaunchCapability](/reference/api/csharp/aspire.typesystem/runtimespec/properties.md#extensionlaunchcapability) : `string?` `get; init` -- Gets the extension capability required to launch this language via the VS Code extension. When set (e.g., "node"), the CLI will use the extension launcher if the extension reports this capability. When null, the CLI always uses the default process-based launcher.
- [Initialize](/reference/api/csharp/aspire.typesystem/runtimespec/properties.md#initialize) : `CommandSpec[]?` `get; init` -- Gets the commands to initialize the project environment (e.g., create a virtual environment and install dependencies). Runs once during scaffolding. Null if no initialization is needed.
- [InstallDependencies](/reference/api/csharp/aspire.typesystem/runtimespec/properties.md#installdependencies) : [CommandSpec?](/reference/api/csharp/aspire.typesystem/commandspec.md) `get; init` -- Gets the command to install dependencies. Null if no dependencies to install.
- [Language](/reference/api/csharp/aspire.typesystem/runtimespec/properties.md#language) : `string` `get; init` -- Gets the language identifier (e.g., "TypeScript", "Python").
- [MigrationFiles](/reference/api/csharp/aspire.typesystem/runtimespec/properties.md#migrationfiles) : `Dictionary<string, string>` `get; init` -- Gets files that must exist in the project directory before execution. If a file in this dictionary is missing, the CLI will create it with the provided content. This supports upgrade scenarios where new runtime requirements are introduced.
- [PreExecute](/reference/api/csharp/aspire.typesystem/runtimespec/properties.md#preexecute) : `CommandSpec[]?` `get; init` -- Gets the commands to run before executing or publishing the AppHost. Null if no pre-execution validation is needed. Watch-mode validation should be part of [RuntimeSpec.WatchExecute](/reference/api/csharp/aspire.typesystem/runtimespec/properties.md#watchexecute) when needed.
- [PublishExecute](/reference/api/csharp/aspire.typesystem/runtimespec/properties.md#publishexecute) : [CommandSpec?](/reference/api/csharp/aspire.typesystem/commandspec.md) `get; init` -- Gets the command to execute the AppHost for publish. Null to use Execute with args appended.
- [WatchExecute](/reference/api/csharp/aspire.typesystem/runtimespec/properties.md#watchexecute) : [CommandSpec?](/reference/api/csharp/aspire.typesystem/commandspec.md) `get; init` -- Gets the command to execute the AppHost in watch mode. Null if watch mode not supported.
