Skip to content

Commit 0c68250

Browse files
m-houstonmasl2
andauthored
CCM-11580: Updates for OAS Spec V1 (#139)
* CCM-11580: OAS syntax fixes Remove 'requestedProductionStatus' from letter-related JSON schemas and update examples to singular form CCM-11580: Update serve-oas command CCM-11580: Update serve-oas command CCM-11580: Remove unneeded endpoints and resource types + Move getData endpoint under letter CCM-11580: Remove hello world endpoint CCM-11580: Remove hello world endpoint CCM-11580: Add sandbox handler metadata to endpoints CCM-11580: More fixes to examples syntax CCM-11580: Remove remaining reference to hello-world lambda CCM-11580: Remove remaining reference to hello-world lambda CCM-11580: add limit parameter to list letters endpoint CCM-11580: Update sandbox endpoints to match OAS CCM-11580: Update letter responses in Sandbox to match spec changes CCM-11580: implement get letter status endpoint in sandbox Add groupId to schema and examples * CCM-11580: remove x-eov extension from non sandox spec --------- Co-authored-by: mark.slowey1 <[email protected]>
1 parent 831aaa6 commit 0c68250

File tree

63 files changed

+307
-1070
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

63 files changed

+307
-1070
lines changed

Makefile

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,6 @@ guard-%:
3636
serve:
3737
npm run serve
3838

39-
4039
lint-oas:
4140
npm run lint-oas
4241

@@ -82,7 +81,7 @@ bundle-oas:
8281

8382
generate-sandbox:
8483
$(MAKE) build-json-oas-spec APIM_ENV=sandbox
85-
jq --slurpfile status sandbox/HealthcheckEndpoint.json '.paths += $$status[0]' build/notify-supplier.json > tmp.json && mv tmp.json build/notify-supplier.json
84+
# jq --slurpfile status sandbox/HealthcheckEndpoint.json '.paths += $$status[0]' build/notify-supplier.json > tmp.json && mv tmp.json build/notify-supplier.json
8685
jq '.security = []' build/notify-supplier.json > tmp.json && mv tmp.json build/notify-supplier.json
8786
npm run generate-sandbox
8887

infrastructure/terraform/components/api/README.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,8 +31,9 @@ No requirements.
3131
|------|--------|---------|
3232
| <a name="module_authorizer_lambda"></a> [authorizer\_lambda](#module\_authorizer\_lambda) | https://github.com/NHSDigital/nhs-notify-shared-modules/releases/download/v2.0.20/terraform-lambda.zip | n/a |
3333
| <a name="module_domain_truststore"></a> [domain\_truststore](#module\_domain\_truststore) | git::https://github.com/NHSDigital/nhs-notify-shared-modules.git//infrastructure/modules/s3bucket | v2.0.17 |
34+
| <a name="module_get_letters"></a> [get\_letters](#module\_get\_letters) | git::https://github.com/NHSDigital/nhs-notify-shared-modules.git//infrastructure/modules/lambda | v2.0.10 |
35+
| <a name="module_kms"></a> [kms](#module\_kms) | git::https://github.com/NHSDigital/nhs-notify-shared-modules.git//infrastructure/modules/kms | v2.0.10 |
3436
| <a name="module_get_letters"></a> [get\_letters](#module\_get\_letters) | https://github.com/NHSDigital/nhs-notify-shared-modules/releases/download/v2.0.20/terraform-lambda.zip | n/a |
35-
| <a name="module_hello_world"></a> [hello\_world](#module\_hello\_world) | https://github.com/NHSDigital/nhs-notify-shared-modules/releases/download/v2.0.20/terraform-lambda.zip | n/a |
3637
| <a name="module_kms"></a> [kms](#module\_kms) | https://github.com/NHSDigital/nhs-notify-shared-modules/releases/download/v2.0.20/terraform-kms.zip | n/a |
3738
| <a name="module_logging_bucket"></a> [logging\_bucket](#module\_logging\_bucket) | git::https://github.com/NHSDigital/nhs-notify-shared-modules.git//infrastructure/modules/s3bucket | v2.0.17 |
3839
| <a name="module_patch_letters"></a> [patch\_letters](#module\_patch\_letters) | https://github.com/NHSDigital/nhs-notify-shared-modules/releases/download/v2.0.20/terraform-lambda.zip | n/a |

infrastructure/terraform/components/api/iam_role_api_gateway_execution_role.tf

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,6 @@ data "aws_iam_policy_document" "api_gateway_execution_policy" {
4949

5050
resources = [
5151
module.authorizer_lambda.function_arn,
52-
module.hello_world.function_arn,
5352
module.get_letters.function_arn,
5453
module.patch_letters.function_arn
5554
]

infrastructure/terraform/components/api/locals.tf

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,9 +8,8 @@ locals {
88
APIG_EXECUTION_ROLE_ARN = aws_iam_role.api_gateway_execution_role.arn
99
AWS_REGION = var.region
1010
AUTHORIZER_LAMBDA_ARN = module.authorizer_lambda.function_arn
11-
HELLO_WORLD_LAMBDA_ARN = module.hello_world.function_arn
12-
GET_LETTERS_LAMBDA_ARN = module.get_letters.function_arn
13-
PATCH_LETTERS_LAMBDA_ARN = module.patch_letters.function_arn
11+
GET_LETTERS_LAMBDA_ARN = module.get_letters.function_arn
12+
PATCH_LETTERS_LAMBDA_ARN = module.patch_letters.function_arn
1413
})
1514

1615
destination_arn = "arn:aws:logs:${var.region}:${var.shared_infra_account_id}:destination:nhs-main-obs-firehose-logs"

infrastructure/terraform/components/api/module_lambda_hello_world.tf

Lines changed: 0 additions & 56 deletions
This file was deleted.

lambdas/api-handler/src/handlers/__tests__/hello-world.test.ts

Lines changed: 0 additions & 41 deletions
This file was deleted.

lambdas/api-handler/src/handlers/hello-world.ts

Lines changed: 0 additions & 18 deletions
This file was deleted.

lambdas/api-handler/src/index.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
11
// Export all handlers for ease of access
22
export { getLetters } from './handlers/get-letters';
33
export { patchLetters } from './handlers/patch-letters';
4-
export { helloWorld } from './handlers/hello-world';

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@
6262
"publish-oas": "mkdir -p build && redocly bundle specification/api/notify-supplier-phase1.yml --dereferenced -k --remove-unused-components --ext json > build/notify-supplier.json",
6363
"serve": "npm run serve-html-docs",
6464
"serve-html-docs": "npx serve sdk/html -p 3050",
65-
"serve-oas": "redocly preview-docs -p 5000 build/notify-supplier.json",
65+
"serve-oas": "redocly preview -p 5001 -d specification/api",
6666
"serve-swagger-docs": "npx serve sdk/swagger -p 3051",
6767
"start": "npm run start --workspace frontend",
6868
"test:unit": "npm run test:unit --workspaces",

0 commit comments

Comments
 (0)