forked from apigee/openbank
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathconfig.yml.template
226 lines (213 loc) · 12.4 KB
/
config.yml.template
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
resources:
- name: openbank_apis
type: solutions.api
properties:
inputs:
- name: org
prompt: Edge Org name
- name: username
prompt: Username
ifNotPresent: token
- name: password
prompt: Password
hidden: true
ifNotPresent: token
- name: env
prompt: Edge Org Environment
- name: consentSessionKey
prompt: Enter Consent Session Key
- name: jwtSignKey
prompt: Enter Login App Key
configurations:
- env: test
edge_host: https://api.enterprise.apigee.com
sms_endpoint: https://rest.nexmo.com/sms/json
- env : prod
edge_host: https://api.enterprise.apigee.com
sms_endpoint: https://rest.nexmo.com/sms/json
edgeOrg:
script: gulpfile.js
basePath: .
subResources:
- name: cacheResources
type: cache
items:
- name: sms-token-cache
payload: '{ "name": "sms-token-cache"}'
- name: nonce-cache
payload: '{ "name": "nonce-cache"}'
- name: message_kvm
type: kvm
items:
- name: GoogleServiceAccountKVM
payload: '{ "name" : "GoogleServiceAccountKVM", "entry" : [ { "name" : "privateKey", "value" : "{{ serviceaccount_Private_Key }}" } ] , "encrypted": "true"}'
- name: BankKVM
payload: '{ "name" : "BankKVM", "entry" : [ { "name" : "privateKey", "value" : "{{ bankPrivateKeySingleLine }}" } ] , "encrypted": "true"}'
- name: replaceGoogleProject
type: configSubstitutions
items:
- name: datastoreProject
filePaths: ['src/gateway/datastore-connector/target/apiproxy/targets/default.xml','src/gateway/datastore-connector/target/apiproxy/policies/Service-Callout-Get-Entity.xml']
value: '{{ datastoreProject }}'
- name: client_email
filePaths: ['src/gateway/datastore-connector/target/apiproxy/policies/Generate-JWT-Datastore.xml']
value: '{{ client_email }}'
- name: token_uri
filePaths: ['src/gateway/datastore-connector/target/apiproxy/policies/Generate-JWT-Datastore.xml','src/gateway/datastore-connector/target/apiproxy/policies/Service-Callout-Get-Access-Token.xml']
value: '{{ token_uri }}'
- name: datastore-connector api
type: proxy
items:
- name: datastore-connector
apiName: Datastorev1.0.1Connector
- name: developers
type: developer
items:
- payload: '{"email":"[email protected]", "firstName":"OpenBank","lastName":"Developer","userName":"openbank"}'
email: [email protected]
- name: dsApiProducts
type: product
items:
- payload: '{"approvalType":"auto", "attributes":[{"name":"access","value":"private"}], "displayName":"Internal Datastore API","name":"datastore_api","environments":["test","prod"],"scopes":[]}'
name: datastore_api
- name: dsDeveloperApps
type: app
items:
- name: internal_DSappv101
payload: '{"name":"internal_DSappv101","callback":"http://localhost/","email":"[email protected]","apiProducts":"datastore_api"}'
assignResponse:
- from: credentials.0.consumerKey
to: apiKey_DS
- name: replaceorgvalues
type: configSubstitutions
items:
- name: edgeBasePath
filePaths: ['src/gateway/payments-connector/target/apiproxy/resources/node/package.json','src/gateway/consent-management/target/apiproxy/targets/default.xml','src/gateway/user-management/target/apiproxy/targets/default.xml','src/gateway/customer-management/target/apiproxy/targets/default.xml','src/gateway/accounts-connector/target/apiproxy/policies/Assign-Target-URL.xml','src/gateway/locations-connector/target/apiproxy/targets/default.xml','src/gateway/products-connector/target/apiproxy/targets/default.xml']
value: 'https://{{=<% %>=}}{{org}}<%={{ }}=%>-{{=<% %>=}}{{env}}<%={{ }}=%>.apigee.net'
- name: DsApikey
filePaths: ['src/gateway/accounts-connector/target/apiproxy/policies/Assign-Target-URL.xml','src/gateway/user-management/target/apiproxy/policies/Assign-Message.xml','src/gateway/products-connector/target/apiproxy/policies/Assign-Message.xml','src/gateway/locations-connector/target/apiproxy/policies/Assign-Variables.xml','src/gateway/customer-management/target/apiproxy/policies/Assign-Apikey.xml','src/gateway/consent-management/target/apiproxy/policies/Assign-Apikey.xml','src/gateway/payments-connector/target/apiproxy/resources/node/package.json']
value: '{{=<% %>=}}{{apiKey_DS}}<%={{ }}=%>'
- name: sms_endpoint
filePaths: ['src/gateway/sms-token/target/apiproxy/targets/confirmation.xml','src/gateway/sms-token/target/apiproxy/targets/default.xml']
value: '{{=<% %>=}}{{sms_endpoint}}<%={{ }}=%>'
- name: bank_apis
type: proxy
items:
- name: accounts-connector
apiName: AccountsOBv1.0.1Connector
- name: sms-token
apiName: SmsTokenOBv1.0.1
- name: consent-management
apiName: ConsentManagementOBv1.0.1
- name: user-management
apiName: UserManagementOBv1.0.1
- name: customer-management
apiName: CustomerManagementOBv1.0.1
- name: payments-connector
apiName: PaymentsOBv1.0.1Connector
- name: locations-connector
apiName: locations-connector
- name: products-connector
apiName: products-connector
- name: apisbank-connector
apiName: ApisbankOBv1.0.1Connector
- name: apiProducts
type: product
items:
- payload: '{"approvalType":"auto", "attributes":[{"name":"access","value":"private"}], "displayName":"Internal Consent APIs v1.0.1","name":"internal_apisv1.0.1","environments":["test","prod"],"scopes":[]}'
name: internal_apisv1.0.1
- name: developerApps
type: app
items:
- name: internal_appv101
payload: '{"name":"internal_appv101","callback":"http://localhost/","email":"[email protected]","apiProducts":"internal_apisv1.0.1"}'
assignResponse:
- from: credentials.0.consumerKey
to: apiKey_IA
- name: replace_consent_app_key
type: configSubstitutions
items:
- name: internalAppKey
filePaths: ['src/gateway/login-app/target/apiproxy/resources/node/config.json','src/gateway/consent-app/target/apiproxy/resources/node/config.json','src/gateway/accounts/target/apiproxy/policies/Assign-APIKey-Header.xml','src/gateway/accounts/target/apiproxy/policies/Fetch-Account-Consent.xml','src/gateway/accounts/target/apiproxy/policies/Get-Acc-Req-Data.xml','src/gateway/accounts/target/apiproxy/policies/Update-Access-Count.xml','src/gateway/oauth/target/apiproxy/policies/Service-Callout-Update-Account-Request.xml','src/gateway/oauth/target/apiproxy/policies/Service-Callout-Update-Payment-Request.xml','src/gateway/oauth/target/apiproxy/policies/Service-Callout-Validate-Account-Request.xml','src/gateway/oauth/target/apiproxy/policies/Service-Callout-Validate-Payment-Request.xml','src/gateway/payments/target/apiproxy/policies/Assign-APIKey-Header.xml','src/gateway/payments/target/apiproxy/policies/Service-Callout-Validate-Payment-Request-Status.xml','src/gateway/payments/target/apiproxy/policies/Service-Callout-Fetch-and-Validate-Consent.xml']
value: '{{=<% %>=}}{{apiKey_IA}}<%={{ }}=%>'
- name: edgeBasePath
filePaths: ['src/gateway/login-app/target/apiproxy/resources/node/config.json','src/gateway/locations/target/apiproxy/targets/default.xml','src/gateway/products/target/apiproxy/targets/default.xml','src/gateway/oauth/target/apiproxy/policies/Service-Callout-Create-ID-token.xml','src/gateway/consent-app/target/apiproxy/resources/node/config.json','src/gateway/accounts/target/apiproxy/policies/Fetch-Account-Consent.xml','src/gateway/accounts/target/apiproxy/policies/Get-Acc-Req-Data.xml','src/gateway/accounts/target/apiproxy/policies/Update-Access-Count.xml','src/gateway/accounts/target/apiproxy/targets/default.xml','src/gateway/oauth/target/apiproxy/policies/Service-Callout-Update-Account-Request.xml','src/gateway/oauth/target/apiproxy/policies/Service-Callout-Update-Payment-Request.xml','src/gateway/oauth/target/apiproxy/policies/Service-Callout-Validate-Account-Request.xml','src/gateway/oauth/target/apiproxy/policies/Service-Callout-Validate-Payment-Request.xml','src/gateway/oauth/target/apiproxy/targets/default.xml','src/gateway/payments/target/apiproxy/policies/Service-Callout-Validate-Payment-Request-Status.xml','src/gateway/payments/target/apiproxy/policies/Service-Callout-Fetch-and-Validate-Consent.xml','src/gateway/payments/target/apiproxy/targets/default.xml']
value: 'https://{{=<% %>=}}{{ org }}<%={{ }}=%>-{{=<% %>=}}{{ env }}<%={{ }}=%>.apigee.net{{ sbconnector}}'
- name: consentSessionKey
filePaths: ['src/gateway/consent-app/target/apiproxy/resources/node/config.json']
value: '{{=<% %>=}}{{ consentSessionKey }}<%={{ }}=%>'
- name: DsApikey
filePaths: ['src/gateway/oauth/target/apiproxy/policies/Service-Callout-Create-ID-token.xml']
value: '{{=<% %>=}}{{apiKey_DS}}<%={{ }}=%>'
- name: jwtSignKey
filePaths: ['src/gateway/consent-app/target/apiproxy/resources/node/config.json','src/gateway/login-app/target/apiproxy/resources/node/config.json']
value: '{{=<% %>=}}{{ jwtSignKey }}<%={{ }}=%>'
- name: edgeBasePathFixed
filePaths: ['src/gateway/consent-app/target/apiproxy/resources/node/config.json','src/gateway/oauth/target/apiproxy/targets/default.xml']
value: 'https://{{=<% %>=}}{{ org }}<%={{ }}=%>-{{=<% %>=}}{{ env }}<%={{ }}=%>.apigee.net'
- name: deploy_remaining_apis
type: proxy
items:
- name: oauth
apiName: OauthOBv1.0.1
- name: login-app
apiName: LoginAppOBv1.0.1
- name: consent-app
apiName: ConsentAppOBv1.0.1
- name: accounts
apiName: AccountsOBv1.0.1
- name: payments
apiName: PaymentsOBv1.0.1
- name: locations
apiName: locations
- name: products
apiName: products
- name: remainingApiProducts
type: product
items:
- payload: '{"approvalType":"auto", "displayName":"Account APIs v1.0.1","name":"account_apisv1.0.1","environments":["test","prod"],"scopes":["accounts","openid"], "proxies":["oauth", "accounts"]}'
name: account_apis
- payload: '{"approvalType":"auto", "displayName":"Payments APIs v1.0.1","name":"payment_apisv1.0.1","environments":["test","prod"],"scopes":["payments","openid"], "proxies":["oauth", "payments"]}'
name: payment_apis
- name: remainingDeveloperApps
type: app
items:
- name: AISP_Appv101
payload: '{"name":"AISP_Appv101","attributes":[{"name":"tppId","value":"12345"},{"name":"publicKey","value":"{{ tppPublicKeySingleLine }}"}],"callback":"http://localhost/,https://api.enterprise.apigee.com/v1/o/{{=<% %>=}}{{ org }}<%={{ }}=%>/apimodels/accounts-apis-v1-0-1/templateauths/PSUOAuth2Security/callback","email":"[email protected]","apiProducts":"account_apisv1.0.1"}'
assignResponse:
- from: credentials.0.consumerKey
to: apiKey_AISP
- from: credentials.0.consumerSecret
to: apiSecret_AISP
- from: appId
to: appId_AISP
- name: PISP_Appv101
payload: '{"name":"PISP_Appv101","attributes":[{"name":"tppId","value":"12345"},{"name":"publicKey","value":"{{ tppPublicKeySingleLine }}"}],"callback":"http://localhost/,https://api.enterprise.apigee.com/v1/o/{{=<% %>=}}{{ org }}<%={{ }}=%>/apimodels/payments-apis-v1-0-1/templateauths/PSUOAuth2Security/callback","email":"[email protected]","apiProducts":"payment_apisv1.0.1"}'
assignResponse:
- from: credentials.0.consumerKey
to: apiKey_PISP
- from: credentials.0.consumerSecret
to: apiSecret_PISP
- from: appId
to: appId_PISP
- name: copyConfigTemplate
type: util
items:
- action: copy
from: test/config.orig
to: test/config.json
- name: replace_test_keys
type: configSubstitutions
items:
- name: keyAISP
filePaths: ['test/config.json']
value: '{{=<% %>=}}{{ apiKey_AISP }}<%={{ }}=%>'
- name: keyPISP
filePaths: ['test/config.json']
value: '{{=<% %>=}}{{ apiKey_PISP }}<%={{ }}=%>'
- name: edgeBasePath
filePaths: ['test/config.json']
value: '{{=<% %>=}}{{ org }}<%={{ }}=%>-{{=<% %>=}}{{ env }}<%={{ }}=%>.apigee.net'
- name: internalAppKey
filePaths: ['test/config.json']
value: '{{=<% %>=}}{{ apiKey_IA }}<%={{ }}=%>'