Skip to content

Commit 14663be

Browse files
Swagger report - merchant
1 parent 70e2f36 commit 14663be

File tree

5 files changed

+108
-13
lines changed

5 files changed

+108
-13
lines changed

src/idpay/21_apim_api_portal_merchants.tf

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -178,6 +178,27 @@ module "idpay_itn_merchants_portal" {
178178
ingress_load_balancer_hostname = local.domain_aks_ingress_hostname
179179
})
180180
},
181+
{
182+
operation_id = "generateReport"
183+
184+
xml_content = templatefile("./apim/api/idpay_merchants_portal/post-generate-report-policy.xml.tpl", {
185+
ingress_load_balancer_hostname = local.domain_aks_ingress_hostname
186+
})
187+
},
188+
{
189+
operation_id = "getMerchantTransactionsReports"
190+
191+
xml_content = templatefile("./apim/api/idpay_merchants_portal/get-report-list-policy.xml.tpl", {
192+
ingress_load_balancer_hostname = local.domain_aks_ingress_hostname
193+
})
194+
},
195+
{
196+
operation_id = "downloadTransactionsReport"
197+
198+
xml_content = templatefile("./apim/api/idpay_merchants_portal/get-report-download-policy.xml.tpl", {
199+
ingress_load_balancer_hostname = local.domain_aks_ingress_hostname
200+
})
201+
},
181202
{
182203
operation_id = "getProcessedTransactionStatuses"
183204
xml_content = templatefile("./apim/api/idpay_merchants_portal/get-merchant-transactions-processed-statuses-policy.xml.tpl", {
Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
<!--
2+
IMPORTANT:
3+
- Policy elements can appear only within the <inbound>, <outbound>, <backend> section elements.
4+
- To apply a policy to the incoming request (before it is forwarded to the backend service), place a corresponding policy element within the <inbound> section element.
5+
- To apply a policy to the outgoing response (before it is sent back to the caller), place a corresponding policy element within the <outbound> section element.
6+
- To add a policy, place the cursor at the desired insertion point and select a policy from the sidebar.
7+
- To remove a policy, delete the corresponding policy statement from the policy document.
8+
- Position the <base> element within a section element to inherit all policies from the corresponding section element in the enclosing scope.
9+
- Remove the <base> element to prevent inheriting policies from the corresponding section element in the enclosing scope.
10+
- Policies are applied in the order of their appearance, from the top down.
11+
- Comments within policy elements are not supported and may disappear. Place your comments between policy elements or at a higher level scope.
12+
-->
13+
<policies>
14+
<inbound>
15+
<base />
16+
17+
<set-backend-service base-url="https://${ingress_load_balancer_hostname}/idpaytransactions" />
18+
<rewrite-uri template="@("/idpay/merchant/portal/initiatives/{initiativeId}/reports/{reportId}/download")" />
19+
</inbound>
20+
<backend>
21+
<base />
22+
</backend>
23+
<outbound>
24+
<base />
25+
</outbound>
26+
<on-error>
27+
<base />
28+
</on-error>
29+
</policies>
Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
<!--
2+
IMPORTANT:
3+
- Policy elements can appear only within the <inbound>, <outbound>, <backend> section elements.
4+
- To apply a policy to the incoming request (before it is forwarded to the backend service), place a corresponding policy element within the <inbound> section element.
5+
- To apply a policy to the outgoing response (before it is sent back to the caller), place a corresponding policy element within the <outbound> section element.
6+
- To add a policy, place the cursor at the desired insertion point and select a policy from the sidebar.
7+
- To remove a policy, delete the corresponding policy statement from the policy document.
8+
- Position the <base> element within a section element to inherit all policies from the corresponding section element in the enclosing scope.
9+
- Remove the <base> element to prevent inheriting policies from the corresponding section element in the enclosing scope.
10+
- Policies are applied in the order of their appearance, from the top down.
11+
- Comments within policy elements are not supported and may disappear. Place your comments between policy elements or at a higher level scope.
12+
-->
13+
<policies>
14+
<inbound>
15+
<base />
16+
17+
<set-backend-service base-url="https://${ingress_load_balancer_hostname}/idpaytransactions" />
18+
<rewrite-uri template="@("/idpay/merchant/portal/initiatives/{initiativeId}/reports")" />
19+
</inbound>
20+
<backend>
21+
<base />
22+
</backend>
23+
<outbound>
24+
<base />
25+
</outbound>
26+
<on-error>
27+
<base />
28+
</on-error>
29+
</policies>

src/idpay/apim/api/idpay_merchants_portal/openapi.merchants.portal.yml

Lines changed: 1 addition & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -554,12 +554,6 @@ paths:
554554
required: true
555555
schema:
556556
type: string
557-
- name: merchantId
558-
in: query
559-
description: The merchant ID
560-
required: false
561-
schema:
562-
type: string
563557
requestBody:
564558
required: true
565559
content:
@@ -592,12 +586,6 @@ paths:
592586
required: true
593587
schema:
594588
type: string
595-
- name: merchantId
596-
in: query
597-
description: The merchant ID
598-
required: false
599-
schema:
600-
type: string
601589
- name: page
602590
in: query
603591
required: false
@@ -3643,7 +3631,7 @@ components:
36433631
required:
36443632
- startPeriod
36453633
- endPeriod
3646-
- required
3634+
- reportType
36473635
securitySchemes:
36483636
Bearer:
36493637
type: apiKey
Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
<!--
2+
IMPORTANT:
3+
- Policy elements can appear only within the <inbound>, <outbound>, <backend> section elements.
4+
- To apply a policy to the incoming request (before it is forwarded to the backend service), place a corresponding policy element within the <inbound> section element.
5+
- To apply a policy to the outgoing response (before it is sent back to the caller), place a corresponding policy element within the <outbound> section element.
6+
- To add a policy, place the cursor at the desired insertion point and select a policy from the sidebar.
7+
- To remove a policy, delete the corresponding policy statement from the policy document.
8+
- Position the <base> element within a section element to inherit all policies from the corresponding section element in the enclosing scope.
9+
- Remove the <base> element to prevent inheriting policies from the corresponding section element in the enclosing scope.
10+
- Policies are applied in the order of their appearance, from the top down.
11+
- Comments within policy elements are not supported and may disappear. Place your comments between policy elements or at a higher level scope.
12+
-->
13+
<policies>
14+
<inbound>
15+
<base />
16+
<set-backend-service base-url="https://${ingress_load_balancer_hostname}/idpaytransactions" />
17+
<rewrite-uri template="@("/idpay/merchant/portal/initiatives/{initiativeId}/reports")" />
18+
</inbound>
19+
<backend>
20+
<base />
21+
</backend>
22+
<outbound>
23+
<base />
24+
</outbound>
25+
<on-error>
26+
<base />
27+
</on-error>
28+
</policies>

0 commit comments

Comments
 (0)