Skip to content

Commit

Permalink
Merge branch 'main' into 119-new-enum-in-matrimonial-property-scheme-1
Browse files Browse the repository at this point in the history
  • Loading branch information
rolfwagner committed Jan 30, 2023
2 parents 4bcaa02 + 9a883f7 commit d34962f
Showing 1 changed file with 46 additions and 37 deletions.
83 changes: 46 additions & 37 deletions mortgageAPI.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
openapi: 3.0.0
info:
version: 3.1.0
version: 3.2.0
title: Common Mortgage API (Public)
description:
This specification defines a common mortgage API for mortgages as used in Switzerland. The API is supposed to be used by requesting parties who want to get, extend, or transfer mortgages from and to financial institutions.
Expand All @@ -18,7 +18,7 @@ externalDocs:
url: https://www.common-api.ch
tags:
- name: Full Mortgage Cases
description: Operations related to full mortgage cases including the application details
description: Operatios related to full mortgage cases including the application details
- name: Existing Mortgages
description: Operations related with existing mortgages
- name: Mortgage Products and Conditions
Expand Down Expand Up @@ -259,7 +259,6 @@ paths:
- libor
- saron
- fixed
default: missingDefaultOrExample
description: The type of the interest rates (for filtering)
- in: query
name: duration
Expand Down Expand Up @@ -330,13 +329,11 @@ paths:
name: duration
schema:
type: string
default: missingDefaultOrExample
description: The duration (for filtering)
- in: query
name: interest
schema:
type: string
example: missingDefaultOrExample
description: The interest (for filtering)
- $ref: '#/components/parameters/clientid_in_header'
- $ref: '#/components/parameters/correlation_in_header'
Expand Down Expand Up @@ -395,7 +392,7 @@ paths:
- $ref: '#/components/parameters/agent_in_header'
responses:
'201':
$ref: '#/components/responses/standard201'
$ref: '#/components/responses/standard201'
'400':
$ref: '#/components/responses/standard400'
'401':
Expand Down Expand Up @@ -504,7 +501,7 @@ paths:
$ref: '#/components/responses/standard503'

put:
summary: Update the applications details $
summary: Update the application's details
description: Update the application’s details. Note that changing the application's details should not be possible after the application has been accepted by the FI.
tags:
- Mortgage Application
Expand Down Expand Up @@ -561,7 +558,7 @@ paths:

delete:
summary: Cancel the application and removing it
description: Cancel the application and removing it
description: The request to delete a previously shared application.
tags:
- Mortgage Application
parameters:
Expand Down Expand Up @@ -637,7 +634,7 @@ paths:
type: string
responses:
'201':
$ref: '#/components/responses/standard201'
$ref: '#/components/responses/standard201'
'400':
$ref: '#/components/responses/standard400'
'401':
Expand Down Expand Up @@ -758,7 +755,7 @@ paths:
/mortgages/applications/{applicationId}/documents:
post:
summary: Add documents for the specific application
description: Add to a specific application’s documents
description: Documents can be assigned to a specific application ID.
tags:
- Mortgage Application
parameters:
Expand Down Expand Up @@ -815,7 +812,7 @@ paths:
example: 576f8de3-6b30-4882-a7af-da2132a456cf
responses:
'201':
$ref: '#/components/responses/standard201'
$ref: '#/components/responses/standard201'
'400':
$ref: '#/components/responses/standard400'
'401':
Expand All @@ -835,7 +832,7 @@ paths:

get:
summary: Get a list of submitted documents for a specifically placed application
description: Get a list of documents submitted for a specifically placed application
description: All documents that have been shared against the Application ID can be retrieved here.
tags:
- Mortgage Application
parameters:
Expand All @@ -862,38 +859,38 @@ paths:
properties:
filename:
type: string
example: missingDefaultOrExample
example: customer_id.pdf
filetype:
type: string
example: missingDefaultOrExample
example: pdf
documentId:
type: string
format: uuid
example: missingDefaultOrExample
example: 7f648f12-fd45-4930-6543-456hf5671c37
description: Document ID in uuid v4 format
filesize:
type: integer
example: missingDefaultOrExample

example: 1024
description: The file size in bytes.
uploaddate:
$ref: '#/components/schemas/Date'
statusInfo:
description: Document status info
type: object
required:
- status
example: missingDefaultOrExample
properties:
status:
type: string
enum:
- accepted
- rejected
- pending
default: missingDefaultOrExample
default: pending
description: Get the current status of the application
statusReason:
type: string
example: missingDefaultOrExample
example: Additional information that can be shared with the status.
description: The reason, of current status.
headers:
X-Correlation-ID:
Expand Down Expand Up @@ -1011,8 +1008,8 @@ paths:
example: pending
detail:
type: string
example: Waiting for details
description: missingDescription
example: Waiting for details
description: Additional information that can be shared with the status.
headers:
X-Correlation-ID:
schema:
Expand Down Expand Up @@ -1062,7 +1059,7 @@ paths:
$ref: '#/components/schemas/FinancingRequest'
responses:
'201':
$ref: '#/components/responses/standard201'
$ref: '#/components/responses/standard201'
'400':
$ref: '#/components/responses/standard400'
'401':
Expand All @@ -1083,8 +1080,8 @@ paths:
/mortgages/applications/{applicationId}/financing-requests/{financingRequestId}/required-information:
get:
summary: List all required documents / information for processing specific Financial request at FI
description: List all required documents / information for processing specific Financial request at FI
This can be used when NO offer is available from FI
description: All required documents for a specific FinancingRequestId can be retrieved herewith.

