{
  "info": {
    "_postman_id": "05004c22-0698-4291-8adc-e78285f6e593",
    "name": "IDPay - Card Not Present Verification",
    "description": "Public REST API for Unico IDPay's Card Not Present Verification product: payment transactions, chargeback, and credit card onboarding (walletid). This collection covers only the endpoints currently documented on this site. If you were pointed here for an endpoint you don't see in the collection, reach out to your Unico contact.",
    "schema": "https://schema.getpostman.com/json/collection/v2.1.0/collection.json"
  },
  "variable": [
    {
      "key": "base_path",
      "value": "https://transactions.transactional.uat.unico.app/api/public/v1",
      "type": "string",
      "description": "UAT by default. For production use https://transactions.transactional.unico.app/api/public/v1"
    },
    {
      "key": "access_token",
      "value": "",
      "type": "string",
      "description": "OAuth2 access token obtained via the service-account flow described in Authentication."
    },
    {
      "key": "transaction_id",
      "value": "",
      "type": "string"
    },
    {
      "key": "chargeback_id",
      "value": "",
      "type": "string"
    }
  ],
  "item": [
    {
      "name": "Payment transactions",
      "item": [
        {
          "name": "Create Transaction",
          "request": {
            "method": "POST",
            "header": [
              {
                "key": "Authorization",
                "value": "Bearer {{access_token}}",
                "type": "text"
              },
              {
                "key": "Content-Type",
                "value": "application/json",
                "type": "text"
              }
            ],
            "url": {
              "raw": "{{base_path}}/credit/transaction",
              "host": [
                "{{base_path}}"
              ],
              "path": [
                "credit",
                "transaction"
              ]
            },
            "body": {
              "mode": "raw",
              "raw": "{\n  \"identity\": {\n    \"key\": \"cpf\",\n    \"value\": \"12345678900\"\n  },\n  \"orderNumber\": \"order-98765\",\n  \"company\": \"company-id\",\n  \"redirectUrl\": \"https://yourapp.com/checkout/return\",\n  \"card\": {\n    \"binDigits\": \"12345678\",\n    \"lastDigits\": \"1234\",\n    \"expirationDate\": \"12/2028\",\n    \"name\": \"John Doe\"\n  },\n  \"value\": 199.9,\n  \"mainContacts\": [\n    {\n      \"key\": \"phone\",\n      \"value\": \"5543999999999\"\n    }\n  ]\n}",
              "options": {
                "raw": {
                  "language": "json"
                }
              }
            }
          },
          "response": []
        },
        {
          "name": "Get Transaction Status",
          "request": {
            "method": "GET",
            "header": [
              {
                "key": "Authorization",
                "value": "Bearer {{access_token}}",
                "type": "text"
              }
            ],
            "url": {
              "raw": "{{base_path}}/credit/transactions/{{transaction_id}}",
              "host": [
                "{{base_path}}"
              ],
              "path": [
                "credit",
                "transactions",
                "{{transaction_id}}"
              ]
            }
          },
          "response": []
        },
        {
          "name": "Get Transaction Evidence Set",
          "request": {
            "method": "GET",
            "header": [
              {
                "key": "Authorization",
                "value": "Bearer {{access_token}}",
                "type": "text"
              }
            ],
            "url": {
              "raw": "{{base_path}}/credit/transactions/{{transaction_id}}/probative",
              "host": [
                "{{base_path}}"
              ],
              "path": [
                "credit",
                "transactions",
                "{{transaction_id}}",
                "probative"
              ]
            },
            "description": "The link returned for the evidence set is valid for five minutes."
          },
          "response": []
        },
        {
          "name": "Resend Transaction Notification",
          "request": {
            "method": "POST",
            "header": [
              {
                "key": "Authorization",
                "value": "Bearer {{access_token}}",
                "type": "text"
              },
              {
                "key": "Content-Type",
                "value": "application/json",
                "type": "text"
              }
            ],
            "url": {
              "raw": "{{base_path}}/credit/transactions/{{transaction_id}}/notify",
              "host": [
                "{{base_path}}"
              ],
              "path": [
                "credit",
                "transactions",
                "{{transaction_id}}",
                "notify"
              ]
            },
            "body": {
              "mode": "raw",
              "raw": "{\n  \"phone\": \"NOTIFICATION_PHONE\",\n  \"email\": \"NOTIFICATION_EMAIL\"\n}",
              "options": {
                "raw": {
                  "language": "json"
                }
              }
            }
          },
          "response": []
        }
      ]
    },
    {
      "name": "Chargeback",
      "item": [
        {
          "name": "Request Chargeback Review",
          "request": {
            "method": "POST",
            "header": [
              {
                "key": "Authorization",
                "value": "Bearer {{access_token}}",
                "type": "text"
              },
              {
                "key": "Content-Type",
                "value": "application/json",
                "type": "text"
              }
            ],
            "url": {
              "raw": "{{base_path}}/credit/transactions/{{transaction_id}}/chargeback",
              "host": [
                "{{base_path}}"
              ],
              "path": [
                "credit",
                "transactions",
                "{{transaction_id}}",
                "chargeback"
              ]
            },
            "body": {
              "mode": "raw",
              "raw": "{\n  \"datetime\": \"2023-01-05T03:00:00.000Z\",\n  \"requestor\": {\n    \"key\": \"cpf\",\n    \"value\": \"USER_CPF\"\n  },\n  \"name\": \"USER_NAME\",\n  \"reason\": \"REQUEST_REASON\",\n  \"observation\": \"GENERAL_OBSERVATIONS\",\n  \"documents\": [\n    {\n      \"label\": \"FILE_NAME\",\n      \"data\": \"JVBERi0xLjQKMSAwI==\"\n    }\n  ]\n}",
              "options": {
                "raw": {
                  "language": "json"
                }
              }
            }
          },
          "response": []
        },
        {
          "name": "Get Chargeback Review Status",
          "request": {
            "method": "GET",
            "header": [
              {
                "key": "Authorization",
                "value": "Bearer {{access_token}}",
                "type": "text"
              }
            ],
            "url": {
              "raw": "{{base_path}}/credit/transactions/{{transaction_id}}/chargeback/{{chargeback_id}}",
              "host": [
                "{{base_path}}"
              ],
              "path": [
                "credit",
                "transactions",
                "{{transaction_id}}",
                "chargeback",
                "{{chargeback_id}}"
              ]
            }
          },
          "response": []
        }
      ]
    },
    {
      "name": "Credit card onboarding",
      "item": [
        {
          "name": "Validate Credit Card",
          "request": {
            "method": "POST",
            "header": [
              {
                "key": "Authorization",
                "value": "Bearer {{access_token}}",
                "type": "text"
              },
              {
                "key": "Content-Type",
                "value": "application/json",
                "type": "text"
              }
            ],
            "url": {
              "raw": "{{base_path}}/walletid/transaction",
              "host": [
                "{{base_path}}"
              ],
              "path": [
                "walletid",
                "transaction"
              ]
            },
            "description": "Can reuse biometric captures from other Unico IDCloud products via additionalInfo.processID (see docs).",
            "body": {
              "mode": "raw",
              "raw": "{\n  \"identity\": {\n    \"key\": \"cpf\",\n    \"value\": \"12345678900\"\n  },\n  \"orderNumber\": \"onboarding-98765\",\n  \"company\": \"company-id\",\n  \"redirectUrl\": \"https://yourapp.com/wallet/return\",\n  \"card\": {\n    \"binDigits\": \"12345678\",\n    \"lastDigits\": \"1234\",\n    \"expirationDate\": \"12/2028\",\n    \"name\": \"John Doe\"\n  },\n  \"value\": 5000.0\n}",
              "options": {
                "raw": {
                  "language": "json"
                }
              }
            }
          },
          "response": []
        },
        {
          "name": "Check Validation Status",
          "request": {
            "method": "GET",
            "header": [
              {
                "key": "Authorization",
                "value": "Bearer {{access_token}}",
                "type": "text"
              }
            ],
            "url": {
              "raw": "{{base_path}}/walletid/transactions/{{transaction_id}}",
              "host": [
                "{{base_path}}"
              ],
              "path": [
                "walletid",
                "transactions",
                "{{transaction_id}}"
              ]
            }
          },
          "response": []
        }
      ]
    }
  ]
}
