Skip to content

Commit 2b14ef2

Browse files
Add documentation for kong_consumer_key_auth
1 parent 01bd7c2 commit 2b14ef2

File tree

1 file changed

+28
-0
lines changed

1 file changed

+28
-0
lines changed

docs/resources/consumer_key_auth.md

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
# kong_consumer_key_auth
2+
3+
Resource that allows you to configure the [Key Authentication](https://docs.konghq.com/hub/kong-inc/key-auth/) plugin for a consumer.
4+
5+
## Example Usage
6+
7+
```hcl
8+
resource "kong_consumer" "my_consumer" {
9+
username = "User1"
10+
custom_id = "123"
11+
}
12+
13+
resource "kong_plugin" "key_auth_plugin" {
14+
name = "key-auth"
15+
}
16+
17+
resource "kong_consumer_key_auth" "consumer_key_auth" {
18+
consumer_id = kong_consumer.my_consumer.id
19+
key = "secret"
20+
tags = ["myTag", "anotherTag"]
21+
}
22+
```
23+
24+
## Argument Reference
25+
26+
* `consumer_id` - (Required) the id of the consumer to associate the credentials to
27+
* `key` - (Optional) Unique key to authenticate the client; if omitted the plugin will generate one
28+
* `tags` - (Optional) A list of strings associated with the consumer key auth for grouping and filtering

0 commit comments

Comments
 (0)