Skip to content

Commit

Permalink
fix: api key nolonger forced to be uuid
Browse files Browse the repository at this point in the history
  • Loading branch information
MCBrandenburg committed Sep 24, 2021
1 parent 1c097ea commit 75d4933
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 7 deletions.
2 changes: 1 addition & 1 deletion docs/resources/api_key.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ resource "fusionauth_api_key" "example" {

* `tenant_id` - (Optional) The unique Id of the Tenant. This value is required if the key is meant to be tenant scoped. Tenant scoped keys can only be used to access users and other tenant scoped objects for the specified tenant. This value is read-only once the key is created.
* `key_id` - (Optional) The Id to use for the new Form. If not specified a secure random UUID will be generated.
* `key` - (Optional) The Id to use for the new Form. If not specified a secure random UUID will be generated.
* `key` - (Optional) API key string. When you create an API key the key is defaulted to a secure random value but the API key is simply a string, so you may call it super-secret-key if you’d like. However a long and random value makes a good API key in that it is unique and difficult to guess.
* `description` - (Optional) Description of the key.
* `permissions_endpoints` - (Required) The unique Id of the private key downloaded from Apple and imported into Key Master that will be used to sign the client secret.
* `lambda_reconcile_id` - (Optional) Endpoint permissions for this key. Each key of the object is an endpoint, with the value being an array of the HTTP methods which can be used against the endpoint. An Empty permissions_endpoints object mean that this is a super key that authorizes this key for all the endpoints.
Expand Down
11 changes: 5 additions & 6 deletions fusionauth/resource_fusionauth_api_key.go
Original file line number Diff line number Diff line change
Expand Up @@ -32,12 +32,11 @@ func resourceAPIKey() *schema.Resource {
ValidateFunc: validation.IsUUID,
},
"key": {
Type: schema.TypeString,
Optional: true,
Computed: true,
Description: "The Id to use for the new Form. If not specified a secure random UUID will be generated.",
ValidateFunc: validation.IsUUID,
Sensitive: true,
Type: schema.TypeString,
Optional: true,
Computed: true,
Description: "API key string. When you create an API key the key is defaulted to a secure random value but the API key is simply a string, so you may call it super-secret-key if you’d like. However a long and random value makes a good API key in that it is unique and difficult to guess.",
Sensitive: true,
},
"description": {
Type: schema.TypeString,
Expand Down

0 comments on commit 75d4933

Please sign in to comment.