Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
222 changes: 120 additions & 102 deletions generate.rb

Large diffs are not rendered by default.

656 changes: 337 additions & 319 deletions openapi.json

Large diffs are not rendered by default.

108 changes: 108 additions & 0 deletions schemas/cash_deposit_barcode.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,108 @@
{
"definitions": {
"cashDepositRelationships": {
"type": "object",
"title": "cashDepositRelationships",
"properties": {
"account": {
"type": "object",
"properties": {
"data": {
"type": "object",
"properties": {
"type": {
"type": "string",
"enum": [
"account",
"depositAccount",
"batchAccount"
]
},
"id": {
"$ref": "types.json#/definitions/identifier"
}
},
"required": [
"type",
"id"
],
"additionalProperties": false
}
},
"required": [
"data"
],
"additionalProperties": false
},
"customer": {
"type": "object",
"properties": {
"data": {
"type": "object",
"properties": {
"type": {
"type": "string",
"enum": [
"businessCustomer",
"individualCustomer",
"customer"
]
},
"id": {
"$ref": "types.json#/definitions/identifier"
}
},
"required": [
"type",
"id"
],
"additionalProperties": false
}
},
"required": [
"data"
],
"additionalProperties": false
}
},
"required": [
"account",
"customer"
],
"additionalProperties": false
}
},
"title": "CashDepositBarcodeResource",
"type": "object",
"properties": {
"type": {
"type": "string",
"enum": ["cashDepositBarcode"]
},
"id": {
"$ref": "types.json#/definitions/identifier"
},
"attributes": {
"type": "object",
"properties": {
"barcodeNumber": {
"type": "string"
},
"expiration": {
"type": "string",
"format": "date-time"},
"storeId": {
"type": "string"
},
"retailerName": {
"type": "string"}
},
"required": ["barcodeNumber", "expiration", "storeId", "retailerName"]
},
"relationships": {
"$ref": "#/definitions/cashDepositRelationships"
}
},
"additionalProperties": false,
"required": ["type", "attributes", "relationships"]
}
139 changes: 139 additions & 0 deletions schemas/cash_deposit_paths.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,139 @@
{
"cash_deposits": {
"get": {
"tags": [
"Get List Store Locations"
],
"operationId": "execute",
"summary": "Get List Cash Deposits",
"description": "Get List Cash Deposits from API ",
"parameters": [
{
"name": "page",
"in": "query",
"style": "deepObject",
"allowReserved": true,
"schema": {
"$ref": "types.json#/definitions/listPageParametersObject"
}
},
{
"name": "filter",
"in": "query",
"style": "deepObject",
"allowReserved": true,
"schema": {
"type": "object",
"properties": {
"coordinates": {
"$ref": "types.json#/definitions/coordinates"
},
"postalCode": {
"type": "string"
},
"serviceType": {
"type": "string"
}
}
}
}
],
"responses": {
"200": {
"description": "Successful Response",
"content": {
"application/vnd.api+json; charset=utf-8": {
"schema": {
"type": "array",
"title": "UnitCashDepositsListResponse",
"items": {
"$ref": "store_location.json"
}
}
}
}
}
}
}
},
"cash_deposit_barcode": {
"get": {
"tags": [
"Retrieve Barcode Image"
],
"operationId": "execute",
"description": "Retrieves a cash deposit barcode image using the unique barcode number provided by the Generate Barcode endpoint.",
"parameters": [
{
"schema": {
"type": "string"
},
"name": "barcodeNumber",
"in": "path",
"description": "The unique identifier of a barcode, obtained from Generate Barcode endpoint.",
"required": true
}
],
"summary": "Get Barcode Image",
"responses": {
"200": {
"description": "Successful Response",
"content": {
"application/pdf": {
"schema": {
"type": "string",
"format": "binary"
}
}
}
}
}
}
},
"generate_cash_deposit_barcode": {
"post": {
"tags": [
"Generate Barcode"
],
"operationId": "execute",
"summary": "Create Check Deposit",
"description": "Create a Check Deposit via API ",
"requestBody": {
"description": "Create Check Deposit Request",
"required": true,
"content": {
"application/vnd.api+json": {
"schema": {
"type": "object",
"properties": {
"data": {
"$ref": "generateBarcode.json"
}
}
}
}
}
},
"responses": {
"200": {
"description": "Successful Response",
"content": {
"application/vnd.api+json; charset=utf-8": {
"schema": {
"type": "object",
"title": "UnitCashDepositResponse",
"properties": {
"data": {
"$ref": "cash_deposit_barcode.json"
}
}
}
}
}
}
}
}
}
}


52 changes: 52 additions & 0 deletions schemas/generateBarcode.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
{
"definitions": {
"createCashDepositRelationships": {
"type": "object",
"properties": {
"account": {
"$ref": "types.json#/definitions/Relationship"
},
"customer": {
"$ref": "types.json#/definitions/customersRelationship"
}
},
"required": [
"account",
"customer"
],
"additionalProperties": false
}
},
"title": "Cash Deposit Barcode",
"type": "object",
"properties": {
"type": {
"type": "string",
"default": "cashDepositBarcode",
"enum": [
"cashDepositBarcode"
]
},
"attributes": {
"type": "object",
"properties": {
"storeId": {
"type": "string"
}
},
"required": [
"storeId"
],
"additionalProperties": false
},
"relationships": {
"$ref": "#/definitions/createCashDepositRelationships"
}
},
"required": [
"type",
"attributes",
"relationships"
],
"additionalProperties": false
}
52 changes: 52 additions & 0 deletions schemas/store_location.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
{
"title": "Store Location",
"type": "object",
"properties": {
"type": {
"type": "string",
"enum": [
"storeLocation"
]
},
"id": {
"$ref": "types.json#/definitions/identifier"
},
"attributes": {
"type": "object",
"properties": {
"storeId": {
"type": "string"
},
"retailerName": {
"type": "string"
},
"phone": {
"$ref": "types.json#/definitions/phone"
},
"address":{
"$ref":"types.json#/definitions/address"
},
"coordinates": {
"$ref": "types.json#/definitions/coordinates"
},
"distance": {
"type": "number"
}
},
"required": [
"storeId",
"retailerName",
"phone",
"address",
"coordinates"
],
"additionalProperties": false
}
},
"additionalProperties": false,
"required": [
"type",
"id",
"attributes"
]
}
Loading