From ea9ad3578784a689bce020675e530fedb5e0494a Mon Sep 17 00:00:00 2001 From: James Bligh Date: Thu, 2 Nov 2023 12:53:18 +1100 Subject: [PATCH] First cut of LIXI2 scheme meta data --- .../Simple-Bank-Account-Origination.md | 2 +- .../Simple-Bank-Account-Origination-OAS.md | 129 ++++++++++++++-- .../Simple-Bank-Account-Origination.json | 144 ++++++++++++++++-- docs/Support_Files/env.json | 5 + 4 files changed, 256 insertions(+), 24 deletions(-) create mode 100644 docs/Support_Files/env.json diff --git a/docs/Standards/Simple-Bank-Account-Origination.md b/docs/Standards/Simple-Bank-Account-Origination.md index 872dcaa..03b3306 100644 --- a/docs/Standards/Simple-Bank-Account-Origination.md +++ b/docs/Standards/Simple-Bank-Account-Origination.md @@ -2,7 +2,7 @@ **EXPERIMENTAL** -*Current Version:* **0.0.3** +*Current Version:* **0.0.4** Additional endpoints, and extensions to existing endpoints, to facilitate the receipt of an account opening instruction to begin the process of a customer opening a new bank account. diff --git a/docs/Support_Files/Simple-Bank-Account-Origination-OAS.md b/docs/Support_Files/Simple-Bank-Account-Origination-OAS.md index c3fcdb6..ea0d383 100644 --- a/docs/Support_Files/Simple-Bank-Account-Origination-OAS.md +++ b/docs/Support_Files/Simple-Bank-Account-Origination-OAS.md @@ -1,4 +1,17 @@ -

CDR Experimantal Simple Bank Account Origination API v0.0.3

+--- +title: CDR Experimantal Simple Bank Account Origination API +language_tabs: [] +toc_footers: [] +includes: [] +search: true +highlight_theme: darkula +headingLevel: 2 + +--- + +

CDR Experimantal Simple Bank Account Origination API v0.0.4

+ +> Scroll down for example requests and responses. Specification of endpoints defined in the Simple Bank Account Origination experimental standard. This is an experimental standard created by the Data Standards Body (DSB) as part of the Consumer Data Standards @@ -15,6 +28,8 @@ License: MIT License +> Code samples + `GET /DSB/banking/origination/schemes/{schemeId}` Obtain the meta data describing how to make an application for a family of products. @@ -32,20 +47,44 @@ Obtain the meta data describing how to make an application for a family of produ > 200 Response ```json -null +{ + "data": { + "schemeUType": "lixi1", + "lixi1": {}, + "lixi2": { + "baseUri": "string", + "lixiCode": "string", + "lixiVersion": "string", + "lixiCustomVersion": "string", + "apiVersion": "string", + "productCodeMappings": [ + { + "productId": "string", + "productCode": "string" + } + ], + "schematronUri": "string", + "apiSpecificationUri": "string", + "customVersionUri": "string" + }, + "cdrApplyForBankAccountV1": {} + }, + "links": { + "self": "string" + }, + "meta": {} +} ```

Responses

