Skip to content

Commit bdd1def

Browse files
committed
fix variable name
1 parent 505b967 commit bdd1def

File tree

3 files changed

+5
-5
lines changed

3 files changed

+5
-5
lines changed

lambda/index.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ import { Payload } from "./types";
44
import { error } from "console";
55

66
const handler: Handler = async (payload: Payload) => {
7-
const apiKey = process.env.API_Key;
7+
const apiKey = process.env.API_KEY;
88
const apiUrl = process.env.API_URL;
99
const { headers, data } = payload;
1010
headers.Authorization = headers.Authorization + apiKey;

terraform/main.tf

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,8 +13,8 @@ resource "aws_lambda_function" "lambda" {
1313

1414
environment {
1515
variables = {
16-
API_ACCESS_TOKEN = var.api_config.access_token
17-
URL = var.api_config.url
16+
API_URL = var.api_config.api_url
17+
API_KEY = var.api_config.api_key
1818
}
1919
}
2020

terraform/variables.tf

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,8 @@ variable "name" {
66
variable "api_config" {
77
description = "api configuration"
88
type = object({
9-
url = string
10-
access_token = string # Access token for the Slack bot
9+
api_url = string
10+
api_key = string
1111
})
1212
}
1313

0 commit comments

Comments
 (0)