tags:
- Mortgage Financing Request
parameters:
Expand Down Expand Up @@ -1208,7 +1205,7 @@ paths:
/mortgages/applications/{applicationId}/financing-requests/{financingRequestId}/offers:
get:
summary: List all binding offers for a given financing request
description: List all binding offers for a given application
description: Lists the offers for a transferred application and the corresponding financing request.
tags:
- Mortgage Offers
parameters:
Expand Down Expand Up @@ -1396,7 +1393,7 @@ paths:
/mortgages/applications/{applicationId}/financing-requests/{financingRequestId}/offers/{offerId}/required-information:
get:
summary: List all required documents / information for processing specific offer at FI
description: List all required documents / information for processing specific offer at FI
description: Lists the required documents for the previously submitted case. Thus, the TPP knows which documents are needed for the later check.
tags:
- Mortgage Offers
parameters:
Expand Down Expand Up @@ -1483,7 +1480,7 @@ paths:
- $ref: '#/components/parameters/agent_in_header'
responses:
'201':
$ref: '#/components/responses/standard201'
$ref: '#/components/responses/standard201'
'400':
$ref: '#/components/responses/standard400'
'401':
Expand Down Expand Up @@ -1555,7 +1552,7 @@ paths:
/mortgages/orders/{orderId}/status:
get:
summary: Get the current status of the order
description: Get the current status of the order (rejected with reason, accepted, pending with reason)
description: Returns the current status of the order. An order can be in accepted rejected or pending status. In addition, further details regarding the status can be transferred.
tags:
- Mortgage Order
parameters:
Expand Down Expand Up @@ -1906,7 +1903,7 @@ components:
# ------------
# ---- Response
commonResourceCreatedResponse:
title: Resource created response
title: Recource created response
description: Uuid v4 of the created resource
example: 20460121-6aff-485b-a61d-6056ecd72bd8
type: object
Expand Down Expand Up @@ -2036,7 +2033,7 @@ components:
description: cost of renovation
minergieStandardType:
type: string
enum:
enum:
- none
- minergie
- minergie-p
Expand Down Expand Up @@ -2512,7 +2509,7 @@ components:
$ref: '#/components/schemas/Date'
offerDate:
$ref: '#/components/schemas/Date'
description: The date when the offer is made by the FI. Optional field for use cases where no MortgageOffer object is used and therefore the offer date needs to be directly in Mortgage object.
description: The date when the offer is made by the FI. Optional field for use cases where no MortageOffer object is used and therefore the offer date needs to be directly in Mortgage object.
example: 2018-04-05
validTo:
$ref: '#/components/schemas/Date'
Expand Down Expand Up @@ -2888,6 +2885,12 @@ components:
example: 6e61ff5d-3ffd-4254-a77d-73cc25d35e92
amount:
$ref: '#/components/schemas/Amount'
increaseAmount:
$ref: '#/components/schemas/Amount'
increasePurpose:
type: string
description: The purpose of the increase.
example: renovation of the kitchen
amortizations:
$ref: '#/components/schemas/Amortizations'
tranches:
Expand Down Expand Up @@ -2927,7 +2930,7 @@ components:
type: integer
minimum: 1
maximum: 20
interest:
interest:
$ref: '#/components/schemas/Interest'
interestRateType:
type: string
Expand Down Expand Up @@ -2970,6 +2973,12 @@ components:
description: Uuid v4 of the corresponding application
amount:
$ref: '#/components/schemas/Amount'
increaseAmount:
$ref: '#/components/schemas/Amount'
increasePurpose:
type: string
description: The purpose of the increase.
example: renovation of the kitchen
tranches:
type: array
items:
Expand Down Expand Up @@ -3425,7 +3434,7 @@ components:

# ---- Document ----
Document:
description: Document containing information for given document type for given order.
description: Document containing information for givent document type for given order.
type: object
required:
- name
Expand Down Expand Up @@ -3489,7 +3498,7 @@ components:

# ---- AssetProvider ----
AssetProvider:
description: Asset provider for each asset, additional information must be transferred. E.g. in case the applicant owns an additional security of type insurance, insurance company name is provided
description: Asset provider for each asset, additional information must be transfered. E.g. in case the applicant owns an addtional security of type insurance, insurance company name is provided
type: object
required:
- name
Expand Down Expand Up @@ -3533,14 +3542,14 @@ components:
currentRate:
type: number
format: double
description: Interest rate in decimals. 2.45% would be sent as 0.0245. For flexible interest mortgage this would show the margin above interest.Base
description: Interest reate in decimals. 2.45% would be sent as 0.0245. For flexible interest mortgage this would show the margin above interest.Base
minimum: 0
maximum: 1
example: 0.5
base:
type: number
format: double
description: Base rate upon margin is applied (e.g. for SARON).
description: Base rate uupon margin is applied (e.g. for SARON).
minimum: 0
maximum: 1
example: 0.5
Expand Down

0 comments on commit d34962f

Please sign in to comment.