Skip to content

Commit

Permalink
feat(client-wafv2): You can now create encrypted API keys to use in a…
Browse files Browse the repository at this point in the history
… client application integration of the JavaScript CAPTCHA API . You can also retrieve a list of your API keys and the JavaScript application integration URL.
  • Loading branch information
awstools committed Apr 20, 2023
1 parent 3eb10b2 commit 8b07232
Show file tree
Hide file tree
Showing 10 changed files with 1,322 additions and 21 deletions.
24 changes: 24 additions & 0 deletions clients/client-wafv2/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -279,6 +279,14 @@ CheckCapacity

[Command API Reference](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-wafv2/classes/checkcapacitycommand.html) / [Input](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-wafv2/interfaces/checkcapacitycommandinput.html) / [Output](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-wafv2/interfaces/checkcapacitycommandoutput.html)

</details>
<details>
<summary>
CreateAPIKey
</summary>

[Command API Reference](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-wafv2/classes/createapikeycommand.html) / [Input](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-wafv2/interfaces/createapikeycommandinput.html) / [Output](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-wafv2/interfaces/createapikeycommandoutput.html)

</details>
<details>
<summary>
Expand Down Expand Up @@ -391,6 +399,14 @@ GenerateMobileSdkReleaseUrl

[Command API Reference](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-wafv2/classes/generatemobilesdkreleaseurlcommand.html) / [Input](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-wafv2/interfaces/generatemobilesdkreleaseurlcommandinput.html) / [Output](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-wafv2/interfaces/generatemobilesdkreleaseurlcommandoutput.html)

</details>
<details>
<summary>
GetDecryptedAPIKey
</summary>

[Command API Reference](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-wafv2/classes/getdecryptedapikeycommand.html) / [Input](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-wafv2/interfaces/getdecryptedapikeycommandinput.html) / [Output](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-wafv2/interfaces/getdecryptedapikeycommandoutput.html)

</details>
<details>
<summary>
Expand Down Expand Up @@ -479,6 +495,14 @@ GetWebACLForResource

[Command API Reference](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-wafv2/classes/getwebaclforresourcecommand.html) / [Input](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-wafv2/interfaces/getwebaclforresourcecommandinput.html) / [Output](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-wafv2/interfaces/getwebaclforresourcecommandoutput.html)

</details>
<details>
<summary>
ListAPIKeys
</summary>

[Command API Reference](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-wafv2/classes/listapikeyscommand.html) / [Input](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-wafv2/interfaces/listapikeyscommandinput.html) / [Output](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-wafv2/interfaces/listapikeyscommandoutput.html)