|Status|Meaning|Description|Schema| |---|---|---|---| -|200|[OK](https://tools.ietf.org/html/rfc7231#section-6.3.1)|Successful response|Inline| +|200|[OK](https://tools.ietf.org/html/rfc7231#section-6.3.1)|Successful response|[OriginationSchemeResponseV1](#schemaoriginationschemeresponsev1)| |400|[Bad Request](https://tools.ietf.org/html/rfc7231#section-6.5.1)|The following error codes MUST be supported:
|[ResponseErrorListV2](#schemaresponseerrorlistv2)| |406|[Not Acceptable](https://tools.ietf.org/html/rfc7231#section-6.5.6)|The following error codes MUST be supported:
|[ResponseErrorListV2](#schemaresponseerrorlistv2)| |422|[Unprocessable Entity](https://tools.ietf.org/html/rfc2518#section-10.3)|The following error codes MUST be supported:
|[ResponseErrorListV2](#schemaresponseerrorlistv2)| -

Response Schema

- ### Response Headers |Status|Header|Type|Format|Description| @@ -60,6 +99,8 @@ This operation does not require authentication +> Code samples + `POST /DSB/banking/accounts` Submit an application, on behalf of a consumer, to apply for an account to be originated. @@ -109,24 +150,71 @@ This operation does not require authentication # Schemas -

MetaError

+

OriginationSchemeResponseV1

- + ```json { - "urn": "string" + "data": { + "schemeUType": "lixi1", + "lixi1": {}, + "lixi2": { + "baseUri": "string", + "lixiCode": "string", + "lixiVersion": "string", + "lixiCustomVersion": "string", + "apiVersion": "string", + "productCodeMappings": [ + { + "productId": "string", + "productCode": "string" + } + ], + "schematronUri": "string", + "apiSpecificationUri": "string", + "customVersionUri": "string" + }, + "cdrApplyForBankAccountV1": {} + }, + "links": { + "self": "string" + }, + "meta": {} } ``` -*Additional data for customised error codes* - ### Properties |Name|Type|Required|Restrictions|Description| |---|---|---|---|---| -|urn|string|false|none|The CDR error code URN which the application-specific error code extends. Mandatory if the error `code` is an application-specific error rather than a standardised error code.| +|data|object|true|none|none| +|» schemeUType|string|true|none|The type of origination scheme represented| +|» lixi1|object|false|none|Provides the metadata for making an application using a LIXI1 gateway. Mandatory if schemeUType is set to 'lixi1'| +|» lixi2|object|false|none|Provides the metadata for making an application using a LIXI2 gateway. Mandatory if schemeUType is set to 'lixi2'| +|»» baseUri|string|true|none|Base path used to access the LIXI2 gateway| +|»» lixiCode|string|true|none|The LIXI participant code, assigned by LIXI, for the receiving organisation| +|»» lixiVersion|string|true|none|The supported version of the LIXI2 schema| +|»» lixiCustomVersion|string|false|none|Optional identifier of a custom version of the LIXI payloads that are accepted if the receiving organisation has made custom extensions or modifications to the LIXI schema| +|»» apiVersion|string|false|none|Optional version of an API schema definition| +|»» productCodeMappings|[object]|false|none|Optional mapping of CDR product IDs to product codes used in LIXI applications via this origination scheme. If absent, or if a mapping is not included, then the CDR product ID is expected to be used as the LIXI product code| +|»»» productId|string|true|none|The CDR product ID to map from| +|»»» productCode|string|true|none|The LIXI product code to map to| +|»» schematronUri|string|false|none|Optional reference to a Schematron file indicating the valid use of this LIXI gateway| +|»» apiSpecificationUri|string|false|none|Optional reference to an Open API Specification file describing the API version specified in the 'apiVersion' field| +|»» customVersionUri|string|false|none|Optional reference to additional information describing the customisations and extensions make to the LIXI scheams| +|» cdrApplyForBankAccountV1|object|false|none|Provides the metadata for making an application using version 1 of the CDR 'Apply For Bank Account' endpoint. Mandatory if schemeUType is set to 'cdrApplyForBankAccountV1'| +|links|[Links](#schemalinks)|true|none|none| +|meta|[Meta](#schemameta)|true|none|none| + +#### Enumerated Values + +|Property|Value| +|---|---| +|schemeUType|lixi1| +|schemeUType|lixi2| +|schemeUType|cdrApplyForBankAccountV1|

ResponseErrorListV2

@@ -232,3 +320,22 @@ This operation does not require authentication |totalRecords|integer|true|none|The total number of records in the full set. See [pagination](#pagination).| |totalPages|integer|true|none|The total number of pages in the full set. See [pagination](#pagination).| +

MetaError

+ + + +```json +{ + "urn": "string" +} + +``` + +*Additional data for customised error codes* + +### Properties + +|Name|Type|Required|Restrictions|Description| +|---|---|---|---|---| +|urn|string|false|none|The CDR error code URN which the application-specific error code extends. Mandatory if the error `code` is an application-specific error rather than a standardised error code.| + diff --git a/docs/Support_Files/Simple-Bank-Account-Origination.json b/docs/Support_Files/Simple-Bank-Account-Origination.json index e6918cb..2db1ede 100644 --- a/docs/Support_Files/Simple-Bank-Account-Origination.json +++ b/docs/Support_Files/Simple-Bank-Account-Origination.json @@ -12,7 +12,7 @@ "url": "https://opensource.org/licenses/MIT" }, "title": "CDR Experimantal Simple Bank Account Origination API", - "version": "0.0.3" + "version": "0.0.4" }, "servers": [ { @@ -51,7 +51,9 @@ "200": { "content": { "application/json": { - "schema": {} + "schema": { + "$ref": "#/components/schemas/OriginationSchemeResponseV1" + } } }, "description": "Successful response", @@ -95,7 +97,7 @@ } }, "/DSB/banking/accounts": { - "summary": "Apply For Account", + "summary": "Apply For Bank Account", "x-version": "1", "post": { "description": "Submit an application, on behalf of a consumer, to apply for an account to be originated.", @@ -200,18 +202,123 @@ }, "responses": {}, "schemas": { - "MetaError": { + "OriginationSchemeResponseV1": { + "required": [ + "data", + "links", + "meta" + ], "type": "object", "properties": { - "urn": { - "type": "string", - "description": "The CDR error code URN which the application-specific error code extends. Mandatory if the error `code` is an application-specific error rather than a standardised error code." + "data": { + "required": [ + "schemeUType" + ], + "x-conditional": [ + "lixi1", + "lixi2", + "cdrApplyV1" + ], + "type": "object", + "properties": { + "schemeUType": { + "type": "string", + "description": "The type of origination scheme represented", + "enum": [ + "lixi1", + "lixi2", + "cdrApplyForBankAccountV1" + ] + }, + "lixi1": { + "type": "object", + "description": "Provides the metadata for making an application using a LIXI1 gateway. Mandatory if schemeUType is set to 'lixi1'", + "properties": {} + }, + "lixi2": { + "type": "object", + "description": "Provides the metadata for making an application using a LIXI2 gateway. Mandatory if schemeUType is set to 'lixi2'", + "required": [ + "baseUri", + "lixiCode", + "lixiVersion" + ], + "properties": { + "baseUri": { + "type": "string", + "description": "Base path used to access the LIXI2 gateway", + "x-cds-type": "URIString" + }, + "lixiCode": { + "type": "string", + "description": "The LIXI participant code, assigned by LIXI, for the receiving organisation" + }, + "lixiVersion": { + "type": "string", + "description": "The supported version of the LIXI2 schema" + }, + "lixiCustomVersion": { + "type": "string", + "description": "Optional identifier of a custom version of the LIXI payloads that are accepted if the receiving organisation has made custom extensions or modifications to the LIXI schema" + }, + "apiVersion": { + "type": "string", + "description": "Optional version of an API schema definition" + }, + "productCodeMappings": { + "type": "array", + "description": "Optional mapping of CDR product IDs to product codes used in LIXI applications via this origination scheme. If absent, or if a mapping is not included, then the CDR product ID is expected to be used as the LIXI product code", + "items": { + "required": [ + "productId", + "productCode" + ], + "type": "object", + "properties": { + "productId": { + "type": "string", + "description": "The CDR product ID to map from" + }, + "productCode": { + "type": "string", + "description": "The LIXI product code to map to" + } + } + } + }, + "schematronUri": { + "type": "string", + "description": "Optional reference to a Schematron file indicating the valid use of this LIXI gateway", + "x-cds-type": "URIString" + }, + "apiSpecificationUri": { + "type": "string", + "description": "Optional reference to an Open API Specification file describing the API version specified in the 'apiVersion' field", + "x-cds-type": "URIString" + }, + "customVersionUri": { + "type": "string", + "description": "Optional reference to additional information describing the customisations and extensions make to the LIXI scheams", + "x-cds-type": "URIString" + } + } + }, + "cdrApplyForBankAccountV1": { + "type": "object", + "description": "Provides the metadata for making an application using version 1 of the CDR 'Apply For Bank Account' endpoint. Mandatory if schemeUType is set to 'cdrApplyForBankAccountV1'", + "required": [ + ], + "properties": {} + } + } + }, + "links": { + "$ref": "#/components/schemas/Links" + }, + "meta": { + "$ref": "#/components/schemas/Meta" } - }, - "description": "Additional data for customised error codes", - "x-conditional": [ - "urn" - ] + } }, "ResponseErrorListV2": { "required": [ @@ -326,6 +433,19 @@ "totalRecords" ], "type": "object" + }, + "MetaError": { + "type": "object", + "properties": { + "urn": { + "type": "string", + "description": "The CDR error code URN which the application-specific error code extends. Mandatory if the error `code` is an application-specific error rather than a standardised error code." + } + }, + "description": "Additional data for customised error codes", + "x-conditional": [ + "urn" + ] } } } diff --git a/docs/Support_Files/env.json b/docs/Support_Files/env.json new file mode 100644 index 0000000..8c1029f --- /dev/null +++ b/docs/Support_Files/env.json @@ -0,0 +1,5 @@ +{ + "language_tabs": [], + "omitHeader": true, + "codeSamples": true +} \ No newline at end of file