@@ -105,6 +105,11 @@ resource "aws_api_gateway_api_key" "confluence-user-key" {
105
105
}
106
106
107
107
108
+ resource "aws_api_gateway_api_key" "fathom-user-key" {
109
+ name = " ${ local . aws_resource_prefix } -api-key-fathom"
110
+ }
111
+
112
+
108
113
# Usage Plans
109
114
resource "aws_api_gateway_usage_plan" "default-user-usage-plan" {
110
115
name = " ${ local . aws_resource_prefix } -usage-plan-default"
@@ -131,8 +136,8 @@ resource "aws_api_gateway_usage_plan_key" "default-user-usage-key" {
131
136
}
132
137
133
138
134
- resource "aws_api_gateway_usage_plan" "trusted -user-usage-plan" {
135
- name = " ${ local . aws_resource_prefix } -usage-plan-trusted "
139
+ resource "aws_api_gateway_usage_plan" "confluence -user-usage-plan" {
140
+ name = " ${ local . aws_resource_prefix } -usage-plan-confluence "
136
141
description = " Hydrocron trusted user usage plan"
137
142
api_stages {
138
143
api_id = aws_api_gateway_rest_api. hydrocron-api-gateway . id
@@ -152,5 +157,30 @@ resource "aws_api_gateway_usage_plan" "trusted-user-usage-plan" {
152
157
resource "aws_api_gateway_usage_plan_key" "confluence-user-usage-key" {
153
158
key_id = aws_api_gateway_api_key. confluence-user-key . id
154
159
key_type = " API_KEY"
155
- usage_plan_id = aws_api_gateway_usage_plan. trusted-user-usage-plan . id
160
+ usage_plan_id = aws_api_gateway_usage_plan. confluence-user-usage-plan . id
161
+ }
162
+
163
+
164
+ resource "aws_api_gateway_usage_plan" "fathom-user-usage-plan" {
165
+ name = " ${ local . aws_resource_prefix } -usage-plan-fathom"
166
+ description = " Hydrocron trusted user usage plan"
167
+ api_stages {
168
+ api_id = aws_api_gateway_rest_api. hydrocron-api-gateway . id
169
+ stage = aws_api_gateway_stage. hydrocron-api-gateway-stage . stage_name
170
+ }
171
+ quota_settings {
172
+ limit = 11200000
173
+ period = " MONTH"
174
+ }
175
+ throttle_settings {
176
+ burst_limit = 200
177
+ rate_limit = 2000
178
+ }
179
+ }
180
+
181
+
182
+ resource "aws_api_gateway_usage_plan_key" "fathom-user-usage-key" {
183
+ key_id = aws_api_gateway_api_key. fathom-user-key . id
184
+ key_type = " API_KEY"
185
+ usage_plan_id = aws_api_gateway_usage_plan. fathom-user-usage-plan . id
156
186
}
0 commit comments