Skip to content

Commit

Permalink
cloned parameters from NewTransactionResponse
Browse files Browse the repository at this point in the history
  • Loading branch information
EmanueleBVtech committed Dec 10, 2024
1 parent 65bd872 commit 53222c4
Show file tree
Hide file tree
Showing 4 changed files with 356 additions and 96 deletions.
114 changes: 89 additions & 25 deletions src/domains/ecommerce-app/api/ecommerce-checkout/v2/_openapi.json.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -424,37 +424,101 @@
},
"TransactionInfo": {
"description": "Transaction data returned when querying for an existing transaction",
"allOf": [
{
"$ref": "#/components/schemas/NewTransactionResponse"
"type": "object",
"properties": {
"transactionId": {
"type": "string"
},
{
"type": "object",
"properties": {
"closePaymentResultError": {
"type": "object",
"description": "Error details for close payment result",
"properties": {
"statusCode": {
"type": "number"
"payments": {
"type": "array",
"items": {
"$ref": "#/components/schemas/PaymentInfo"
},
"minItems": 1,
"maxItems": 1,
"example": [
{
"rptId": "77777777777302012387654312384",
"paymentToken": "paymentToken1",
"reason": "reason1",
"amount": 600,
"transferList": [
{
"paFiscalCode": "77777777777",
"digitalStamp": false,
"transferCategory": "transferCategory1",
"transferAmount": 500
},
"description": {
"type": "string"
{
"paFiscalCode": "11111111111",
"digitalStamp": true,
"transferCategory": "transferCategory2",
"transferAmount": 100
}
}
},
"status": {
"$ref": "#/components/schemas/TransactionStatus"
},
"gatewayAuthorizationStatus": {
"type": "string",
"description": "Payment gateway authorization status"
]
}
},
"required": [
"status"
]
},
"status": {
"$ref": "#/components/schemas/TransactionStatus"
},
"feeTotal": {
"$ref": "#/components/schemas/AmountEuroCents"
},
"clientId": {
"description": "transaction client id",
"type": "string",
"enum": [
"IO"
]
},
"sendPaymentResultOutcome": {
"description": "The outcome of sendPaymentResult api (OK, KO, NOT_RECEIVED)",
"type": "string",
"enum": [
"OK",
"KO",
"NOT_RECEIVED"
]
},
"authorizationCode": {
"type": "string",
"description": "Payment gateway-specific authorization code related to the transaction"
},
"errorCode": {
"type": "string",
"description": "Payment gateway-specific error code from the gateway"
},
"gateway": {
"type": "string",
"pattern": "XPAY|VPOS|NPG|REDIRECT",
"description": "Pgs identifier"
},
"closePaymentResultError": {
"type": "object",
"description": "Error details for close payment result",
"properties": {
"statusCode": {
"type": "number"
},
"description": {
"type": "string"
}
}
},
"status": {
"$ref": "#/components/schemas/TransactionStatus"
},
"gatewayAuthorizationStatus": {
"type": "string",
"description": "Payment gateway authorization status"
}
},
"required": [
"status",
"transactionId",
"status",
"payments"
]
},
"ValidationFaultPaymentUnknownProblemJson": {
Expand Down
114 changes: 89 additions & 25 deletions src/domains/ecommerce-app/api/ecommerce-io/v2/_openapi.json.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -1712,37 +1712,101 @@
},
"TransactionInfo": {
"description": "Transaction data returned when querying for an existing transaction",
"allOf": [
{
"$ref": "#/components/schemas/NewTransactionResponse"
"type": "object",
"properties": {
"transactionId": {
"type": "string"
},
{
"type": "object",
"properties": {
"closePaymentResultError": {
"type": "object",
"description": "Error details for close payment result",
"properties": {
"statusCode": {
"type": "number"
"payments": {
"type": "array",
"items": {
"$ref": "#/components/schemas/PaymentInfo"
},
"minItems": 1,
"maxItems": 1,
"example": [
{
"rptId": "77777777777302012387654312384",
"paymentToken": "paymentToken1",
"reason": "reason1",
"amount": 600,
"transferList": [
{
"paFiscalCode": "77777777777",
"digitalStamp": false,
"transferCategory": "transferCategory1",
"transferAmount": 500
},
"description": {
"type": "string"
{
"paFiscalCode": "11111111111",
"digitalStamp": true,
"transferCategory": "transferCategory2",
"transferAmount": 100
}
}
},
"status": {
"$ref": "#/components/schemas/TransactionStatus"
},
"gatewayAuthorizationStatus": {
"type": "string",
"description": "payment gateway authorization status"
]
}
},
"required": [
"status"
]
},
"status": {
"$ref": "#/components/schemas/TransactionStatus"
},
"feeTotal": {
"$ref": "#/components/schemas/AmountEuroCents"
},
"clientId": {
"description": "transaction client id",
"type": "string",
"enum": [
"IO"
]
},
"sendPaymentResultOutcome": {
"description": "The outcome of sendPaymentResult api (OK, KO, NOT_RECEIVED)",
"type": "string",
"enum": [
"OK",
"KO",
"NOT_RECEIVED"
]
},
"authorizationCode": {
"type": "string",
"description": "Payment gateway-specific authorization code related to the transaction"
},
"errorCode": {
"type": "string",
"description": "Payment gateway-specific error code from the gateway"
},
"gateway": {
"type": "string",
"pattern": "XPAY|VPOS|NPG|REDIRECT",
"description": "Pgs identifier"
},
"closePaymentResultError": {
"type": "object",
"description": "Error details for close payment result",
"properties": {
"statusCode": {
"type": "number"
},
"description": {
"type": "string"
}
}
},
"status": {
"$ref": "#/components/schemas/TransactionStatus"
},
"gatewayAuthorizationStatus": {
"type": "string",
"description": "Payment gateway authorization status"
}
},
"required": [
"status",
"transactionId",
"status",
"payments"
]
},
"AmountEuroCents": {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -289,33 +289,101 @@
},
"TransactionInfo": {
"description": "Transaction data returned when querying for an existing transaction",
"allOf": [
{
"$ref": "#/components/schemas/NewTransactionResponse"
"type": "object",
"properties": {
"transactionId": {
"type": "string"
},
{
"type": "object",
"properties": {
"closePaymentResultError": {
"type": "object",
"description": "Error details for close payment result",
"properties": {
"statusCode": {
"type": "number"
"payments": {
"type": "array",
"items": {
"$ref": "#/components/schemas/PaymentInfo"
},
"minItems": 1,
"maxItems": 1,
"example": [
{
"rptId": "77777777777302012387654312384",
"paymentToken": "paymentToken1",
"reason": "reason1",
"amount": 600,
"transferList": [
{
"paFiscalCode": "77777777777",
"digitalStamp": false,
"transferCategory": "transferCategory1",
"transferAmount": 500
},
"description": {
"type": "string"
{
"paFiscalCode": "11111111111",
"digitalStamp": true,
"transferCategory": "transferCategory2",
"transferAmount": 100
}
}
},
"feeTotal": {
"$ref": "#/components/schemas/AmountEuroCents"
]
}
},
"required": [
"status"
]
},
"status": {
"$ref": "#/components/schemas/TransactionStatus"
},
"feeTotal": {
"$ref": "#/components/schemas/AmountEuroCents"
},
"clientId": {
"description": "transaction client id",
"type": "string",
"enum": [
"IO"
]
},
"sendPaymentResultOutcome": {
"description": "The outcome of sendPaymentResult api (OK, KO, NOT_RECEIVED)",
"type": "string",
"enum": [
"OK",
"KO",
"NOT_RECEIVED"
]
},
"authorizationCode": {
"type": "string",
"description": "Payment gateway-specific authorization code related to the transaction"
},
"errorCode": {
"type": "string",
"description": "Payment gateway-specific error code from the gateway"
},
"gateway": {
"type": "string",
"pattern": "XPAY|VPOS|NPG|REDIRECT",
"description": "Pgs identifier"
},
"closePaymentResultError": {
"type": "object",
"description": "Error details for close payment result",
"properties": {
"statusCode": {
"type": "number"
},
"description": {
"type": "string"
}
}
},
"status": {
"$ref": "#/components/schemas/TransactionStatus"
},
"gatewayAuthorizationStatus": {
"type": "string",
"description": "Payment gateway authorization status"
}
},
"required": [
"status",
"transactionId",
"status",
"payments"
]
},
"NewTransactionRequest": {
Expand Down
Loading

0 comments on commit 53222c4

Please sign in to comment.