import type { MetadataBearer as __MetadataBearer } from "@smithy/types"; import type { UpdateInstanceCustomHealthStatusRequest } from "../models/models_0"; /** * @public */ export type { __MetadataBearer }; /** * @public * * The input for {@link UpdateInstanceCustomHealthStatusCommand}. */ export interface UpdateInstanceCustomHealthStatusCommandInput extends UpdateInstanceCustomHealthStatusRequest { } /** * @public * * The output of {@link UpdateInstanceCustomHealthStatusCommand}. */ export interface UpdateInstanceCustomHealthStatusCommandOutput extends __MetadataBearer { } declare const UpdateInstanceCustomHealthStatusCommand_base: { new (input: UpdateInstanceCustomHealthStatusCommandInput): import("@smithy/core/client").CommandImpl; new (input: UpdateInstanceCustomHealthStatusCommandInput): import("@smithy/core/client").CommandImpl; getEndpointParameterInstructions(): import("@smithy/types").EndpointParameterInstructions; }; /** *

Submits a request to change the health status of a custom health check to healthy or * unhealthy.

*

You can use UpdateInstanceCustomHealthStatus to change the status only for * custom health checks, which you define using HealthCheckCustomConfig when you create * a service. You can't use it to change the status for RouteĀ 53 health checks, which you define using * HealthCheckConfig.

*

For more information, see HealthCheckCustomConfig.

* @example * Use a bare-bones client and the command you need to make an API call. * ```javascript * import { ServiceDiscoveryClient, UpdateInstanceCustomHealthStatusCommand } from "@aws-sdk/client-servicediscovery"; // ES Modules import * // const { ServiceDiscoveryClient, UpdateInstanceCustomHealthStatusCommand } = require("@aws-sdk/client-servicediscovery"); // CommonJS import * // import type { ServiceDiscoveryClientConfig } from "@aws-sdk/client-servicediscovery"; * const config = {}; // type is ServiceDiscoveryClientConfig * const client = new ServiceDiscoveryClient(config); * const input = { // UpdateInstanceCustomHealthStatusRequest * ServiceId: "STRING_VALUE", // required * InstanceId: "STRING_VALUE", // required * Status: "HEALTHY" || "UNHEALTHY", // required * }; * const command = new UpdateInstanceCustomHealthStatusCommand(input); * const response = await client.send(command); * // {}; * * ``` * * @param UpdateInstanceCustomHealthStatusCommandInput - {@link UpdateInstanceCustomHealthStatusCommandInput} * @returns {@link UpdateInstanceCustomHealthStatusCommandOutput} * @see {@link UpdateInstanceCustomHealthStatusCommandInput} for command's `input` shape. * @see {@link UpdateInstanceCustomHealthStatusCommandOutput} for command's `response` shape. * @see {@link ServiceDiscoveryClientResolvedConfig | config} for ServiceDiscoveryClient's `config` shape. * * @throws {@link CustomHealthNotFound} (client fault) *

The health check for the instance that's specified by ServiceId and * InstanceId isn't a custom health check.

* * @throws {@link InstanceNotFound} (client fault) *

No instance exists with the specified ID, or the instance was recently registered, and * information about the instance hasn't propagated yet.

* * @throws {@link InvalidInput} (client fault) *

One or more specified values aren't valid. For example, a required value might be missing, a * numeric value might be outside the allowed range, or a string value might exceed length * constraints.

* * @throws {@link ServiceNotFound} (client fault) *

No service exists with the specified ID.

* * @throws {@link ServiceDiscoveryServiceException} *

Base exception class for all service exceptions from ServiceDiscovery service.

* * * @example Update instance custom health status using service ARN * ```javascript * // Updates instance custom health status using a service ARN instead of service ID, useful when working with shared namespaces. * const input = { * InstanceId: "i-abcd1234xmpl5678", * ServiceId: "arn:aws:servicediscovery:us-west-2:123456789012:service/srv-abcd1234xmpl5678", * Status: "HEALTHY" * }; * const command = new UpdateInstanceCustomHealthStatusCommand(input); * const response = await client.send(command); * /* response is * { /* empty *\/ } * *\/ * ``` * * @example UpdateInstanceCustomHealthStatus Example * ```javascript * // This example submits a request to change the health status of an instance associated with a service with a custom health check to HEALTHY. * const input = { * InstanceId: "i-abcd1234", * ServiceId: "srv-e4anhexample0004", * Status: "HEALTHY" * }; * const command = new UpdateInstanceCustomHealthStatusCommand(input); * const response = await client.send(command); * /* response is * { /* metadata only *\/ } * *\/ * ``` * * @public */ export declare class UpdateInstanceCustomHealthStatusCommand extends UpdateInstanceCustomHealthStatusCommand_base { /** @internal type navigation helper, not in runtime. */ protected static __types: { api: { input: UpdateInstanceCustomHealthStatusRequest; output: {}; }; sdk: { input: UpdateInstanceCustomHealthStatusCommandInput; output: UpdateInstanceCustomHealthStatusCommandOutput; }; }; }