File tree Expand file tree Collapse file tree 1 file changed +16
-9
lines changed
src/pages/gen1/[platform]/build-a-backend/troubleshooting/apikey-not-found Expand file tree Collapse file tree 1 file changed +16
-9
lines changed Original file line number Diff line number Diff line change @@ -29,11 +29,14 @@ export function getStaticProps(context) {
29
29
If you're encountering an "API Key Not Found" issue in your Amplify project, follow the steps below to troubleshoot and resolve the problem:
30
30
31
31
## Step 1: Modify ` parameters.json ` to Remove API Key
32
+
32
33
1 . Navigate to the ` amplify/backend/api/<apiName>/parameters.json ` file in your project.
33
34
2 . Add the following line to the file:
34
35
35
36
``` tsx title="parameters.json"
37
+ {
36
38
" CreateAPIKey" : 0
39
+ }
37
40
```
38
41
Ensure that a comma is placed after the previous line if this is added at the end of the JSON object.
39
42
@@ -45,20 +48,24 @@ If you're encountering an "API Key Not Found" issue in your Amplify project, fol
45
48
* Change this:
46
49
47
50
``` tsx title="backend-config.json"
48
- " attributes" : [
49
- " GraphQLAPIIdOutput" ,
50
- " GraphQLAPIEndpointOutput" ,
51
- " GraphQLAPIKeyOutput"
52
- ]
51
+ {
52
+ " attributes" : [
53
+ " GraphQLAPIIdOutput" ,
54
+ " GraphQLAPIEndpointOutput" ,
55
+ " GraphQLAPIKeyOutput"
56
+ ]
57
+ }
53
58
```
54
59
55
60
* To this:
56
61
57
62
``` tsx title="backend-config.json"
58
- " attributes" : [
59
- " GraphQLAPIIdOutput" ,
60
- " GraphQLAPIEndpointOutput"
61
- ]
63
+ {
64
+ " attributes" : [
65
+ " GraphQLAPIIdOutput" ,
66
+ " GraphQLAPIEndpointOutput"
67
+ ]
68
+ }
62
69
```
63
70
Perform this change for each Lambda function that utilizes the API.
64
71
You can’t perform that action at this time.
0 commit comments