Skip to content

Commit 4eb96be

Browse files
committed
CCM-13280: Add missing authorization header (#273)
* auth header * remove required for published spec simplicity * authorization variants by apim env * change defaults to prod * use make for spec build * try to increase timeout * revert timeout experiment * change dynamic envs to use apikey header Signed-off-by: Mark Slowey <mark.slowey1@nhs.net>
1 parent 55594dc commit 4eb96be

File tree

9 files changed

+17
-7
lines changed

9 files changed

+17
-7
lines changed

Makefile

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,11 @@ publish-oas:
4545
$(MAKE) copy-examples
4646
npm run publish-oas
4747

48+
set-authorization: guard-APIM_ENV
49+
@ AUTHORIZATION=authorization-$$APIM_ENV.yml \
50+
envsubst '$${AUTHORIZATION}' \
51+
< specification/api/components/parameters/authorization/authorization-template.yml > specification/api/components/parameters/authorization/authorization.yml
52+
4853
set-target: guard-APIM_ENV
4954
@ TARGET=target-$$APIM_ENV.yml \
5055
envsubst '$${TARGET}' \
@@ -64,6 +69,7 @@ set-security: guard-APIM_ENV
6469
< specification/api/components/security-schemes/security-schemes-template.yml > specification/api/components/security-schemes/security-schemes.yml
6570

6671
construct-spec: guard-APIM_ENV
72+
$(MAKE) set-authorization APIM_ENV=$$APIM_ENV
6773
$(MAKE) set-target APIM_ENV=$$APIM_ENV
6874
$(MAKE) set-access APIM_ENV=$$APIM_ENV
6975
$(MAKE) set-security APIM_ENV=$$APIM_ENV

VERSION

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
1.0.0-${yyyy}${mm}${dd}.${HH}${MM}${SS}+${hash}
1+
1.0.1-${yyyy}${mm}${dd}.${HH}${MM}${SS}+${hash}

sdk/Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ VERSION ?= ""
33
SHELL = /bin/bash
44

55
build: version # Build the project artefact @Pipeline
6-
VER=$$(cat .version) && cd .. && npm run build --buildver=$$VER && cd sdk
6+
VER=$$(cat .version) && cd .. && make build-yml-oas-spec APIM_ENV=prod && npm run generate --buildver=$$VER && cd sdk
77
./swagger-static.sh
88

99
clean: # Clean-up project resources (main) @Operations

sdk/_config.version.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
version: 0.2.0-20251120.121539+0c18993
1+
version: 1.0.1-20251125.131623+3d60875
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
$ref: security-schemes-internal-dev-pr.yml
1+
$ref: security-schemes-prod.yml
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
$ref: security-internal-dev-pr.yml
1+
$ref: security-prod.yml
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
$ref: access-internal-dev-pr.yml
1+
$ref: access-prod.yml
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
$ref: target-internal-dev-pr.yml
1+
$ref: target-prod.yml

specification/api/notify-supplier-phase1.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@ security:
99
paths:
1010
/letters:
1111
parameters:
12+
- $ref: 'components/parameters/authorization/authorization.yml'
1213
- $ref: 'components/parameters/requestId.yml'
1314
- $ref: 'components/parameters/correlationId.yml'
1415
post:
@@ -17,6 +18,7 @@ paths:
1718
$ref: 'components/endpoints/listLetters.yml'
1819
'/letters/{id}':
1920
parameters:
21+
- $ref: 'components/parameters/authorization/authorization.yml'
2022
- $ref: 'components/parameters/requestId.yml'
2123
- $ref: 'components/parameters/correlationId.yml'
2224
- $ref: 'components/parameters/resourceId.yml'
@@ -26,6 +28,7 @@ paths:
2628
$ref: 'components/endpoints/patchLetter.yml'
2729
'/letters/{id}/data':
2830
parameters:
31+
- $ref: 'components/parameters/authorization/authorization.yml'
2932
- $ref: 'components/parameters/resourceId.yml'
3033
- $ref: 'components/parameters/requestId.yml'
3134
- $ref: 'components/parameters/correlationId.yml'
@@ -35,6 +38,7 @@ paths:
3538
# $ref: 'components/endpoints/headDataId.yml'
3639
/mi:
3740
parameters:
41+
- $ref: 'components/parameters/authorization/authorization.yml'
3842
- $ref: 'components/parameters/requestId.yml'
3943
- $ref: 'components/parameters/correlationId.yml'
4044
post:

0 commit comments

Comments
 (0)