Skip to content

DiscoverInstancesRequest

Source code in docs_src/capo_servicediscovery/types/discover_instances_request.py
class DiscoverInstancesRequest(TypedDict, closed=True):
    namespace_name: "capo_servicediscovery.types.namespace_name.NamespaceName"
    """<p>The <code>HttpName</code> name of the namespace. The <code>HttpName</code> is found in the <code>HttpProperties</code> member of the <code>Properties</code> member of the namespace. In most cases, <code>Name</code> and <code>HttpName</code> match. However, if you reuse <code>Name</code> for namespace creation, a generated hash is added to <code>HttpName</code> to distinguish the two.</p>"""
    service_name: "capo_servicediscovery.types.service_name.ServiceName"
    """<p>The name of the service that you specified when you registered the instance.</p>"""
    max_results: NotRequired[
        "capo_servicediscovery.types.discover_max_results.DiscoverMaxResults"
    ]
    """<p>The maximum number of instances that you want Cloud Map to return in the response to a <code>DiscoverInstances</code> request. If you don't specify a value for <code>MaxResults</code>, Cloud Map returns up to 100 instances.</p>"""
    query_parameters: NotRequired["capo_servicediscovery.types.attributes.Attributes"]
    """<p>Filters to scope the results based on custom attributes for the instance (for example, <code>{version=v1, az=1a}</code>). Only instances that match all the specified key-value pairs are returned.</p>"""
    optional_parameters: NotRequired[
        "capo_servicediscovery.types.attributes.Attributes"
    ]
    """<p>Opportunistic filters to scope the results based on custom attributes. If there are instances that match both the filters specified in both the <code>QueryParameters</code> parameter and this parameter, all of these instances are returned. Otherwise, the filters are ignored, and only instances that match the filters that are specified in the <code>QueryParameters</code> parameter are returned.</p>"""
    health_status: NotRequired[
        "capo_servicediscovery.types.health_status_filter.HealthStatusFilter"
    ]
    """<p>The health status of the instances that you want to discover. This parameter is ignored for services that don't have a health check configured, and all instances are returned.</p> <dl> <dt>HEALTHY</dt> <dd> <p>Returns healthy instances.</p> </dd> <dt>UNHEALTHY</dt> <dd> <p>Returns unhealthy instances.</p> </dd> <dt>ALL</dt> <dd> <p>Returns all instances.</p> </dd> <dt>HEALTHY_OR_ELSE_ALL</dt> <dd> <p>Returns healthy instances, unless none are reporting a healthy state. In that case, return all instances. This is also called failing open.</p> </dd> </dl>"""
    owner_account: NotRequired[
        "capo_servicediscovery.types.aws_account_id.AWSAccountId"
    ]
    """<p>The ID of the Amazon Web Services account that owns the namespace associated with the instance, as specified in the namespace <code>ResourceOwner</code> field. For instances associated with namespaces that are shared with your account, you must specify an <code>OwnerAccount</code>.</p>"""

health_status instance-attribute

health_status: NotRequired[HealthStatusFilter]

The health status of the instances that you want to discover. This parameter is ignored for services that don't have a health check configured, and all instances are returned.

HEALTHY

Returns healthy instances.

UNHEALTHY

Returns unhealthy instances.

ALL

Returns all instances.

HEALTHY_OR_ELSE_ALL

Returns healthy instances, unless none are reporting a healthy state. In that case, return all instances. This is also called failing open.

max_results instance-attribute

max_results: NotRequired[DiscoverMaxResults]

The maximum number of instances that you want Cloud Map to return in the response to a DiscoverInstances request. If you don't specify a value for MaxResults, Cloud Map returns up to 100 instances.

namespace_name instance-attribute

namespace_name: NamespaceName

The HttpName name of the namespace. The HttpName is found in the HttpProperties member of the Properties member of the namespace. In most cases, Name and HttpName match. However, if you reuse Name for namespace creation, a generated hash is added to HttpName to distinguish the two.

optional_parameters instance-attribute

optional_parameters: NotRequired[Attributes]

Opportunistic filters to scope the results based on custom attributes. If there are instances that match both the filters specified in both the QueryParameters parameter and this parameter, all of these instances are returned. Otherwise, the filters are ignored, and only instances that match the filters that are specified in the QueryParameters parameter are returned.

owner_account instance-attribute

owner_account: NotRequired[AWSAccountId]

The ID of the Amazon Web Services account that owns the namespace associated with the instance, as specified in the namespace ResourceOwner field. For instances associated with namespaces that are shared with your account, you must specify an OwnerAccount.

query_parameters instance-attribute

query_parameters: NotRequired[Attributes]

Filters to scope the results based on custom attributes for the instance (for example, {version=v1, az=1a}). Only instances that match all the specified key-value pairs are returned.

service_name instance-attribute

service_name: ServiceName

The name of the service that you specified when you registered the instance.