import { Command as $Command } from "@smithy/core/client"; import type { MetadataBearer as __MetadataBearer } from "@smithy/types"; import type { IoTClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../IoTClient"; import type { TestInvokeAuthorizerRequest, TestInvokeAuthorizerResponse } from "../models/models_2"; /** * @public */ export type { __MetadataBearer }; export { $Command }; /** * @public * * The input for {@link TestInvokeAuthorizerCommand}. */ export interface TestInvokeAuthorizerCommandInput extends TestInvokeAuthorizerRequest { } /** * @public * * The output of {@link TestInvokeAuthorizerCommand}. */ export interface TestInvokeAuthorizerCommandOutput extends TestInvokeAuthorizerResponse, __MetadataBearer { } declare const TestInvokeAuthorizerCommand_base: { new (input: TestInvokeAuthorizerCommandInput): import("@smithy/core/client").CommandImpl; new (input: TestInvokeAuthorizerCommandInput): import("@smithy/core/client").CommandImpl; getEndpointParameterInstructions(): { [x: string]: unknown; }; }; /** *

Tests a custom authorization behavior by invoking a specified custom authorizer. Use * this to test and debug the custom authorization behavior of devices that connect to the IoT * device gateway.

*

Requires permission to access the TestInvokeAuthorizer action.

* @example * Use a bare-bones client and the command you need to make an API call. * ```javascript * import { IoTClient, TestInvokeAuthorizerCommand } from "@aws-sdk/client-iot"; // ES Modules import * // const { IoTClient, TestInvokeAuthorizerCommand } = require("@aws-sdk/client-iot"); // CommonJS import * // import type { IoTClientConfig } from "@aws-sdk/client-iot"; * const config = {}; // type is IoTClientConfig * const client = new IoTClient(config); * const input = { // TestInvokeAuthorizerRequest * authorizerName: "STRING_VALUE", // required * token: "STRING_VALUE", * tokenSignature: "STRING_VALUE", * httpContext: { // HttpContext * headers: { // HttpHeaders * "": "STRING_VALUE", * }, * queryString: "STRING_VALUE", * }, * mqttContext: { // MqttContext * username: "STRING_VALUE", * password: new Uint8Array(), // e.g. Buffer.from("") or new TextEncoder().encode("") * clientId: "STRING_VALUE", * }, * tlsContext: { // TlsContext * serverName: "STRING_VALUE", * }, * }; * const command = new TestInvokeAuthorizerCommand(input); * const response = await client.send(command); * // { // TestInvokeAuthorizerResponse * // isAuthenticated: true || false, * // principalId: "STRING_VALUE", * // policyDocuments: [ // PolicyDocuments * // "STRING_VALUE", * // ], * // refreshAfterInSeconds: Number("int"), * // disconnectAfterInSeconds: Number("int"), * // }; * * ``` * * @param TestInvokeAuthorizerCommandInput - {@link TestInvokeAuthorizerCommandInput} * @returns {@link TestInvokeAuthorizerCommandOutput} * @see {@link TestInvokeAuthorizerCommandInput} for command's `input` shape. * @see {@link TestInvokeAuthorizerCommandOutput} for command's `response` shape. * @see {@link IoTClientResolvedConfig | config} for IoTClient's `config` shape. * * @throws {@link InternalFailureException} (server fault) *

An unexpected error has occurred.

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

The request is not valid.

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

The response is invalid.

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

The specified resource does not exist.

* * @throws {@link ServiceUnavailableException} (server fault) *

The service is temporarily unavailable.

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

The rate exceeds the limit.

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

You are not authorized to perform this operation.

* * @throws {@link IoTServiceException} *

Base exception class for all service exceptions from IoT service.

* * * @public */ export declare class TestInvokeAuthorizerCommand extends TestInvokeAuthorizerCommand_base { /** @internal type navigation helper, not in runtime. */ protected static __types: { api: { input: TestInvokeAuthorizerRequest; output: TestInvokeAuthorizerResponse; }; sdk: { input: TestInvokeAuthorizerCommandInput; output: TestInvokeAuthorizerCommandOutput; }; }; }