</details>
<details>
<summary>
Expand Down
53 changes: 53 additions & 0 deletions clients/client-wafv2/src/WAFV2.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,11 @@ import {
CheckCapacityCommandInput,
CheckCapacityCommandOutput,
} from "./commands/CheckCapacityCommand";
import {
CreateAPIKeyCommand,
CreateAPIKeyCommandInput,
CreateAPIKeyCommandOutput,
} from "./commands/CreateAPIKeyCommand";
import { CreateIPSetCommand, CreateIPSetCommandInput, CreateIPSetCommandOutput } from "./commands/CreateIPSetCommand";
import {
CreateRegexPatternSetCommand,
Expand Down Expand Up @@ -74,6 +79,11 @@ import {
GenerateMobileSdkReleaseUrlCommandInput,
GenerateMobileSdkReleaseUrlCommandOutput,
} from "./commands/GenerateMobileSdkReleaseUrlCommand";
import {
GetDecryptedAPIKeyCommand,
GetDecryptedAPIKeyCommandInput,
GetDecryptedAPIKeyCommandOutput,
} from "./commands/GetDecryptedAPIKeyCommand";
import { GetIPSetCommand, GetIPSetCommandInput, GetIPSetCommandOutput } from "./commands/GetIPSetCommand";
import {
GetLoggingConfigurationCommand,
Expand Down Expand Up @@ -121,6 +131,7 @@ import {
GetWebACLForResourceCommandInput,
GetWebACLForResourceCommandOutput,
} from "./commands/GetWebACLForResourceCommand";
import { ListAPIKeysCommand, ListAPIKeysCommandInput, ListAPIKeysCommandOutput } from "./commands/ListAPIKeysCommand";
import {
ListAvailableManagedRuleGroupsCommand,
ListAvailableManagedRuleGroupsCommandInput,
Expand Down Expand Up @@ -215,6 +226,7 @@ import { WAFV2Client, WAFV2ClientConfig } from "./WAFV2Client";
const commands = {
AssociateWebACLCommand,
CheckCapacityCommand,
CreateAPIKeyCommand,
CreateIPSetCommand,
CreateRegexPatternSetCommand,
CreateRuleGroupCommand,
Expand All @@ -229,6 +241,7 @@ const commands = {
DescribeManagedRuleGroupCommand,
DisassociateWebACLCommand,
GenerateMobileSdkReleaseUrlCommand,
GetDecryptedAPIKeyCommand,
GetIPSetCommand,
GetLoggingConfigurationCommand,
GetManagedRuleSetCommand,
Expand All @@ -240,6 +253,7 @@ const commands = {
GetSampledRequestsCommand,
GetWebACLCommand,
GetWebACLForResourceCommand,
ListAPIKeysCommand,
ListAvailableManagedRuleGroupsCommand,
ListAvailableManagedRuleGroupVersionsCommand,
ListIPSetsCommand,
Expand Down Expand Up @@ -289,6 +303,17 @@ export interface WAFV2 {
cb: (err: any, data?: CheckCapacityCommandOutput) => void
): void;

/**
* @see {@link CreateAPIKeyCommand}
*/
createAPIKey(args: CreateAPIKeyCommandInput, options?: __HttpHandlerOptions): Promise<CreateAPIKeyCommandOutput>;
createAPIKey(args: CreateAPIKeyCommandInput, cb: (err: any, data?: CreateAPIKeyCommandOutput) => void): void;
createAPIKey(
args: CreateAPIKeyCommandInput,
options: __HttpHandlerOptions,
cb: (err: any, data?: CreateAPIKeyCommandOutput) => void
): void;

/**
* @see {@link CreateIPSetCommand}
*/
Expand Down Expand Up @@ -497,6 +522,23 @@ export interface WAFV2 {
cb: (err: any, data?: GenerateMobileSdkReleaseUrlCommandOutput) => void
): void;

/**
* @see {@link GetDecryptedAPIKeyCommand}
*/
getDecryptedAPIKey(
args: GetDecryptedAPIKeyCommandInput,
options?: __HttpHandlerOptions
): Promise<GetDecryptedAPIKeyCommandOutput>;
getDecryptedAPIKey(
args: GetDecryptedAPIKeyCommandInput,
cb: (err: any, data?: GetDecryptedAPIKeyCommandOutput) => void
): void;
getDecryptedAPIKey(
args: GetDecryptedAPIKeyCommandInput,
options: __HttpHandlerOptions,
cb: (err: any, data?: GetDecryptedAPIKeyCommandOutput) => void
): void;

/**
* @see {@link GetIPSetCommand}
*/
Expand Down Expand Up @@ -666,6 +708,17 @@ export interface WAFV2 {
cb: (err: any, data?: GetWebACLForResourceCommandOutput) => void
): void;

/**
* @see {@link ListAPIKeysCommand}
*/
listAPIKeys(args: ListAPIKeysCommandInput, options?: __HttpHandlerOptions): Promise<ListAPIKeysCommandOutput>;
listAPIKeys(args: ListAPIKeysCommandInput, cb: (err: any, data?: ListAPIKeysCommandOutput) => void): void;
listAPIKeys(
args: ListAPIKeysCommandInput,
options: __HttpHandlerOptions,
cb: (err: any, data?: ListAPIKeysCommandOutput) => void
): void;

/**
* @see {@link ListAvailableManagedRuleGroupsCommand}
*/
Expand Down
9 changes: 9 additions & 0 deletions clients/client-wafv2/src/WAFV2Client.ts
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,7 @@ import {

import { AssociateWebACLCommandInput, AssociateWebACLCommandOutput } from "./commands/AssociateWebACLCommand";
import { CheckCapacityCommandInput, CheckCapacityCommandOutput } from "./commands/CheckCapacityCommand";
import { CreateAPIKeyCommandInput, CreateAPIKeyCommandOutput } from "./commands/CreateAPIKeyCommand";
import { CreateIPSetCommandInput, CreateIPSetCommandOutput } from "./commands/CreateIPSetCommand";
import {
CreateRegexPatternSetCommandInput,
Expand Down Expand Up @@ -86,6 +87,7 @@ import {
GenerateMobileSdkReleaseUrlCommandInput,
GenerateMobileSdkReleaseUrlCommandOutput,
} from "./commands/GenerateMobileSdkReleaseUrlCommand";
import { GetDecryptedAPIKeyCommandInput, GetDecryptedAPIKeyCommandOutput } from "./commands/GetDecryptedAPIKeyCommand";
import { GetIPSetCommandInput, GetIPSetCommandOutput } from "./commands/GetIPSetCommand";
import {
GetLoggingConfigurationCommandInput,
Expand All @@ -112,6 +114,7 @@ import {
GetWebACLForResourceCommandInput,
GetWebACLForResourceCommandOutput,
} from "./commands/GetWebACLForResourceCommand";
import { ListAPIKeysCommandInput, ListAPIKeysCommandOutput } from "./commands/ListAPIKeysCommand";
import {
ListAvailableManagedRuleGroupsCommandInput,
ListAvailableManagedRuleGroupsCommandOutput,
Expand Down Expand Up @@ -186,6 +189,7 @@ import { getRuntimeConfig as __getRuntimeConfig } from "./runtimeConfig";
export type ServiceInputTypes =
| AssociateWebACLCommandInput
| CheckCapacityCommandInput
| CreateAPIKeyCommandInput
| CreateIPSetCommandInput
| CreateRegexPatternSetCommandInput
| CreateRuleGroupCommandInput
Expand All @@ -200,6 +204,7 @@ export type ServiceInputTypes =
| DescribeManagedRuleGroupCommandInput
| DisassociateWebACLCommandInput
| GenerateMobileSdkReleaseUrlCommandInput
| GetDecryptedAPIKeyCommandInput
| GetIPSetCommandInput
| GetLoggingConfigurationCommandInput
| GetManagedRuleSetCommandInput
Expand All @@ -211,6 +216,7 @@ export type ServiceInputTypes =
| GetSampledRequestsCommandInput
| GetWebACLCommandInput
| GetWebACLForResourceCommandInput
| ListAPIKeysCommandInput
| ListAvailableManagedRuleGroupVersionsCommandInput
| ListAvailableManagedRuleGroupsCommandInput
| ListIPSetsCommandInput
Expand Down Expand Up @@ -239,6 +245,7 @@ export type ServiceInputTypes =
export type ServiceOutputTypes =
| AssociateWebACLCommandOutput
| CheckCapacityCommandOutput
| CreateAPIKeyCommandOutput
| CreateIPSetCommandOutput
| CreateRegexPatternSetCommandOutput
| CreateRuleGroupCommandOutput
Expand All @@ -253,6 +260,7 @@ export type ServiceOutputTypes =
| DescribeManagedRuleGroupCommandOutput
| DisassociateWebACLCommandOutput
| GenerateMobileSdkReleaseUrlCommandOutput
| GetDecryptedAPIKeyCommandOutput
| GetIPSetCommandOutput
| GetLoggingConfigurationCommandOutput
| GetManagedRuleSetCommandOutput
Expand All @@ -264,6 +272,7 @@ export type ServiceOutputTypes =
| GetSampledRequestsCommandOutput
| GetWebACLCommandOutput
| GetWebACLForResourceCommandOutput
| ListAPIKeysCommandOutput
| ListAvailableManagedRuleGroupVersionsCommandOutput
| ListAvailableManagedRuleGroupsCommandOutput
| ListIPSetsCommandOutput
Expand Down
Loading

0 comments on commit 8b07232

Please sign in to comment.