Skip to content
Docs Try Aspire

AtsCapabilityInfo

Class sealed net8.0
📦 Aspire.TypeSystem v13.2.0
Represents a discovered [AspireExport] capability.
namespace Aspire.TypeSystem;
public sealed class AtsCapabilityInfo
{
// ...
}

This model is shared between code generation (using RoMethod/RoType metadata reflection) and the runtime CapabilityDispatcher (using System.Reflection).

The capability represents a single exportable method that can be invoked via invokeCapability(capabilityId, args) from polyglot clients.

View all constructors
CapabilityIdget; init
string
Gets or sets the capability ID (e.g., "Aspire.Hosting/addRedis").
CapabilityKindget; init
Gets or sets the kind of capability (Method, PropertyGetter, PropertySetter, InstanceMethod).
Descriptionget; init
string?
Gets or sets the description of what this capability does.
ExpandedTargetTypesget; set
Gets or sets the expanded list of concrete types this capability applies to. Pre-computed during scanning by resolving interface targets to all implementing types.
MethodNameget; set
string
Gets or sets the simple method name for generated SDKs (e.g., "addRedis", "isRunMode"). For context type capabilities, this is just the property/method name without the type prefix.
OwningTypeNameget; init
string?
Gets or sets the owning type name for property/method capabilities.
Parametersget; init
Gets or sets the parameters for this capability.
QualifiedMethodNameget
string
Gets the qualified method name combining OwningTypeName and MethodName.
ReturnsBuilderget; init
bool
Gets or sets whether the return type is a builder type.
ReturnTypeget; init
Gets or sets the return type reference with full type metadata. Use AtsConstants.Void TypeId for void return types.
RunSyncOnBackgroundThreadget; init
bool
Gets or sets whether synchronous invocations of this capability should run on a background thread.
SourceLocationget; init
string?
Gets or sets the source location where this capability is defined.
TargetParameterNameget; init
string?
Gets or sets the name of the target parameter (e.g., "builder", "resource"). This is the first parameter of the method that represents the target/receiver.
TargetTypeget; init
Gets or sets the target type reference with full type metadata.
TargetTypeIdget; init
string?
Gets or sets the original (declared) ATS type ID that this capability targets. May be an interface type (e.g., "Aspire.Hosting/IResourceWithEnvironment").
View all properties