OVPAY-879 - Added schemas for Failures v2.

This commit is contained in:
Bas Boterman 2024-12-24 13:27:22 +01:00
parent 8111b631f3
commit 4ed63a75bf

View File

@ -216,43 +216,14 @@ paths:
content: content:
application/json: application/json:
schema: schema:
$ref: "#/components/schemas/unavailable" $ref: "#/components/schemas/ProcessingFailuresPostRequestBody"
example:
{
"department": "900",
"costCenter": "84955",
"costType": "619031",
"documentDate": "2022-01-01",
"documentCode": "VERK_FACTUUR",
"accountingPeriod": "2024/10",
"transactionDescription": "Dagkaart",
"contraAccountNumber": "220.10419",
"status": "open",
"occurence": 1,
"processingFailureInstances":
[
{
"processingFailureInstanceId": "9afa9a6b-5b6a-4b0a-9c9e-4b0a5b6a4b0a",
"processingFailureId": "c93a5b6a-5b6a-4b0a-9c9e-4b0a5b6a4b0a",
"timestamp": "2022-01-01 00:00:00",
"failureReason": "122be602-139d-49f5-b34f-1e3e2de29408",
"element": "costCenter",
"occurence": 1,
"change": "Adapt config",
},
],
}
responses: responses:
"201": "201":
description: Created description: Created
content: content:
application/json: application/json:
schema: schema:
$ref: "#/components/schemas/unavailable" $ref: "#/components/schemas/ProcessingFailuresPostResponseBody"
example:
{
"processingFailureId": "afce35b2-1dff-4ace-98d0-4b9ac405c87d",
}
/transactionitems/{transactionItemId}/transactionaudittrails: /transactionitems/{transactionItemId}/transactionaudittrails:
parameters: parameters:
- in: path - in: path
@ -482,45 +453,7 @@ paths:
content: content:
application/json: application/json:
schema: schema:
$ref: "#/components/schemas/unavailable" $ref: "#/components/schemas/ProcessingFailuresGetResponseBody"
example:
{
"processingFailures":
[
{
"processingFailureId": "37a8095b-19db-498f-9349-5f37d21c5bdf",
"transactionItemId": "000dd413-2d19-47c0-a9db-9efbb6bc39a2",
"department": "900",
"costCenter": "84955",
"costType": "619031",
"documentDate": "2022-01-01",
"documentCode": "VERK_FACTUUR",
"accountingPeriod": "2024/10",
"transactionDescription": "Dagkaart",
"contraAccountNumber": "220.10419",
"status": "open",
"occurence": 1,
"processingFailureInstances":
[
{
"processingFailureInstanceId": "9afa9a6b-5b6a-4b0a-9c9e-4b0a5b6a4b0a",
"processingFailureId": "c93a5b6a-5b6a-4b0a-9c9e-4b0a5b6a4b0a",
"timestamp": "2022-01-01 00:00:00",
"failureReason":
{
"failureReasonId": 12,
"reasonCode": "1234ABCD",
"reasonDesc": "description",
},
"element": "costCenter",
"occurence": 1,
"change": "Adapt config",
},
],
},
],
"href": null,
}
/processingfailures/{processingFailureId}: /processingfailures/{processingFailureId}:
parameters: parameters:
- in: path - in: path
@ -540,19 +473,14 @@ paths:
content: content:
application/json: application/json:
schema: schema:
$ref: "#/components/schemas/unavailable" $ref: "#/components/schemas/ProcessingFailuresPatchRequestBody"
example: { "status": "open", "occurence": 2 }
responses: responses:
"200": "200":
description: OK description: OK
content: content:
application/json: application/json:
schema: schema:
$ref: "#/components/schemas/unavailable" $ref: "#/components/schemas/ProcessingFailuresPatchResponseBody"
example:
{
"processingFailureId": "37a8095b-19db-498f-9349-5f37d21c5bdf",
}
/processingfailures/{processingFailureId}/processingfailureinstances: /processingfailures/{processingFailureId}/processingfailureinstances:
parameters: parameters:
- in: path - in: path
@ -572,26 +500,14 @@ paths:
content: content:
application/json: application/json:
schema: schema:
$ref: "#/components/schemas/unavailable" $ref: "#/components/schemas/ProcessingFailureInstancesPostRequestBody"
example:
{
"timestamp": "2022-01-01 00:00:00",
"failureReasonId": 12,
"element": "costCenter",
"occurence": 1,
"change": "Adapt config",
}
responses: responses:
"201": "201":
description: Created description: Created
content: content:
application/json: application/json:
schema: schema:
$ref: "#/components/schemas/unavailable" $ref: "#/components/schemas/ProcessingFailureInstancesPostResponseBody"
example:
{
"processingFailureInstanceId": "9afa9a6b-5b6a-4b0a-9c9e-4b0a5b6a4b0a",
}
/processingfailureinstances/{processingFailureInstanceId}: /processingfailureinstances/{processingFailureInstanceId}:
parameters: parameters:
- in: path - in: path
@ -611,24 +527,14 @@ paths:
content: content:
application/json: application/json:
schema: schema:
$ref: "#/components/schemas/unavailable" $ref: "#/components/schemas/ProcessingFailureInstancesPatchRequestBody"
example:
{
"timestamp": "2022-01-01 00:00:00",
"occurence": 2,
"change": "Adapt config",
}
responses: responses:
"200": "200":
description: OK description: OK
content: content:
application/json: application/json:
schema: schema:
$ref: "#/components/schemas/unavailable" $ref: "#/components/schemas/ProcessingFailureInstancesPatchResponseBody"
example:
{
"processingFailureInstanceId": "37a8095b-19db-498f-9349-5f37d21c5bdf",
}
/productmetadata: /productmetadata:
get: get:
summary: Find product metadata. summary: Find product metadata.
@ -2064,60 +1970,60 @@ components:
TransactionItemsGetResponseBody: TransactionItemsGetResponseBody:
type: object type: object
properties: properties:
transactionItems: transactionItems:
type: "array" type: array
items: items:
type: object type: object
properties: properties:
transactionItemId: transactionItemId:
type: string type: string
example: afce35b2-1dff-4ace-98d0-4b9ac405c87d example: afce35b2-1dff-4ace-98d0-4b9ac405c87d
sourceName: sourceName:
type: string type: string
example: Verkoopengine example: Verkoopengine
transactionId: transactionId:
type: string type: string
example: 1001236 example: 1001236
transactionLineId: transactionLineId:
type: string type: string
nullable: true nullable: true
example: 1 example: 1
name: name:
type: string type: string
example: HTM Maandkorting 20% example: HTM Maandkorting 20%
quantity: quantity:
type: integer type: integer
example: 1 example: 1
taxCode: taxCode:
type: string type: string
example: V21 example: V21
amountExclTax: amountExclTax:
type: number type: integer
example: 100 example: 100
amountInclTax: amountInclTax:
type: number type: integer
example: 121 example: 121
amountTax: amountTax:
type: number type: integer
example: 21 example: 21
occurredOn: occurredOn:
type: string type: string
format: date-time format: date-time
example: 2024-10-04T00:00:00Z example: 2024-10-04T00:00:00Z
type: type:
type: string type: string
enum: enum:
- debit - debit
- credit - credit
example: debit example: debit
productCode: productCode:
type: string type: string
example: HTM-MND-20 example: HTM-MND-20
aggregationReference: aggregationReference:
type: string type: string
nullable: true nullable: true
example: FIKO-123456 example: FIKO-123456
accountingSystemReference: accountingSystemReference:
type: string type: string
nullable: true nullable: true
example: U4F-123456 example: U4F-123456
@ -2142,45 +2048,45 @@ components:
TransactionItemsPostRequestBody: TransactionItemsPostRequestBody:
type: object type: object
properties: properties:
sourceName: sourceName:
type: string type: string
example: Verkoopengine example: Verkoopengine
transactionId: transactionId:
type: string type: string
example: 1001236 example: 1001236
transactionLineId: transactionLineId:
type: string type: string
nullable: true nullable: true
example: 1 example: 1
name: name:
type: string type: string
example: HTM Maandkorting 20% example: HTM Maandkorting 20%
quantity: quantity:
type: integer type: integer
example: 1 example: 1
taxCode: taxCode:
type: string type: string
example: V21 example: V21
amountExclTax: amountExclTax:
type: integer type: integer
example: 100 example: 100
amountInclTax: amountInclTax:
type: integer type: integer
example: 121 example: 121
amountTax: amountTax:
type: integer type: integer
example: 21 example: 21
occurredOn: occurredOn:
type: string type: string
format: date-time format: date-time
example: 2024-10-04T00:00:00Z example: 2024-10-04T00:00:00Z
type: type:
type: string type: string
enum: enum:
- debit - debit
- credit - credit
example: debit example: debit
productCode: productCode:
type: string type: string
example: HTM-MND-20 example: HTM-MND-20
required: required:
@ -2211,45 +2117,45 @@ components:
items: items:
type: object type: object
properties: properties:
sourceName: sourceName:
type: string type: string
example: Verkoopengine example: Verkoopengine
transactionId: transactionId:
type: string type: string
example: 1001236 example: 1001236
transactionLineId: transactionLineId:
type: string type: string
nullable: true nullable: true
example: 1 example: 1
name: name:
type: string type: string
example: HTM Maandkorting 20% example: HTM Maandkorting 20%
quantity: quantity:
type: integer type: integer
example: 1 example: 1
taxCode: taxCode:
type: string type: string
example: V21 example: V21
amountExclTax: amountExclTax:
type: integer type: integer
example: 100 example: 100
amountInclTax: amountInclTax:
type: integer type: integer
example: 121 example: 121
amountTax: amountTax:
type: integer type: integer
example: 21 example: 21
occurredOn: occurredOn:
type: string type: string
format: date-time format: date-time
example: 2024-10-04T00:00:00Z example: 2024-10-04T00:00:00Z
type: type:
type: string type: string
enum: enum:
- debit - debit
- credit - credit
example: debit example: debit
productCode: productCode:
type: string type: string
example: HTM-MND-20 example: HTM-MND-20
required: required:
@ -2293,6 +2199,270 @@ components:
example: afce35b2-1dff-4ace-98d0-4b9ac405c87d example: afce35b2-1dff-4ace-98d0-4b9ac405c87d
required: required:
- transactionItemId - transactionItemId
ProcessingFailuresPostRequestBody:
type: object
properties:
department:
type: string
nullable: true
example: 900
costCenter:
type: string
nullable: true
example: 84955
costType:
type: string
nullable: true
example: 619031
documentDate:
type: string
format: date
nullable: true
example: 2022-01-01
documentCode:
type: string
nullable: true
example: VERK_FACTUUR
accountingPeriod:
type: string
nullable: true
example: 2024/10
transactionDescription:
type: string
nullable: true
example: Dagkaart
contraAccountNumber:
type: string
nullable: true
example: 220.10419
status:
type: string
enum:
- open
- returned to trx-db
- returned to src
example: open
occurence:
type: integer
example: 1
processingFailureInstances:
type: array
items:
$ref: "#/components/schemas/ProcessingFailureInstancesPostRequestBody"
required:
- status
- occurence
- processingFailureInstances
ProcessingFailuresPostResponseBody:
type: object
properties:
processingFailureId:
type: string
format: uuid
example: 37a8095b-19db-498f-9349-5f37d21c5bdf
required:
- processingFailureId
ProcessingFailuresGetResponseBody:
type: object
properties:
processingFailures:
type: array
items:
type: object
properties:
processingFailureId:
type: string
format: uuid
example: 37a8095b-19db-498f-9349-5f37d21c5bdf
transactionItemId:
type: string
format: uuid
example: 2d77d978-7141-499a-84ad-93fad8ee03ce
department:
type: string
nullable: true
example: 900
costCenter:
type: string
nullable: true
example: 84955
costType:
type: string
nullable: true
example: 619031
documentDate:
type: string
format: date
nullable: true
example: 2022-01-01
documentCode:
type: string
nullable: true
example: VERK_FACTUUR
accountingPeriod:
type: string
nullable: true
example: 2024/10
transactionDescription:
type: string
nullable: true
example: Dagkaart
contraAccountNumber:
type: string
nullable: true
example: 220.10419
status:
type: string
enum:
- open
- returned to trx-db
- returned to src
example: open
occurence:
type: integer
example: 1
processingFailureInstances:
type: array
items:
type: object
properties:
processingFailureInstanceId:
type: string
format: uuid
example: 9afa9a6b-5b6a-4b0a-9c9e-4b0a5b6a4b0a
timestamp:
type: string
format: date-time
example: 2022-01-01 00:00:00
failureReason:
type: object
properties:
failureReasonId:
type: integer
example: 1
reasonCode:
type: string
example: 002
reasonDesc:
type: string
example: Contra account does not exist
required:
- failureReasonId
- reasonCode
- reasonDesc
element:
type: string
example: costCenter
occurence:
type: integer
example: 1
change:
type: string
nullable: true
example: Adapt config
required:
- processingFailureInstanceId
- timestamp
- failureReason
- element
- occurence
required:
- processingFailureId
- transactionItemId
- status
- occurence
- processingFailureInstances
href:
type: string
nullable: true
description: URI for pagination.
example: null
ProcessingFailuresPatchRequestBody:
type: object
properties:
status:
type: string
enum:
- open
- returned to trx-db
- returned to src
nullable: true
example: returned to trx-db
occurence:
type: integer
nullable: true
example: 2
ProcessingFailuresPatchResponseBody:
type: object
properties:
processingFailureId:
type: string
format: uuid
nullable: false
example: 37a8095b-19db-498f-9349-5f37d21c5bdf
required:
- processingFailureId
ProcessingFailureInstancesPostRequestBody:
type: object
properties:
timestamp:
type: string
format: date-time
example: 2022-01-01 00:00:00
failureReasonId:
type: integer
example: 1
element:
type: string
example: costCenter
occurence:
type: integer
example: 1
change:
type: string
nullable: true
example: Adapt config
required:
- timestamp
- failureReason
- element
- occurence
ProcessingFailureInstancesPostResponseBody:
type: object
properties:
processingFailureInstanceId:
type: string
format: uuid
nullable: false
example: 37a8095b-19db-498f-9349-5f37d21c5bdf
required:
- processingFailureInstanceId
ProcessingFailureInstancesPatchRequestBody:
type: object
properties:
timestamp:
type: string
format: date-time
nullable: true
example: 2022-01-01 00:00:00
occurence:
type: integer
nullable: true
example: 1
change:
type: string
nullable: true
example: Adapt config
ProcessingFailureInstancesPatchResponseBody:
type: object
properties:
processingFailureInstanceId:
type: string
format: uuid
nullable: false
example: 37a8095b-19db-498f-9349-5f37d21c5bdf
required:
- processingFailureInstanceId
rfc9457: rfc9457:
type: object type: object
properties: properties: