Skip to content
Docs Try Aspire

ExternalServiceResource Constructors

Class Constructors 2 members
Represents an external service resource with service discovery capabilities.
Creates a new instance of ExternalServiceResource with a specified name and URI.
public sealed class ExternalServiceResource
{
public ExternalServiceResource(
string name,
Uri uri)
{
// ...
}
}
name string The name of the resource.
uri Uri The URI for the external service.
The URI must be an absolute URI with the absolute path ending with '/'. The URI cannot contain a fragment or query string.
Constructor(string, ParameterResource) Section titled Constructor(string, ParameterResource)
Creates a new instance of ExternalServiceResource with a specified name and URL parameter.
public sealed class ExternalServiceResource
{
public ExternalServiceResource(
string name,
ParameterResource urlParameter)
{
// ...
}
}
name string The name of the resource.
urlParameter ParameterResource The parameter to use for the URL of the external service.