Updated Swagger Documentation

This commit is contained in:
Azeez Muibi
2025-03-24 15:15:31 +01:00
parent 67dfc32e4a
commit 9684d6dd29
56 changed files with 1344 additions and 349 deletions
+12 -7
View File
@@ -3,9 +3,9 @@
"tags": [
"BulkSMS"
],
"summary": "BulkSMS Request",
"description": "BulkSMS Request",
"operationId": "BulkSMS",
"summary": "Send Bulk SMS",
"description": "This request is used to send Bulk SMS messages to multiple customers. The max length of the array should equal 20. The API is hosted in FIRSTBANK and it is the HTTP wrapper for the real SMS sending interface.",
"operationId": "bulkSmsNotification",
"requestBody": {
"required": true,
"content": {
@@ -28,7 +28,7 @@
},
"responses": {
"200": {
"description": "BulkSMS Successful",
"description": "Bulk SMS sent successfully",
"content": {
"application/json": {
"schema": {
@@ -43,11 +43,16 @@
}
},
"400": {
"description": "Invalid request"
"description": "Unsuccessful Response with Client Error"
},
"500": {
"description": "Internal server error"
}
}
},
"security": [
{
"api_key": []
}
]
}
}
}
+10 -5
View File
@@ -4,8 +4,8 @@
"CollectLoan"
],
"summary": "Collect Loan Request",
"description": "Collect Loan Request",
"operationId": "CollectLoan",
"description": "This request is to collect money from user accounts. When request is received, FIRSTBANK should check all user accounts and collect as much as possible money to cover existing loan either partially or fully. In response, FIRSTBANK should return total amount that is actually collected from user accounts. First FBN collects body amount, then penal charge. If requested amount is not collected or collected partially FBN places a lien on user account. FBN places lien for body amount and penal charge separately.",
"operationId": "collectLoan",
"requestBody": {
"required": true,
"content": {
@@ -28,7 +28,7 @@
},
"responses": {
"200": {
"description": "CollectLoan Successful",
"description": "Loan Collection Successful",
"content": {
"application/json": {
"schema": {
@@ -48,6 +48,11 @@
"500": {
"description": "Internal server error"
}
}
},
"security": [
{
"api_key": []
}
]
}
}
}
+10 -5
View File
@@ -4,8 +4,8 @@
"CustomerConsent"
],
"summary": "Customer Consent Request",
"description": "Customer Consent Request",
"operationId": "CustomerConsent",
"description": "This endpoint allows FirstBank to send customer consent requests to Simbrella",
"operationId": "customerConsent",
"requestBody": {
"required": true,
"content": {
@@ -28,7 +28,7 @@
},
"responses": {
"200": {
"description": "Successful",
"description": "Successful operation",
"content": {
"application/json": {
"schema": {
@@ -48,6 +48,11 @@
"500": {
"description": "Internal server error"
}
}
},
"security": [
{
"basic_auth": []
}
]
}
}
}
+11 -6
View File
@@ -3,9 +3,9 @@
"tags": [
"Disbursement"
],
"summary": "Disbursement Request",
"description": "Disbursement Request",
"operationId": "Disbursement",
"summary": "Loan Disbursement Request",
"description": "This request should be executed as an atomic operation. Providing a loan and collecting the upfront fees operation should be executed within the same transaction. If one of the operations is failed, the whole transaction should be rolled back. Results of requests sent to this endpoint will be received from NotificationCallback endpoint.",
"operationId": "disbursement",
"requestBody": {
"required": true,
"content": {
@@ -28,7 +28,7 @@
},
"responses": {
"200": {
"description": "Disbursement Successful",
"description": "Disbursement request accepted",
"content": {
"application/json": {
"schema": {
@@ -48,6 +48,11 @@
"500": {
"description": "Internal server error"
}
}
},
"security": [
{
"api_key": []
}
]
}
}
}
+10 -13
View File
@@ -3,11 +3,11 @@
"tags": [
"EligibilityCheck"
],
"summary": "Start the process - initiate steps to eligibility RAC Checks ",
"description": "Initiate Eligibility Check Request",
"operationId": "startEligibilityCheck",
"summary": "Check customer eligibility for loan products",
"description": "This endpoint is used by FirstBank to check if a customer is eligible for loan products and returns available offers",
"operationId": "eligibilityCheck",
"requestBody": {
"description": "Post JSON to conduct eligibility tests",
"description": "Customer information for eligibility check",
"content": {
"application/json": {
"schema": {
@@ -44,21 +44,18 @@
}
},
"400": {
"description": "Invalid ID supplied"
"description": "Invalid request parameters"
},
"404": {
"description": "Pet not found"
"401": {
"description": "Authentication failed"
},
"422": {
"description": "Validation exception"
"500": {
"description": "Internal server error"
}
},
"security": [
{
"petstore_auth": [
"write:pets",
"read:pets"
]
"basic_auth": []
}
]
}
+10 -5
View File
@@ -4,8 +4,8 @@
"LienCheck"
],
"summary": "Lien Check Request",
"description": "Lien Check Request",
"operationId": "LienCheck",
"description": "This method is used to get applied lien amount to the specific account.",
"operationId": "lienCheck",
"requestBody": {
"required": true,
"content": {
@@ -28,7 +28,7 @@
},
"responses": {
"200": {
"description": "LienCheck Successful",
"description": "Lien check successful",
"content": {
"application/json": {
"schema": {
@@ -48,6 +48,11 @@
"500": {
"description": "Internal server error"
}
}
},
"security": [
{
"api_key": []
}
]
}
}
}
+60 -60
View File
@@ -1,65 +1,65 @@
{
"get": {
"tags": [
"LoanInformation"
],
"summary": "Loan Information Request ",
"description": "Loan Information Request",
"operationId": "startEligibilityCheck",
"requestBody": {
"description": "Post JSON to conduct eligibility tests",
"content": {
"application/json": {
"schema": {
"$ref": "../schemas/LoanInformationRequest.json"
}
},
"application/xml": {
"schema": {
"$ref": "../schemas/LoanInformationRequest.json"
}
},
"application/x-www-form-urlencoded": {
"schema": {
"$ref": "../schemas/LoanInformationRequest.json"
}
}
},
"required": true
},
"responses": {
"200": {
"description": "Successful operation",
"content": {
"application/json": {
"schema": {
"$ref": "../schemas/LoanInformationResponse.json"
}
"post": {
"tags": [
"LoanInformation"
],
"summary": "Get information about customer's existing loans",
"description": "Loan Information Request to retrieve details about customer's existing loans",
"operationId": "loanInformation",
"requestBody": {
"description": "Customer information for loan details",
"content": {
"application/json": {
"schema": {
"$ref": "../schemas/LoanInformationRequest.json"
}
},
"application/xml": {
"schema": {
"$ref": "../schemas/LoanInformationRequest.json"
}
},
"application/x-www-form-urlencoded": {
"schema": {
"$ref": "../schemas/LoanInformationRequest.json"
}
}
},
"application/xml": {
"schema": {
"$ref": "../schemas/LoanInformationResponse.json"
}
"required": true
},
"responses": {
"200": {
"description": "Successful operation",
"content": {
"application/json": {
"schema": {
"$ref": "../schemas/LoanInformationResponse.json"
}
},
"application/xml": {
"schema": {
"$ref": "../schemas/LoanInformationResponse.json"
}
}
}
},
"400": {
"description": "Invalid request parameters"
},
"401": {
"description": "Authentication failed"
},
"404": {
"description": "No loans found"
},
"500": {
"description": "Internal server error"
}
}
},
"400": {
"description": "Invalid ID supplied"
},
"404": {
"description": "Loan not found"
},
"422": {
"description": "Validation exception"
}
},
"security": [
{
"petstore_auth": [
"write:pets",
"read:pets"
]
}
]
"security": [
{
"basic_auth": []
}
]
}
}
}
+10 -5
View File
@@ -4,8 +4,8 @@
"NewTransactionCheck"
],
"summary": "New Transaction Check Request",
"description": "New Transaction Check Request",
"operationId": "NewTransactionCheck",
"description": "This new Transaction Check will be utilized for checking status of transactions in new Asynchronous requests. Request will be sent by Simbrella to check the status of Transaction on FirstBank side if Simbrella doesn't receive callback notification 5 minutes after initial request. New list of resultCodes with corresponding resultDescriptions must be provided by FirstBank to notify Simbrella in which cases Simbrella should retry sending the request.",
"operationId": "newTransactionCheck",
"requestBody": {
"required": true,
"content": {
@@ -28,7 +28,7 @@
},
"responses": {
"200": {
"description": "NewTransactionCheck Successful",
"description": "Transaction check successful",
"content": {
"application/json": {
"schema": {
@@ -48,6 +48,11 @@
"500": {
"description": "Internal server error"
}
}
},
"security": [
{
"api_key": []
}
]
}
}
}
+15 -21
View File
@@ -3,25 +3,25 @@
"tags": [
"NotificationCallback"
],
"summary": "Loan Information Request ",
"description": "Loan Information Request",
"operationId": "startEligibilityCheck",
"summary": "Notification Callback",
"description": "This new feature will be used for informing Simbrella about status of the transactions that FBN have processed. Retry mechanism should be implemented by FirstBank in case of connection issues, sending notification should be repeated for 5 minutes in case of there is connection issues, after which Simbrella will try to check the status of transaction with New Transaction Check endpoint. FBN should provide a list of Response Codes with corresponding Response Descriptions for notifications. Please note that AmountCollected field will equal to 0 when transaction type is Disbursement. AmountProvided field will equal to 0 when transaction type is Collection or PenalCharge.",
"operationId": "notificationCallback",
"requestBody": {
"description": "Post JSON to conduct eligibility tests",
"description": "Transaction status notification from FirstBank to Simbrella",
"content": {
"application/json": {
"schema": {
"$ref": "../schemas/LoanInformationRequest.json"
"$ref": "../schemas/NotificationCallbackRequest.json"
}
},
"application/xml": {
"schema": {
"$ref": "../schemas/LoanInformationRequest.json"
"$ref": "../schemas/NotificationCallbackRequest.json"
}
},
"application/x-www-form-urlencoded": {
"schema": {
"$ref": "../schemas/LoanInformationRequest.json"
"$ref": "../schemas/NotificationCallbackRequest.json"
}
}
},
@@ -29,37 +29,31 @@
},
"responses": {
"200": {
"description": "Successful operation",
"description": "Notification received successfully",
"content": {
"application/json": {
"schema": {
"$ref": "../schemas/LoanInformationResponse.json"
"$ref": "../schemas/NotificationCallbackResponse.json"
}
},
"application/xml": {
"schema": {
"$ref": "../schemas/LoanInformationResponse.json"
"$ref": "../schemas/NotificationCallbackResponse.json"
}
}
}
},
"400": {
"description": "Invalid ID supplied"
"description": "Invalid request"
},
"404": {
"description": "Loan not found"
},
"422": {
"description": "Validation exception"
"500": {
"description": "Internal server error"
}
},
"security": [
{
"petstore_auth": [
"write:pets",
"read:pets"
]
"basic_auth": []
}
]
}
}
}
+10 -5
View File
@@ -4,8 +4,8 @@
"PenalCharge"
],
"summary": "Penal Charge Request",
"description": "Penal Charge Request",
"operationId": "PenalCharge",
"description": "This request is used to charge customer for penalty as per existing debt. Results of requests sent to this endpoint will be received from NotificationCallback endpoint.",
"operationId": "penalCharge",
"requestBody": {
"required": true,
"content": {
@@ -28,7 +28,7 @@
},
"responses": {
"200": {
"description": "PenalCharge Successful",
"description": "Penal Charge Request Accepted",
"content": {
"application/json": {
"schema": {
@@ -48,6 +48,11 @@
"500": {
"description": "Internal server error"
}
}
},
"security": [
{
"api_key": []
}
]
}
}
}
+15 -21
View File
@@ -3,25 +3,25 @@
"tags": [
"ProvideLoan"
],
"summary": "Provide Loan Request ",
"description": "Provide Loan Request",
"operationId": "startEligibilityCheck",
"summary": "Provide Loan Request",
"description": "This endpoint is used by FirstBank to request a loan provision for a customer. It allows FirstBank to specify the loan details including the amount, collection type, and loan type.",
"operationId": "provideLoan",
"requestBody": {
"description": "Post JSON to conduct eligibility tests",
"description": "Loan provision request details",
"content": {
"application/json": {
"schema": {
"$ref": "../schemas/EligibilityCheckRequest.json"
"$ref": "../schemas/ProvideLoanRequest.json"
}
},
"application/xml": {
"schema": {
"$ref": "../schemas/EligibilityCheckRequest.json"
"$ref": "../schemas/ProvideLoanRequest.json"
}
},
"application/x-www-form-urlencoded": {
"schema": {
"$ref": "../schemas/EligibilityCheckRequest.json"
"$ref": "../schemas/ProvideLoanRequest.json"
}
}
},
@@ -29,37 +29,31 @@
},
"responses": {
"200": {
"description": "Successful operation",
"description": "Loan provision request processed successfully",
"content": {
"application/json": {
"schema": {
"$ref": "../schemas/EligibilityCheckResponse.json"
"$ref": "../schemas/ProvideLoanResponse.json"
}
},
"application/xml": {
"schema": {
"$ref": "../schemas/EligibilityCheckResponse.json"
"$ref": "../schemas/ProvideLoanResponse.json"
}
}
}
},
"400": {
"description": "Invalid ID supplied"
"description": "Invalid request"
},
"404": {
"description": "Pet not found"
},
"422": {
"description": "Validation exception"
"500": {
"description": "Internal server error"
}
},
"security": [
{
"petstore_auth": [
"write:pets",
"read:pets"
]
"basic_auth": []
}
]
}
}
}
+8 -3
View File
@@ -4,7 +4,7 @@
"RACCheck"
],
"summary": "Risk Acceptance Criteria Check",
"description": "Check if a customer passes the Risk Acceptance Criteria defined by the bank",
"description": "This request is used to check if a customer passes the Risk Acceptance Criteria defined by the bank",
"operationId": "racCheck",
"requestBody": {
"required": true,
@@ -48,6 +48,11 @@
"500": {
"description": "Internal server error"
}
}
},
"security": [
{
"api_key": []
}
]
}
}
}
+19 -7
View File
@@ -3,11 +3,11 @@
"tags": [
"Repayment"
],
"summary": "Repayment Request",
"description": "Repayment Request",
"operationId": "Repayment",
"summary": "Process a loan repayment request",
"description": "Repayment Request to initiate loan repayment",
"operationId": "repayment",
"requestBody": {
"required": true,
"description": "Repayment request details",
"content": {
"application/json": {
"schema": {
@@ -24,7 +24,8 @@
"$ref": "../schemas/RepaymentRequest.json"
}
}
}
},
"required": true
},
"responses": {
"200": {
@@ -43,11 +44,22 @@
}
},
"400": {
"description": "Invalid request"
"description": "Invalid request parameters"
},
"401": {
"description": "Authentication failed"
},
"404": {
"description": "Debt not found"
},
"500": {
"description": "Internal server error"
}
}
},
"security": [
{
"basic_auth": []
}
]
}
}
+11 -6
View File
@@ -3,9 +3,9 @@
"tags": [
"RevokeEnableConsent"
],
"summary": "Revoke Enable Consent Request",
"description": "Revoke Enable Consent Request",
"operationId": "RevokeEnableConsent",
"summary": "Revoke or Enable Consent Request",
"description": "This endpoint is used to notify FirstBank about the processing of a customer consent request. It allows Simbrella to inform FirstBank when a customer's consent has been either enabled or revoked.",
"operationId": "revokeEnableConsent",
"requestBody": {
"required": true,
"content": {
@@ -28,7 +28,7 @@
},
"responses": {
"200": {
"description": "RevokeEnableConsent Successful",
"description": "Consent status update successful",
"content": {
"application/json": {
"schema": {
@@ -48,6 +48,11 @@
"500": {
"description": "Internal server error"
}
}
},
"security": [
{
"api_key": []
}
]
}
}
}
+12 -7
View File
@@ -3,9 +3,9 @@
"tags": [
"SMS"
],
"summary": "SMS Request",
"description": "SMS Request",
"operationId": "SMS",
"summary": "Send Single SMS",
"description": "This request is used to send a single SMS message to a customer. The API is hosted in FIRSTBANK and it is the HTTP wrapper for the real SMS sending interface.",
"operationId": "smsNotification",
"requestBody": {
"required": true,
"content": {
@@ -28,7 +28,7 @@
},
"responses": {
"200": {
"description": "SMS Successful",
"description": "SMS sent successfully",
"content": {
"application/json": {
"schema": {
@@ -43,11 +43,16 @@
}
},
"400": {
"description": "Invalid request"
"description": "Unsuccessful Response with Client Error"
},
"500": {
"description": "Internal server error"
}
}
},
"security": [
{
"api_key": []
}
]
}
}
}
+10 -13
View File
@@ -3,11 +3,11 @@
"tags": [
"SelectOffer"
],
"summary": "This method is used the send the offer the customer selected to Simbrella ",
"description": "This method is used the send the offer the customer selected to Simbrella",
"operationId": "startEligibilityCheck",
"summary": "Send the offer the customer selected to Simbrella",
"description": "This method is used to send the offer the customer selected to Simbrella",
"operationId": "selectOffer",
"requestBody": {
"description": "Post JSON to conduct eligibility tests",
"description": "Customer selected offer details",
"content": {
"application/json": {
"schema": {
@@ -44,21 +44,18 @@
}
},
"400": {
"description": "Invalid ID supplied"
"description": "Invalid request parameters"
},
"404": {
"description": "Offers not found"
"401": {
"description": "Authentication failed"
},
"422": {
"description": "Validation exception"
"500": {
"description": "Internal server error"
}
},
"security": [
{
"petstore_auth": [
"write:pets",
"read:pets"
]
"basic_auth": []
}
]
}
+10 -5
View File
@@ -4,8 +4,8 @@
"TokenValidation"
],
"summary": "Token Validation Request",
"description": "Token Validation Request",
"operationId": "TokenValidation",
"description": "This method is used while users from FBN access Customer Care Portal. User will enter soft/hard token code. This will be captured and sent to this endpoint for validation.",
"operationId": "validateToken",
"requestBody": {
"required": true,
"content": {
@@ -28,7 +28,7 @@
},
"responses": {
"200": {
"description": "TokenValidation Successful",
"description": "Token validation successful",
"content": {
"application/json": {
"schema": {
@@ -48,6 +48,11 @@
"500": {
"description": "Internal server error"
}
}
},
"security": [
{
"api_key": []
}
]
}
}
}
+11 -6
View File
@@ -3,9 +3,9 @@
"tags": [
"TransactionVerify"
],
"summary": "Transaction Verify Request",
"description": "Transaction Verify Request",
"operationId": "TransactionVerify",
"summary": "Transaction Verification Request",
"description": "This request is to double check the response received from DisburseLoan and CollectLoan Synchronous APIs. This request is required to check transaction result on FIRSTBANK.",
"operationId": "transactionVerify",
"requestBody": {
"required": true,
"content": {
@@ -28,7 +28,7 @@
},
"responses": {
"200": {
"description": "TransactionVerify Successful",
"description": "Transaction Verification Successful",
"content": {
"application/json": {
"schema": {
@@ -48,6 +48,11 @@
"500": {
"description": "Internal server error"
}
}
},
"security": [
{
"api_key": []
}
]
}
}
}