Class ApiKey
Provides an API Gateway API Key.
NOTE: Since the API Gateway usage plans feature was launched on August 11, 2016, usage plans are now required to associate an API key with an API stage.
Example Usage
using Pulumi;
using Aws = Pulumi.Aws;
class MyStack : Stack
{
public MyStack()
{
var myDemoApiKey = new Aws.ApiGateway.ApiKey("myDemoApiKey", new Aws.ApiGateway.ApiKeyArgs
{
});
}
}
Inherited Members
Namespace: Pulumi.Aws.ApiGateway
Assembly: Pulumi.Aws.dll
Syntax
public class ApiKey : CustomResource
Constructors
View SourceApiKey(String, ApiKeyArgs, CustomResourceOptions)
Create a ApiKey resource with the given unique name, arguments, and options.
Declaration
public ApiKey(string name, ApiKeyArgs args = null, CustomResourceOptions options = null)
Parameters
| Type | Name | Description |
|---|---|---|
| System.String | name | The unique name of the resource |
| ApiKeyArgs | args | The arguments used to populate this resource's properties |
| CustomResourceOptions | options | A bag of options that control this resource's behavior |
Properties
View SourceArn
Amazon Resource Name (ARN)
Declaration
public Output<string> Arn { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.String> |
CreatedDate
The creation date of the API key
Declaration
public Output<string> CreatedDate { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.String> |
Description
The API key description. Defaults to "Managed by Pulumi".
Declaration
public Output<string> Description { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.String> |
Enabled
Specifies whether the API key can be used by callers. Defaults to true.
Declaration
public Output<bool?> Enabled { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.Nullable<System.Boolean>> |
LastUpdatedDate
The last update date of the API key
Declaration
public Output<string> LastUpdatedDate { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.String> |
Name
The name of the API key
Declaration
public Output<string> Name { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.String> |
Tags
Key-value map of resource tags
Declaration
public Output<ImmutableDictionary<string, object>> Tags { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.Collections.Immutable.ImmutableDictionary<System.String, System.Object>> |
Value
The value of the API key. If not specified, it will be automatically generated by AWS on creation.
Declaration
public Output<string> Value { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.String> |
Methods
View SourceGet(String, Input<String>, ApiKeyState, CustomResourceOptions)
Get an existing ApiKey resource's state with the given name, ID, and optional extra properties used to qualify the lookup.
Declaration
public static ApiKey Get(string name, Input<string> id, ApiKeyState state = null, CustomResourceOptions options = null)
Parameters
| Type | Name | Description |
|---|---|---|
| System.String | name | The unique name of the resulting resource. |
| Input<System.String> | id | The unique provider ID of the resource to lookup. |
| ApiKeyState | state | Any extra arguments used during the lookup. |
| CustomResourceOptions | options | A bag of options that control this resource's behavior |
Returns
| Type | Description |
|---|---|
| ApiKey |