Class ApiKey
Provides an AppSync API Key.
Example Usage
using Pulumi;
using Aws = Pulumi.Aws;
class MyStack : Stack
{
public MyStack()
{
var exampleGraphQLApi = new Aws.AppSync.GraphQLApi("exampleGraphQLApi", new Aws.AppSync.GraphQLApiArgs
{
AuthenticationType = "API_KEY",
});
var exampleApiKey = new Aws.AppSync.ApiKey("exampleApiKey", new Aws.AppSync.ApiKeyArgs
{
ApiId = exampleGraphQLApi.Id,
Expires = "2018-05-03T04:00:00Z",
});
}
}
Inherited Members
Namespace: Pulumi.Aws.AppSync
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, 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 SourceApiId
The ID of the associated AppSync API
Declaration
public Output<string> ApiId { 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> |
Expires
RFC3339 string representation of the expiry date. Rounded down to nearest hour. By default, it is 7 days from the date of creation.
Declaration
public Output<string> Expires { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.String> |
Key
The API key
Declaration
public Output<string> Key { 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 |