From 5cc0947b5689ea91d238060dd26d6d7268981993 Mon Sep 17 00:00:00 2001 From: dkoeni <116151702+dkoeni@users.noreply.github.com> Date: Mon, 28 Oct 2024 16:41:48 +0100 Subject: [PATCH 01/22] added camt.052 endpoint --- accountAPI.yaml | 127 +++++++++++++++++++++++++++++++++++++++++++++++- 1 file changed, 126 insertions(+), 1 deletion(-) diff --git a/accountAPI.yaml b/accountAPI.yaml index 79e3c85..88ac50f 100644 --- a/accountAPI.yaml +++ b/accountAPI.yaml @@ -23,7 +23,7 @@ tags: - name: accounts description: Third party access to bank account service considering account information and transaction data operations (JSON). - name: iso20022 - description: Third party access to bank account service considering camt.053 operations (XML). + description: Third party access to bank account service considering camt operations (XML). security: - OAuth2: @@ -405,6 +405,95 @@ paths: '503': $ref: '#/components/responses/standard503' + /iso20022/{accountId}/reports: + get: + tags: + - iso20022 + summary: Retrieve a list of resource links to account reports (CAMT.052) + description: > + Get the resources links to available account reports (camt.052). + The returned account statements must be conform to the XML schema and + implementation guidelines defined by Swiss Payment Standards. + parameters: + - $ref: '#/components/parameters/authorization_in_header' + - $ref: '#/components/parameters/path_accountId' + - $ref: '#/components/parameters/clientid_in_header' + - $ref: '#/components/parameters/correlation_in_header' + - $ref: '#/components/parameters/agent_in_header' + - $ref: '#/components/parameters/optional_targetid_in_header' + - $ref: '#/components/parameters/optional_psu_ip_in_header' + - $ref: '#/components/parameters/optional_psu_user_agent_in_header' + responses: + '200': + description: Returns a list of resource links to ISO20022 XML camt.052 messages. + headers: + X-Correlation-ID: + $ref: '#/components/headers/X-Correlation-ID' + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/Iso20022ReportReference052' + '400': + $ref: '#/components/responses/standard400' + '401': + $ref: '#/components/responses/standard401' + '403': + $ref: '#/components/responses/standard403' + '404': + $ref: '#/components/responses/standard404' + '405': + $ref: '#/components/responses/standard405' + '500': + $ref: '#/components/responses/standard500' + '501': + $ref: '#/components/responses/standard501' + '503': + $ref: '#/components/responses/standard503' + + /iso20022/{accountId}/reports/{reportId}: + get: + tags: + - iso20022 + summary: Retrieves the designated ISO20022 XML CAMT document. + parameters: + - $ref: '#/components/parameters/path_reportId' + - $ref: '#/components/parameters/authorization_in_header' + - $ref: '#/components/parameters/path_accountId' + - $ref: '#/components/parameters/clientid_in_header' + - $ref: '#/components/parameters/correlation_in_header' + - $ref: '#/components/parameters/agent_in_header' + - $ref: '#/components/parameters/optional_targetid_in_header' + - $ref: '#/components/parameters/optional_psu_ip_in_header' + - $ref: '#/components/parameters/optional_psu_user_agent_in_header' + responses: + '200': + description: Returns the requested ISO20022 XML camt.052 message. + headers: + X-Correlation-ID: + $ref: '#/components/headers/X-Correlation-ID' + content: + application/xml: + schema: + type: string + '400': + $ref: '#/components/responses/standard400' + '401': + $ref: '#/components/responses/standard401' + '403': + $ref: '#/components/responses/standard403' + '404': + $ref: '#/components/responses/standard404' + '405': + $ref: '#/components/responses/standard405' + '500': + $ref: '#/components/responses/standard500' + '501': + $ref: '#/components/responses/standard501' + '503': + $ref: '#/components/responses/standard503' + # ------------------------- # -------- Models --------- # ------------------------- @@ -1065,6 +1154,12 @@ components: description: A date. example: 2018-04-13 + DateTime: + type: string + format: date-time + description: The date and time formatted as YYYY-MM-DDTHH:mm:ssZ. + example: 2018-04-13T11:11:11Z + Designation: type: string maxLength: 140 @@ -1108,6 +1203,36 @@ components: $ref: '#/components/schemas/Date' description: The end date of the transaction query period. + Iso20022ReportReference052: + title: ISO 20022 Report Reference + type: object + description: The referenced ISO20022 report (camt.052). + properties: + id: + type: string + description: The unique identifier of the referenced ISO20022 report. + example: '8265333' + schemaVersion: + type: string + example: camt.052.001.08 + description: The delivered schema version of the referenced ISO20022 report. + pattern: '^camt\.052\.[0-9]{3}\.[0-9]{2}$' + type: + type: string + enum: + - incremental + - full + example: full + description: > + Indicates the type of ISO 20022 report being referenced. + * incremental: Contains only the transactions that occurred since the last intraday statement (camt.052). + * full: Contains all transactions since the last regular account statement (camt.053). + account: + $ref: '#/components/schemas/PaymentIbanAccount' + dateTime: + $ref: '#/components/schemas/DateTime' + description: The end date of the transaction query period. + PaymentCurrencyAmount: title: Payment Currency Amount type: object From 66adc3313bc7bdf6843c74f41ac27787ceecc87d Mon Sep 17 00:00:00 2001 From: simonmeyerm <115779682+simonmeyerm@users.noreply.github.com> Date: Fri, 8 Nov 2024 13:58:10 +0100 Subject: [PATCH 02/22] Update accountAPI.yaml - Endpoint for camt.054 credit/debit notifications added --- accountAPI.yaml | 130 ++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 130 insertions(+) diff --git a/accountAPI.yaml b/accountAPI.yaml index 88ac50f..53339b6 100644 --- a/accountAPI.yaml +++ b/accountAPI.yaml @@ -494,6 +494,94 @@ paths: '503': $ref: '#/components/responses/standard503' + /iso20022/{accountId}/notifications: + get: + tags: + - iso20022 + summary: Retrieve a list of resource links to credit and debit notifications (camt.054) + description: > + Retrieves the resources links to available credit and debit notifications (camt.054), + which conform to Swiss Payment Standards and ISO20022 XML schema guidelines. + parameters: + - $ref: '#/components/parameters/authorization_in_header' + - $ref: '#/components/parameters/path_accountId' + - $ref: '#/components/parameters/clientid_in_header' + - $ref: '#/components/parameters/correlation_in_header' + - $ref: '#/components/parameters/agent_in_header' + - $ref: '#/components/parameters/optional_targetid_in_header' + - $ref: '#/components/parameters/optional_psu_ip_in_header' + - $ref: '#/components/parameters/optional_psu_user_agent_in_header' + responses: + '200': + description: Returns a list of resource links to ISO20022 XML camt.054 messages. + headers: + X-Correlation-ID: + $ref: '#/components/headers/X-Correlation-ID' + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/Iso20022ReportReference054' + '400': + $ref: '#/components/responses/standard400' + '401': + $ref: '#/components/responses/standard401' + '403': + $ref: '#/components/responses/standard403' + '404': + $ref: '#/components/responses/standard404' + '405': + $ref: '#/components/responses/standard405' + '500': + $ref: '#/components/responses/standard500' + '501': + $ref: '#/components/responses/standard501' + '503': + $ref: '#/components/responses/standard503' + + /iso20022/{accountId}/notifications/{reportId}: + get: + tags: + - iso20022 + summary: Retrieves the designated ISO20022 XML CAMT document. + parameters: + - $ref: '#/components/parameters/path_reportId' + - $ref: '#/components/parameters/authorization_in_header' + - $ref: '#/components/parameters/path_accountId' + - $ref: '#/components/parameters/clientid_in_header' + - $ref: '#/components/parameters/correlation_in_header' + - $ref: '#/components/parameters/agent_in_header' + - $ref: '#/components/parameters/optional_targetid_in_header' + - $ref: '#/components/parameters/optional_psu_ip_in_header' + - $ref: '#/components/parameters/optional_psu_user_agent_in_header' + responses: + '200': + description: Returns the requested ISO20022 XML camt.052 message. + headers: + X-Correlation-ID: + $ref: '#/components/headers/X-Correlation-ID' + content: + application/xml: + schema: + type: string + '400': + $ref: '#/components/responses/standard400' + '401': + $ref: '#/components/responses/standard401' + '403': + $ref: '#/components/responses/standard403' + '404': + $ref: '#/components/responses/standard404' + '405': + $ref: '#/components/responses/standard405' + '500': + $ref: '#/components/responses/standard500' + '501': + $ref: '#/components/responses/standard501' + '503': + $ref: '#/components/responses/standard503' + # ------------------------- # -------- Models --------- # ------------------------- @@ -1233,6 +1321,48 @@ components: $ref: '#/components/schemas/DateTime' description: The end date of the transaction query period. + Iso20022ReportReference054: + title: ISO20022 Notification Reference + type: object + description: The referenced ISO20022 report (camt.054) for individual credit/debit notifications. + properties: + id: + type: string + description: Unique identifier for the camt.054 notification entry. + example: '9876543' + transactionId: + type: string + description: Unique transaction identifier for tracking individual credit/debit. + example: 'TX123456789' + endToEndId: + type: string + description: Unique identifier from the payer's payment instruction. + example: 'E2E123456789' + messageIdentification: + type: string + description: Unique identifier for the entire camt.054 message. + example: 'MSG987654321' + accountServicerReference: + type: string + description: Identifier assigned by the account servicer for this transaction. + example: 'ASR987654321' + schemaVersion: + type: string + example: camt.054.001.08 + description: The delivered schema version of the referenced ISO20022 report. + pattern: '^camt\.054\.[0-9]{3}\.[0-9]{2}$' + type: + type: string + description: Type of notification. + enum: + - debit + - credit + account: + $ref: '#/components/schemas/PaymentIbanAccount' + dateTime: + $ref: '#/components/schemas/DateTime' + description: The timestamp of the notification. + PaymentCurrencyAmount: title: Payment Currency Amount type: object From 2e8ece48084d8b7c20570e55bea52ad634829a66 Mon Sep 17 00:00:00 2001 From: simonmeyerm <115779682+simonmeyerm@users.noreply.github.com> Date: Fri, 8 Nov 2024 14:15:48 +0100 Subject: [PATCH 03/22] Update accountAPI.yaml corrections lint findings --- accountAPI.yaml | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/accountAPI.yaml b/accountAPI.yaml index 53339b6..bb85088 100644 --- a/accountAPI.yaml +++ b/accountAPI.yaml @@ -1322,30 +1322,30 @@ components: description: The end date of the transaction query period. Iso20022ReportReference054: - title: ISO20022 Notification Reference - type: object - description: The referenced ISO20022 report (camt.054) for individual credit/debit notifications. - properties: + title: ISO20022 Notification Reference + type: object + description: The referenced ISO20022 report (camt.054) for individual credit/debit notifications. + properties: id: type: string description: Unique identifier for the camt.054 notification entry. - example: '9876543' + example: 9876543 transactionId: type: string description: Unique transaction identifier for tracking individual credit/debit. - example: 'TX123456789' + example: TX123456789 endToEndId: type: string description: Unique identifier from the payer's payment instruction. - example: 'E2E123456789' + example: E2E123456789 messageIdentification: type: string description: Unique identifier for the entire camt.054 message. - example: 'MSG987654321' + example: MSG987654321 accountServicerReference: type: string description: Identifier assigned by the account servicer for this transaction. - example: 'ASR987654321' + example: ASR987654321 schemaVersion: type: string example: camt.054.001.08 From bea0595273cb5b0f0ba647a250e1d280cb0f3451 Mon Sep 17 00:00:00 2001 From: simonmeyerm <115779682+simonmeyerm@users.noreply.github.com> Date: Fri, 8 Nov 2024 16:39:01 +0100 Subject: [PATCH 04/22] Update accountAPI.yaml corrections lint validator --- accountAPI.yaml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/accountAPI.yaml b/accountAPI.yaml index bb85088..addeb3f 100644 --- a/accountAPI.yaml +++ b/accountAPI.yaml @@ -1329,7 +1329,7 @@ components: id: type: string description: Unique identifier for the camt.054 notification entry. - example: 9876543 + example: 9876543ABC transactionId: type: string description: Unique transaction identifier for tracking individual credit/debit. @@ -1354,6 +1354,7 @@ components: type: type: string description: Type of notification. + example: debit enum: - debit - credit From 73a93022e5f509f3e60d1d688beb06b9e8272d5b Mon Sep 17 00:00:00 2001 From: simonmeyerm <115779682+simonmeyerm@users.noreply.github.com> Date: Thu, 28 Nov 2024 11:24:48 +0100 Subject: [PATCH 05/22] Update accountAPI.yaml Update format for reportIds --- accountAPI.yaml | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/accountAPI.yaml b/accountAPI.yaml index addeb3f..db99275 100644 --- a/accountAPI.yaml +++ b/accountAPI.yaml @@ -388,6 +388,7 @@ paths: application/xml; charset=utf-8: schema: type: string + format: binary '400': $ref: '#/components/responses/standard400' '401': @@ -474,9 +475,10 @@ paths: X-Correlation-ID: $ref: '#/components/headers/X-Correlation-ID' content: - application/xml: + application/xml; charset=utf-8: schema: type: string + format: binary '400': $ref: '#/components/responses/standard400' '401': @@ -562,9 +564,10 @@ paths: X-Correlation-ID: $ref: '#/components/headers/X-Correlation-ID' content: - application/xml: + application/xml; charset=utf-8: schema: type: string + format: binary '400': $ref: '#/components/responses/standard400' '401': From a1543c66cded7277c375322815b04b60a4c0fa84 Mon Sep 17 00:00:00 2001 From: simonmeyerm <115779682+simonmeyerm@users.noreply.github.com> Date: Mon, 9 Dec 2024 13:36:46 +0100 Subject: [PATCH 06/22] Update accountAPI.yaml --- accountAPI.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/accountAPI.yaml b/accountAPI.yaml index db99275..2b1a5f8 100644 --- a/accountAPI.yaml +++ b/accountAPI.yaml @@ -559,7 +559,7 @@ paths: - $ref: '#/components/parameters/optional_psu_user_agent_in_header' responses: '200': - description: Returns the requested ISO20022 XML camt.052 message. + description: Returns the requested ISO20022 XML camt.054 message. headers: X-Correlation-ID: $ref: '#/components/headers/X-Correlation-ID' From 15036aa33437767ea5c5fd8f0b7ab4da1b2a2a58 Mon Sep 17 00:00:00 2001 From: simonmeyerm <115779682+simonmeyerm@users.noreply.github.com> Date: Wed, 18 Dec 2024 09:55:27 +0100 Subject: [PATCH 07/22] Update accountAPI.yaml - Rework camt.054 endpoint - Remove accountId as parameter for camt.052 and camt.054 endpoint --- accountAPI.yaml | 52 ++++++++++++++++++++----------------------------- 1 file changed, 21 insertions(+), 31 deletions(-) diff --git a/accountAPI.yaml b/accountAPI.yaml index 2b1a5f8..398948d 100644 --- a/accountAPI.yaml +++ b/accountAPI.yaml @@ -406,7 +406,7 @@ paths: '503': $ref: '#/components/responses/standard503' - /iso20022/{accountId}/reports: + /iso20022/reports: get: tags: - iso20022 @@ -417,7 +417,6 @@ paths: implementation guidelines defined by Swiss Payment Standards. parameters: - $ref: '#/components/parameters/authorization_in_header' - - $ref: '#/components/parameters/path_accountId' - $ref: '#/components/parameters/clientid_in_header' - $ref: '#/components/parameters/correlation_in_header' - $ref: '#/components/parameters/agent_in_header' @@ -453,7 +452,7 @@ paths: '503': $ref: '#/components/responses/standard503' - /iso20022/{accountId}/reports/{reportId}: + /iso20022/reports/{reportId}: get: tags: - iso20022 @@ -461,7 +460,6 @@ paths: parameters: - $ref: '#/components/parameters/path_reportId' - $ref: '#/components/parameters/authorization_in_header' - - $ref: '#/components/parameters/path_accountId' - $ref: '#/components/parameters/clientid_in_header' - $ref: '#/components/parameters/correlation_in_header' - $ref: '#/components/parameters/agent_in_header' @@ -496,17 +494,25 @@ paths: '503': $ref: '#/components/responses/standard503' - /iso20022/{accountId}/notifications: + /iso20022/notifications: get: tags: - iso20022 summary: Retrieve a list of resource links to credit and debit notifications (camt.054) description: > - Retrieves the resources links to available credit and debit notifications (camt.054), - which conform to Swiss Payment Standards and ISO20022 XML schema guidelines. + Retrieves the resources links to available camt.054 notifications for credit and debit transactions, supporting external batch booking breakdowns where transaction details are not included in camt.053 account statements. parameters: + - in: query + name: dateFrom + schema: + $ref: '#/components/schemas/Date' + description: The start date for the query. Must be earlier than or equal to the dateTo parameter. + - in: query + name: dateTo + schema: + $ref: '#/components/schemas/Date' + description: The end date for the query. Must be later than or equal to the dateFrom parameter. - $ref: '#/components/parameters/authorization_in_header' - - $ref: '#/components/parameters/path_accountId' - $ref: '#/components/parameters/clientid_in_header' - $ref: '#/components/parameters/correlation_in_header' - $ref: '#/components/parameters/agent_in_header' @@ -1333,39 +1339,23 @@ components: type: string description: Unique identifier for the camt.054 notification entry. example: 9876543ABC - transactionId: - type: string - description: Unique transaction identifier for tracking individual credit/debit. - example: TX123456789 - endToEndId: - type: string - description: Unique identifier from the payer's payment instruction. - example: E2E123456789 - messageIdentification: - type: string - description: Unique identifier for the entire camt.054 message. - example: MSG987654321 accountServicerReference: type: string - description: Identifier assigned by the account servicer for this transaction. + description: Reference assigned by the account servicer. Corresponds to the attribute _Ntry ⇾ AcctSvcrRef_ in SPS/ISO-20022. example: ASR987654321 schemaVersion: type: string example: camt.054.001.08 description: The delivered schema version of the referenced ISO20022 report. pattern: '^camt\.054\.[0-9]{3}\.[0-9]{2}$' - type: - type: string - description: Type of notification. - example: debit - enum: - - debit - - credit account: $ref: '#/components/schemas/PaymentIbanAccount' - dateTime: - $ref: '#/components/schemas/DateTime' - description: The timestamp of the notification. + dateFrom: + $ref: '#/components/schemas/Date' + description: The start date of the transaction query period. + dateTo: + $ref: '#/components/schemas/Date' + description: The end date of the transaction query period. PaymentCurrencyAmount: title: Payment Currency Amount From b93e1840573e85b50b512930b19115aa274d5a92 Mon Sep 17 00:00:00 2001 From: simonmeyerm <115779682+simonmeyerm@users.noreply.github.com> Date: Wed, 18 Dec 2024 09:57:45 +0100 Subject: [PATCH 08/22] Update accountAPI.yaml lint corrections --- accountAPI.yaml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/accountAPI.yaml b/accountAPI.yaml index 398948d..54102d6 100644 --- a/accountAPI.yaml +++ b/accountAPI.yaml @@ -500,7 +500,8 @@ paths: - iso20022 summary: Retrieve a list of resource links to credit and debit notifications (camt.054) description: > - Retrieves the resources links to available camt.054 notifications for credit and debit transactions, supporting external batch booking breakdowns where transaction details are not included in camt.053 account statements. + Retrieves the resources links to available camt.054 notifications for credit and debit transactions, + supporting external batch booking breakdowns where transaction details are not included in camt.053 account statements. parameters: - in: query name: dateFrom From de3630a90c1b5b19082ba14c680afd9f282d197c Mon Sep 17 00:00:00 2001 From: simonmeyerm <115779682+simonmeyerm@users.noreply.github.com> Date: Wed, 18 Dec 2024 13:23:49 +0100 Subject: [PATCH 09/22] Update accountAPI.yaml - Adjusted structure with pagination to be aligned with statements endpoint --- accountAPI.yaml | 30 ++++++++++++++++++++++++------ 1 file changed, 24 insertions(+), 6 deletions(-) diff --git a/accountAPI.yaml b/accountAPI.yaml index 54102d6..95c624c 100644 --- a/accountAPI.yaml +++ b/accountAPI.yaml @@ -416,6 +416,8 @@ paths: The returned account statements must be conform to the XML schema and implementation guidelines defined by Swiss Payment Standards. parameters: + - $ref: '#/components/parameters/cursor' + - $ref: '#/components/parameters/limit' - $ref: '#/components/parameters/authorization_in_header' - $ref: '#/components/parameters/clientid_in_header' - $ref: '#/components/parameters/correlation_in_header' @@ -429,12 +431,19 @@ paths: headers: X-Correlation-ID: $ref: '#/components/headers/X-Correlation-ID' + X-Next-Cursor: + $ref: '#/components/headers/X-Next-Cursor' content: application/json: schema: - type: array - items: - $ref: '#/components/schemas/Iso20022ReportReference052' + type: object + required: + - reports + properties: + reports: + type: array + items: + $ref: '#/components/schemas/Iso20022ReportReference052' '400': $ref: '#/components/responses/standard400' '401': @@ -513,6 +522,8 @@ paths: schema: $ref: '#/components/schemas/Date' description: The end date for the query. Must be later than or equal to the dateFrom parameter. + - $ref: '#/components/parameters/cursor' + - $ref: '#/components/parameters/limit' - $ref: '#/components/parameters/authorization_in_header' - $ref: '#/components/parameters/clientid_in_header' - $ref: '#/components/parameters/correlation_in_header' @@ -526,12 +537,19 @@ paths: headers: X-Correlation-ID: $ref: '#/components/headers/X-Correlation-ID' + X-Next-Cursor: + $ref: '#/components/headers/X-Next-Cursor' content: application/json: schema: - type: array - items: - $ref: '#/components/schemas/Iso20022ReportReference054' + type: object + required: + - notifications + properties: + notifications: + type: array + items: + $ref: '#/components/schemas/Iso20022ReportReference054' '400': $ref: '#/components/responses/standard400' '401': From 6e357f12ff2e9d723382bbb7c83ce41a7e6d4ff1 Mon Sep 17 00:00:00 2001 From: simonmeyerm <115779682+simonmeyerm@users.noreply.github.com> Date: Wed, 18 Dec 2024 13:49:15 +0100 Subject: [PATCH 10/22] Update accountAPI.yaml added required fields --- accountAPI.yaml | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/accountAPI.yaml b/accountAPI.yaml index 95c624c..dff9ece 100644 --- a/accountAPI.yaml +++ b/accountAPI.yaml @@ -1299,6 +1299,7 @@ components: - account - dateFrom - dateTo + - id - schemaVersion properties: schemaVersion: @@ -1323,6 +1324,12 @@ components: title: ISO 20022 Report Reference type: object description: The referenced ISO20022 report (camt.052). + required: + - account + - dateTime + - id + - schemaVersion + - type properties: id: type: string @@ -1353,6 +1360,12 @@ components: title: ISO20022 Notification Reference type: object description: The referenced ISO20022 report (camt.054) for individual credit/debit notifications. + required: + - account + - dateFrom + - dateTo + - id + - schemaVersion properties: id: type: string From 324ee3388038c44bc2ca3344b4ffd51870c6911e Mon Sep 17 00:00:00 2001 From: simonmeyerm <115779682+simonmeyerm@users.noreply.github.com> Date: Thu, 19 Dec 2024 10:11:09 +0100 Subject: [PATCH 11/22] Update accountAPI.yaml removed acctsvcrref --- accountAPI.yaml | 4 ---- 1 file changed, 4 deletions(-) diff --git a/accountAPI.yaml b/accountAPI.yaml index dff9ece..75e493a 100644 --- a/accountAPI.yaml +++ b/accountAPI.yaml @@ -1371,10 +1371,6 @@ components: type: string description: Unique identifier for the camt.054 notification entry. example: 9876543ABC - accountServicerReference: - type: string - description: Reference assigned by the account servicer. Corresponds to the attribute _Ntry ⇾ AcctSvcrRef_ in SPS/ISO-20022. - example: ASR987654321 schemaVersion: type: string example: camt.054.001.08 From 4c0d235bafc69bc3a4e6ce28abb86ca1f44d8a94 Mon Sep 17 00:00:00 2001 From: simonmeyerm <115779682+simonmeyerm@users.noreply.github.com> Date: Fri, 20 Dec 2024 08:56:29 +0100 Subject: [PATCH 12/22] Update accountAPI.yaml --- accountAPI.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/accountAPI.yaml b/accountAPI.yaml index 75e493a..998eaae 100644 --- a/accountAPI.yaml +++ b/accountAPI.yaml @@ -567,7 +567,7 @@ paths: '503': $ref: '#/components/responses/standard503' - /iso20022/{accountId}/notifications/{reportId}: + /iso20022/notifications/{reportId}: get: tags: - iso20022 From 8879ea50a24c6753ebfd751f9ddae43f84311e55 Mon Sep 17 00:00:00 2001 From: simonmeyerm <115779682+simonmeyerm@users.noreply.github.com> Date: Fri, 20 Dec 2024 08:56:54 +0100 Subject: [PATCH 13/22] Update accountAPI.yaml --- accountAPI.yaml | 1 - 1 file changed, 1 deletion(-) diff --git a/accountAPI.yaml b/accountAPI.yaml index 998eaae..6a1e3cd 100644 --- a/accountAPI.yaml +++ b/accountAPI.yaml @@ -575,7 +575,6 @@ paths: parameters: - $ref: '#/components/parameters/path_reportId' - $ref: '#/components/parameters/authorization_in_header' - - $ref: '#/components/parameters/path_accountId' - $ref: '#/components/parameters/clientid_in_header' - $ref: '#/components/parameters/correlation_in_header' - $ref: '#/components/parameters/agent_in_header' From aade2b7e8130067628cecd3d6470b20fdc77dfb7 Mon Sep 17 00:00:00 2001 From: simonmeyerm <115779682+simonmeyerm@users.noreply.github.com> Date: Tue, 21 Jan 2025 09:42:17 +0100 Subject: [PATCH 14/22] Update accountAPI.yaml Removed camt.054 endpoints --- accountAPI.yaml | 135 ------------------------------------------------ 1 file changed, 135 deletions(-) diff --git a/accountAPI.yaml b/accountAPI.yaml index 6a1e3cd..77cff30 100644 --- a/accountAPI.yaml +++ b/accountAPI.yaml @@ -503,112 +503,6 @@ paths: '503': $ref: '#/components/responses/standard503' - /iso20022/notifications: - get: - tags: - - iso20022 - summary: Retrieve a list of resource links to credit and debit notifications (camt.054) - description: > - Retrieves the resources links to available camt.054 notifications for credit and debit transactions, - supporting external batch booking breakdowns where transaction details are not included in camt.053 account statements. - parameters: - - in: query - name: dateFrom - schema: - $ref: '#/components/schemas/Date' - description: The start date for the query. Must be earlier than or equal to the dateTo parameter. - - in: query - name: dateTo - schema: - $ref: '#/components/schemas/Date' - description: The end date for the query. Must be later than or equal to the dateFrom parameter. - - $ref: '#/components/parameters/cursor' - - $ref: '#/components/parameters/limit' - - $ref: '#/components/parameters/authorization_in_header' - - $ref: '#/components/parameters/clientid_in_header' - - $ref: '#/components/parameters/correlation_in_header' - - $ref: '#/components/parameters/agent_in_header' - - $ref: '#/components/parameters/optional_targetid_in_header' - - $ref: '#/components/parameters/optional_psu_ip_in_header' - - $ref: '#/components/parameters/optional_psu_user_agent_in_header' - responses: - '200': - description: Returns a list of resource links to ISO20022 XML camt.054 messages. - headers: - X-Correlation-ID: - $ref: '#/components/headers/X-Correlation-ID' - X-Next-Cursor: - $ref: '#/components/headers/X-Next-Cursor' - content: - application/json: - schema: - type: object - required: - - notifications - properties: - notifications: - type: array - items: - $ref: '#/components/schemas/Iso20022ReportReference054' - '400': - $ref: '#/components/responses/standard400' - '401': - $ref: '#/components/responses/standard401' - '403': - $ref: '#/components/responses/standard403' - '404': - $ref: '#/components/responses/standard404' - '405': - $ref: '#/components/responses/standard405' - '500': - $ref: '#/components/responses/standard500' - '501': - $ref: '#/components/responses/standard501' - '503': - $ref: '#/components/responses/standard503' - - /iso20022/notifications/{reportId}: - get: - tags: - - iso20022 - summary: Retrieves the designated ISO20022 XML CAMT document. - parameters: - - $ref: '#/components/parameters/path_reportId' - - $ref: '#/components/parameters/authorization_in_header' - - $ref: '#/components/parameters/clientid_in_header' - - $ref: '#/components/parameters/correlation_in_header' - - $ref: '#/components/parameters/agent_in_header' - - $ref: '#/components/parameters/optional_targetid_in_header' - - $ref: '#/components/parameters/optional_psu_ip_in_header' - - $ref: '#/components/parameters/optional_psu_user_agent_in_header' - responses: - '200': - description: Returns the requested ISO20022 XML camt.054 message. - headers: - X-Correlation-ID: - $ref: '#/components/headers/X-Correlation-ID' - content: - application/xml; charset=utf-8: - schema: - type: string - format: binary - '400': - $ref: '#/components/responses/standard400' - '401': - $ref: '#/components/responses/standard401' - '403': - $ref: '#/components/responses/standard403' - '404': - $ref: '#/components/responses/standard404' - '405': - $ref: '#/components/responses/standard405' - '500': - $ref: '#/components/responses/standard500' - '501': - $ref: '#/components/responses/standard501' - '503': - $ref: '#/components/responses/standard503' - # ------------------------- # -------- Models --------- # ------------------------- @@ -1355,35 +1249,6 @@ components: $ref: '#/components/schemas/DateTime' description: The end date of the transaction query period. - Iso20022ReportReference054: - title: ISO20022 Notification Reference - type: object - description: The referenced ISO20022 report (camt.054) for individual credit/debit notifications. - required: - - account - - dateFrom - - dateTo - - id - - schemaVersion - properties: - id: - type: string - description: Unique identifier for the camt.054 notification entry. - example: 9876543ABC - schemaVersion: - type: string - example: camt.054.001.08 - description: The delivered schema version of the referenced ISO20022 report. - pattern: '^camt\.054\.[0-9]{3}\.[0-9]{2}$' - account: - $ref: '#/components/schemas/PaymentIbanAccount' - dateFrom: - $ref: '#/components/schemas/Date' - description: The start date of the transaction query period. - dateTo: - $ref: '#/components/schemas/Date' - description: The end date of the transaction query period. - PaymentCurrencyAmount: title: Payment Currency Amount type: object From 8fea9f8867f70e6cc174012e565bb0ff37b8e883 Mon Sep 17 00:00:00 2001 From: simonmeyerm <115779682+simonmeyerm@users.noreply.github.com> Date: Thu, 23 Jan 2025 11:13:31 +0100 Subject: [PATCH 15/22] Update accountAPI.yaml --- accountAPI.yaml | 100 +++++++++++++++++++++++------------------------- 1 file changed, 47 insertions(+), 53 deletions(-) diff --git a/accountAPI.yaml b/accountAPI.yaml index 77cff30..6851ed3 100644 --- a/accountAPI.yaml +++ b/accountAPI.yaml @@ -338,14 +338,9 @@ paths: content: application/json: schema: - type: object - required: - - statements - properties: - statements: - type: array - items: - $ref: '#/components/schemas/Iso20022ReportReference' + type: array + items: + $ref: '#/components/schemas/Iso20022ReportReference053' '400': $ref: '#/components/responses/standard400' '401': @@ -367,8 +362,8 @@ paths: get: tags: - iso20022 - summary: Designated ISO20022 XML camt.053 document - description: Retrieves the designated ISO20022 XML camt.053 document. + summary: Retrieve the designated ISO20022 XML camt.053 document + description: Retrieve the designated ISO20022 XML camt.053 document. parameters: - $ref: '#/components/parameters/path_reportId' - $ref: '#/components/parameters/authorization_in_header' @@ -410,7 +405,7 @@ paths: get: tags: - iso20022 - summary: Retrieve a list of resource links to account reports (CAMT.052) + summary: Retrieve a list of resource links to account reports (camt.052) description: > Get the resources links to available account reports (camt.052). The returned account statements must be conform to the XML schema and @@ -436,14 +431,9 @@ paths: content: application/json: schema: - type: object - required: - - reports - properties: - reports: - type: array - items: - $ref: '#/components/schemas/Iso20022ReportReference052' + type: array + items: + $ref: '#/components/schemas/Iso20022ReportReference052' '400': $ref: '#/components/responses/standard400' '401': @@ -465,7 +455,8 @@ paths: get: tags: - iso20022 - summary: Retrieves the designated ISO20022 XML CAMT document. + summary: Retrieve the designated ISO20022 XML camt.052 document + description: Retrieve the designated ISO20022 XML camt.052 document. parameters: - $ref: '#/components/parameters/path_reportId' - $ref: '#/components/parameters/authorization_in_header' @@ -1187,52 +1178,37 @@ components: Iso20022ReportReference: title: ISO20022 Report Reference type: object - description: The referenced ISO20022 report (camt.053). + description: The referenced ISO20022 report (common fields for camt.052 and camt.053). required: - account - - dateFrom - - dateTo + - creationDateTime - id - schemaVersion properties: - schemaVersion: - type: string - example: camt.053.001.01 - description: The delivered schema version of the referenced ISO20022 report. - pattern: '^camt\.053\.[0-9]{3}\.[0-9]{2}$' id: type: string description: The unique identifier of the referenced ISO20022 report. example: '8265333' + schemaVersion: + type: string + example: camt.053.001.01 + description: The delivered schema version of the referenced ISO20022 report. + pattern: '^camt\.(052|053|054)\.[0-9]{3}\.[0-9]{2}$' account: $ref: '#/components/schemas/PaymentIbanAccount' - dateFrom: - $ref: '#/components/schemas/Date' - description: The start date of the transaction query period. - dateTo: - $ref: '#/components/schemas/Date' - description: The end date of the transaction query period. + creationDateTime: + $ref: '#/components/schemas/DateTime' + description: Date and time when the message was created. Iso20022ReportReference052: - title: ISO 20022 Report Reference + title: ISO20022 Report Reference (camt.052) type: object description: The referenced ISO20022 report (camt.052). + allOf: + - $ref: '#/components/schemas/Iso20022ReportReference' # Reuse the base schema required: - - account - - dateTime - - id - - schemaVersion - type properties: - id: - type: string - description: The unique identifier of the referenced ISO20022 report. - example: '8265333' - schemaVersion: - type: string - example: camt.052.001.08 - description: The delivered schema version of the referenced ISO20022 report. - pattern: '^camt\.052\.[0-9]{3}\.[0-9]{2}$' type: type: string enum: @@ -1243,11 +1219,29 @@ components: Indicates the type of ISO 20022 report being referenced. * incremental: Contains only the transactions that occurred since the last intraday statement (camt.052). * full: Contains all transactions since the last regular account statement (camt.053). - account: - $ref: '#/components/schemas/PaymentIbanAccount' - dateTime: - $ref: '#/components/schemas/DateTime' - description: The end date of the transaction query period. + dateFrom: + $ref: '#/components/schemas/Date' + description: The start date of the transaction query period, optional for camt.052. + dateTo: + $ref: '#/components/schemas/Date' + description: The end date of the transaction query period, optional for camt.052. + + Iso20022ReportReference053: + title: ISO20022 Report Reference (camt.053) + type: object + description: The referenced ISO20022 report (camt.053). + allOf: + - $ref: '#/components/schemas/Iso20022ReportReference' # Reuse the base schema + required: + - dateFrom + - dateTo + properties: + dateFrom: + $ref: '#/components/schemas/Date' + description: The start date of the transaction query period, mandatory for camt.053. + dateTo: + $ref: '#/components/schemas/Date' + description: The end date of the transaction query period, mandatory for camt.053. PaymentCurrencyAmount: title: Payment Currency Amount From b24183302d7f7c25b8eb98cc6fab682216a86028 Mon Sep 17 00:00:00 2001 From: simonmeyerm <115779682+simonmeyerm@users.noreply.github.com> Date: Thu, 23 Jan 2025 11:33:30 +0100 Subject: [PATCH 16/22] Update accountAPI.yaml --- accountAPI.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/accountAPI.yaml b/accountAPI.yaml index 6851ed3..f2671d0 100644 --- a/accountAPI.yaml +++ b/accountAPI.yaml @@ -1198,7 +1198,7 @@ components: $ref: '#/components/schemas/PaymentIbanAccount' creationDateTime: $ref: '#/components/schemas/DateTime' - description: Date and time when the message was created. + description: Date and time when the message was created. Corresponds to the attribute _GrpHdr ⇾ CreDtTm_ in SPS/ISO-20022. Iso20022ReportReference052: title: ISO20022 Report Reference (camt.052) From d72c74093f1de08dd2fc67686691e2afe2b3cfcc Mon Sep 17 00:00:00 2001 From: simonmeyerm <115779682+simonmeyerm@users.noreply.github.com> Date: Fri, 24 Jan 2025 08:12:16 +0100 Subject: [PATCH 17/22] Update accountAPI.yaml --- accountAPI.yaml | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/accountAPI.yaml b/accountAPI.yaml index f2671d0..64f896b 100644 --- a/accountAPI.yaml +++ b/accountAPI.yaml @@ -318,6 +318,18 @@ paths: The returned account statements must be conform to the XML schema and implementation guidelines defined by Swiss Payment Standards. parameters: + - in: query + name: dateFrom + required: true + schema: + $ref: '#/components/schemas/Date' + description: The start date for the query. Must be earlier than or equal to the dateTo parameter. + - in: query + name: dateTo + required: true + schema: + $ref: '#/components/schemas/Date' + description: The end date for the query. Must be later than or equal to the dateFrom parameter. - $ref: '#/components/parameters/cursor' - $ref: '#/components/parameters/limit' - $ref: '#/components/parameters/authorization_in_header' From 077cb889bb91b82606248ae4f34fb563f34fdc42 Mon Sep 17 00:00:00 2001 From: simonmeyerm <115779682+simonmeyerm@users.noreply.github.com> Date: Fri, 24 Jan 2025 08:48:41 +0100 Subject: [PATCH 18/22] Update accountAPI.yaml --- accountAPI.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/accountAPI.yaml b/accountAPI.yaml index 64f896b..c3710c9 100644 --- a/accountAPI.yaml +++ b/accountAPI.yaml @@ -1205,7 +1205,7 @@ components: type: string example: camt.053.001.01 description: The delivered schema version of the referenced ISO20022 report. - pattern: '^camt\.(052|053|054)\.[0-9]{3}\.[0-9]{2}$' + pattern: '^camt\.(052|053)\.[0-9]{3}\.[0-9]{2}$' account: $ref: '#/components/schemas/PaymentIbanAccount' creationDateTime: From 2ff1c601fcae457d716fc668c3ac9a34b7b8bb92 Mon Sep 17 00:00:00 2001 From: Sven Biellmann <121558620+svenbiellmann@users.noreply.github.com> Date: Mon, 17 Feb 2025 17:02:53 +0100 Subject: [PATCH 19/22] Update accountAPI.yaml Several minor changes added to be compliant with the SFTI naming conventions. --- accountAPI.yaml | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/accountAPI.yaml b/accountAPI.yaml index c3710c9..8d256e0 100644 --- a/accountAPI.yaml +++ b/accountAPI.yaml @@ -11,12 +11,12 @@ info: contact: email: info@common-api.ch license: - name: Apache 2.0 + name: Apache-2.0 url: https://www.apache.org/licenses/LICENSE-2.0.html servers: - url: account.common-api.ch/api/v4 externalDocs: - description: Find out more about SFTI API specifications + description: Find out more about SFTI API specifications. url: https://www.common-api.ch tags: @@ -193,17 +193,17 @@ paths: parameters: - $ref: '#/components/parameters/path_accountId' - in: query - name: dateFrom + name: date_from schema: $ref: '#/components/schemas/Date' description: The start date for the query. Must be earlier than or equal to the dateTo parameter. - in: query - name: dateTo + name: date_to schema: $ref: '#/components/schemas/Date' description: The end date for the query. Must be later than or equal to the dateFrom parameter. - in: query - name: entryStatus + name: entry_status required: false schema: type: string @@ -1642,12 +1642,12 @@ components: headers: Content-Language: - description: Response language - always en + description: Response language - always en. schema: type: string X-Correlation-ID: - description: Client defined ID from request to correlates HTTP requests between a client and server + description: Client defined ID from request to correlates HTTP requests between a client and server. schema: type: string example: f058ebd6-02f7-4d3f-942e-904344e8cde5 From 16b6fe777844d465d6a3b19a359d5cbebdd9a634 Mon Sep 17 00:00:00 2001 From: Sven Biellmann <121558620+svenbiellmann@users.noreply.github.com> Date: Mon, 17 Feb 2025 17:06:36 +0100 Subject: [PATCH 20/22] Update accountAPI.yaml Several minor changes added to be compliant with the SFTI naming conventions. --- accountAPI.yaml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/accountAPI.yaml b/accountAPI.yaml index 8d256e0..3aa9031 100644 --- a/accountAPI.yaml +++ b/accountAPI.yaml @@ -11,7 +11,7 @@ info: contact: email: info@common-api.ch license: - name: Apache-2.0 + name: Apache 2.0 url: https://www.apache.org/licenses/LICENSE-2.0.html servers: - url: account.common-api.ch/api/v4 @@ -392,7 +392,7 @@ paths: X-Correlation-ID: $ref: '#/components/headers/X-Correlation-ID' content: - application/xml; charset=utf-8: + application/xml: schema: type: string format: binary @@ -485,7 +485,7 @@ paths: X-Correlation-ID: $ref: '#/components/headers/X-Correlation-ID' content: - application/xml; charset=utf-8: + application/xml: schema: type: string format: binary From a631fd1f91d35f69973d01ad9f9881f8aade22d7 Mon Sep 17 00:00:00 2001 From: simonmeyerm <115779682+simonmeyerm@users.noreply.github.com> Date: Thu, 20 Feb 2025 16:57:59 +0100 Subject: [PATCH 21/22] Update accountAPI.yaml Description adjustments camt.052 endpoint --- accountAPI.yaml | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/accountAPI.yaml b/accountAPI.yaml index 3aa9031..ad245d5 100644 --- a/accountAPI.yaml +++ b/accountAPI.yaml @@ -419,8 +419,9 @@ paths: - iso20022 summary: Retrieve a list of resource links to account reports (camt.052) description: > - Get the resources links to available account reports (camt.052). - The returned account statements must be conform to the XML schema and + Get the resources links to available account reports (camt.052) generated since the last + End-of-Day (EOD) processing. Only intraday reports created after the most recent EOD cycle are included. + The returned account reports must conform to the XML schema and implementation guidelines defined by Swiss Payment Standards. parameters: - $ref: '#/components/parameters/cursor' From 86cfa7adaf6eabc7544f6209ca478f8a18886294 Mon Sep 17 00:00:00 2001 From: simonmeyerm <115779682+simonmeyerm@users.noreply.github.com> Date: Thu, 20 Feb 2025 17:01:35 +0100 Subject: [PATCH 22/22] Update accountAPI.yaml Correction Lint validations --- accountAPI.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/accountAPI.yaml b/accountAPI.yaml index 372ad6d..237ed39 100644 --- a/accountAPI.yaml +++ b/accountAPI.yaml @@ -419,7 +419,7 @@ paths: - iso20022 summary: Retrieve a list of resource links to account reports (camt.052) description: > - Get the resources links to available account reports (camt.052) generated since the last + Get the resources links to available account reports (camt.052) generated since the last End-of-Day (EOD) processing. Only intraday reports created after the most recent EOD cycle are included. The returned account reports must conform to the XML schema and implementation guidelines defined by Swiss Payment Standards.