Creates and manages a Hook Key. This resource allows you to create and configure an Okta Hook Key.
Use Key Management to create and manage JSON Web Keys (JWKS) that support OAuth 2.0 client authentication. The key is composed of a public and private key pair. The private key signs the JSON Web Token (JWT) and the public key validates it on the client side.
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as okta from "@pulumi/okta";
const example = new okta.HookKey("example", {name: "My Hook Key"});
import pulumi
import pulumi_okta as okta
example = okta.HookKey("example", name="My Hook Key")
package main
import (
"github.com/pulumi/pulumi-okta/sdk/v6/go/okta"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := okta.NewHookKey(ctx, "example", &okta.HookKeyArgs{
Name: pulumi.String("My Hook Key"),
})
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Okta = Pulumi.Okta;
return await Deployment.RunAsync(() =>
{
var example = new Okta.HookKey("example", new()
{
Name = "My Hook Key",
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.okta.HookKey;
import com.pulumi.okta.HookKeyArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;
public class App {
public static void main(String[] args) {
Pulumi.run(App::stack);
}
public static void stack(Context ctx) {
var example = new HookKey("example", HookKeyArgs.builder()
.name("My Hook Key")
.build());
}
}
resources:
example:
type: okta:HookKey
properties:
name: My Hook Key
Create HookKey Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new HookKey(name: string, args?: HookKeyArgs, opts?: CustomResourceOptions);@overload
def HookKey(resource_name: str,
args: Optional[HookKeyArgs] = None,
opts: Optional[ResourceOptions] = None)
@overload
def HookKey(resource_name: str,
opts: Optional[ResourceOptions] = None,
name: Optional[str] = None)func NewHookKey(ctx *Context, name string, args *HookKeyArgs, opts ...ResourceOption) (*HookKey, error)public HookKey(string name, HookKeyArgs? args = null, CustomResourceOptions? opts = null)
public HookKey(String name, HookKeyArgs args)
public HookKey(String name, HookKeyArgs args, CustomResourceOptions options)
type: okta:HookKey
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.
Parameters
- name string
- The unique name of the resource.
- args HookKeyArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- resource_name str
- The unique name of the resource.
- args HookKeyArgs
- The arguments to resource properties.
- opts ResourceOptions
- Bag of options to control resource's behavior.
- ctx Context
- Context object for the current deployment.
- name string
- The unique name of the resource.
- args HookKeyArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args HookKeyArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args HookKeyArgs
- The arguments to resource properties.
- options CustomResourceOptions
- Bag of options to control resource's behavior.
Constructor example
The following reference example uses placeholder values for all input properties.
var hookKeyResource = new Okta.HookKey("hookKeyResource", new()
{
Name = "string",
});
example, err := okta.NewHookKey(ctx, "hookKeyResource", &okta.HookKeyArgs{
Name: pulumi.String("string"),
})
var hookKeyResource = new HookKey("hookKeyResource", HookKeyArgs.builder()
.name("string")
.build());
hook_key_resource = okta.HookKey("hookKeyResource", name="string")
const hookKeyResource = new okta.HookKey("hookKeyResource", {name: "string"});
type: okta:HookKey
properties:
name: string
HookKey Resource Properties
To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.
Inputs
In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.
The HookKey resource accepts the following input properties:
- Name string
- Display name for the key. Must be between 1 and 255 characters.
- Name string
- Display name for the key. Must be between 1 and 255 characters.
- name String
- Display name for the key. Must be between 1 and 255 characters.
- name string
- Display name for the key. Must be between 1 and 255 characters.
- name str
- Display name for the key. Must be between 1 and 255 characters.
- name String
- Display name for the key. Must be between 1 and 255 characters.
Outputs
All input properties are implicitly available as output properties. Additionally, the HookKey resource produces the following output properties:
- Created string
- Timestamp when the key was created.
- Id string
- The provider-assigned unique ID for this managed resource.
- Is
Used bool - Whether this key is currently in use by other applications.
- Key
Id string - The alias of the public key.
- Last
Updated string - Timestamp when the key was updated.
- Created string
- Timestamp when the key was created.
- Id string
- The provider-assigned unique ID for this managed resource.
- Is
Used bool - Whether this key is currently in use by other applications.
- Key
Id string - The alias of the public key.
- Last
Updated string - Timestamp when the key was updated.
- created String
- Timestamp when the key was created.
- id String
- The provider-assigned unique ID for this managed resource.
- is
Used Boolean - Whether this key is currently in use by other applications.
- key
Id String - The alias of the public key.
- last
Updated String - Timestamp when the key was updated.
- created string
- Timestamp when the key was created.
- id string
- The provider-assigned unique ID for this managed resource.
- is
Used boolean - Whether this key is currently in use by other applications.
- key
Id string - The alias of the public key.
- last
Updated string - Timestamp when the key was updated.
- created str
- Timestamp when the key was created.
- id str
- The provider-assigned unique ID for this managed resource.
- is_
used bool - Whether this key is currently in use by other applications.
- key_
id str - The alias of the public key.
- last_
updated str - Timestamp when the key was updated.
- created String
- Timestamp when the key was created.
- id String
- The provider-assigned unique ID for this managed resource.
- is
Used Boolean - Whether this key is currently in use by other applications.
- key
Id String - The alias of the public key.
- last
Updated String - Timestamp when the key was updated.
Look up Existing HookKey Resource
Get an existing HookKey resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.
public static get(name: string, id: Input<ID>, state?: HookKeyState, opts?: CustomResourceOptions): HookKey@staticmethod
def get(resource_name: str,
id: str,
opts: Optional[ResourceOptions] = None,
created: Optional[str] = None,
is_used: Optional[bool] = None,
key_id: Optional[str] = None,
last_updated: Optional[str] = None,
name: Optional[str] = None) -> HookKeyfunc GetHookKey(ctx *Context, name string, id IDInput, state *HookKeyState, opts ...ResourceOption) (*HookKey, error)public static HookKey Get(string name, Input<string> id, HookKeyState? state, CustomResourceOptions? opts = null)public static HookKey get(String name, Output<String> id, HookKeyState state, CustomResourceOptions options)resources: _: type: okta:HookKey get: id: ${id}- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- resource_name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- Created string
- Timestamp when the key was created.
- Is
Used bool - Whether this key is currently in use by other applications.
- Key
Id string - The alias of the public key.
- Last
Updated string - Timestamp when the key was updated.
- Name string
- Display name for the key. Must be between 1 and 255 characters.
- Created string
- Timestamp when the key was created.
- Is
Used bool - Whether this key is currently in use by other applications.
- Key
Id string - The alias of the public key.
- Last
Updated string - Timestamp when the key was updated.
- Name string
- Display name for the key. Must be between 1 and 255 characters.
- created String
- Timestamp when the key was created.
- is
Used Boolean - Whether this key is currently in use by other applications.
- key
Id String - The alias of the public key.
- last
Updated String - Timestamp when the key was updated.
- name String
- Display name for the key. Must be between 1 and 255 characters.
- created string
- Timestamp when the key was created.
- is
Used boolean - Whether this key is currently in use by other applications.
- key
Id string - The alias of the public key.
- last
Updated string - Timestamp when the key was updated.
- name string
- Display name for the key. Must be between 1 and 255 characters.
- created str
- Timestamp when the key was created.
- is_
used bool - Whether this key is currently in use by other applications.
- key_
id str - The alias of the public key.
- last_
updated str - Timestamp when the key was updated.
- name str
- Display name for the key. Must be between 1 and 255 characters.
- created String
- Timestamp when the key was created.
- is
Used Boolean - Whether this key is currently in use by other applications.
- key
Id String - The alias of the public key.
- last
Updated String - Timestamp when the key was updated.
- name String
- Display name for the key. Must be between 1 and 255 characters.
Import
Hook Keys can be imported using the id.
$ pulumi import okta:index/hookKey:HookKey example <hook_key_id>
To learn more about importing existing cloud resources, see Importing resources.
Package Details
- Repository
- Okta pulumi/pulumi-okta
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
oktaTerraform Provider.
