UNPKG

@pulumi/kong

Version:

A Pulumi package for creating and managing Kong resources.

99 lines (98 loc) 3.6 kB
import * as pulumi from "@pulumi/pulumi"; /** * ## # kong.ConsumerKeyAuth * * Resource that allows you to configure the [Key Authentication](https://docs.konghq.com/hub/kong-inc/key-auth/) plugin for a consumer. * * ## Example Usage * * ```typescript * import * as pulumi from "@pulumi/pulumi"; * import * as kong from "@pulumi/kong"; * * const myConsumer = new kong.Consumer("my_consumer", { * username: "User1", * customId: "123", * }); * const keyAuthPlugin = new kong.Plugin("key_auth_plugin", {name: "key-auth"}); * const consumerKeyAuth = new kong.ConsumerKeyAuth("consumer_key_auth", { * consumerId: myConsumer.id, * key: "secret", * tags: [ * "myTag", * "anotherTag", * ], * }); * ``` */ export declare class ConsumerKeyAuth extends pulumi.CustomResource { /** * Get an existing ConsumerKeyAuth resource's state with the given name, ID, and optional extra * properties used to qualify the lookup. * * @param name The _unique_ name of the resulting resource. * @param id The _unique_ provider ID of the resource to lookup. * @param state Any extra arguments used during the lookup. * @param opts Optional settings to control the behavior of the CustomResource. */ static get(name: string, id: pulumi.Input<pulumi.ID>, state?: ConsumerKeyAuthState, opts?: pulumi.CustomResourceOptions): ConsumerKeyAuth; /** * Returns true if the given object is an instance of ConsumerKeyAuth. This is designed to work even * when multiple copies of the Pulumi SDK have been loaded into the same process. */ static isInstance(obj: any): obj is ConsumerKeyAuth; /** * the id of the consumer to associate the credentials to */ readonly consumerId: pulumi.Output<string>; /** * Unique key to authenticate the client; if omitted the plugin will generate one */ readonly key: pulumi.Output<string>; /** * A list of strings associated with the consumer key auth for grouping and filtering */ readonly tags: pulumi.Output<string[] | undefined>; /** * Create a ConsumerKeyAuth resource with the given unique name, arguments, and options. * * @param name The _unique_ name of the resource. * @param args The arguments to use to populate this resource's properties. * @param opts A bag of options that control this resource's behavior. */ constructor(name: string, args: ConsumerKeyAuthArgs, opts?: pulumi.CustomResourceOptions); } /** * Input properties used for looking up and filtering ConsumerKeyAuth resources. */ export interface ConsumerKeyAuthState { /** * the id of the consumer to associate the credentials to */ consumerId?: pulumi.Input<string>; /** * Unique key to authenticate the client; if omitted the plugin will generate one */ key?: pulumi.Input<string>; /** * A list of strings associated with the consumer key auth for grouping and filtering */ tags?: pulumi.Input<pulumi.Input<string>[]>; } /** * The set of arguments for constructing a ConsumerKeyAuth resource. */ export interface ConsumerKeyAuthArgs { /** * the id of the consumer to associate the credentials to */ consumerId: pulumi.Input<string>; /** * Unique key to authenticate the client; if omitted the plugin will generate one */ key?: pulumi.Input<string>; /** * A list of strings associated with the consumer key auth for grouping and filtering */ tags?: pulumi.Input<pulumi.Input<string>[]>; }