{
  "info": {
    "_postman_id": "a99fca1b-ae46-43d5-b91b-1b77b26a7c88",
    "name": "Tilt Pay - Client pack (local)",
    "description": "### Introduction\nSend transfers and collect payments through the Tilt platform by using the Tilt Pay API.\n\nThe Tilt Pay API is based on REST with resource-oriented URLs. It accepts form-encoded request bodies and returns JSON-encoded responses with standard HTTP response codes.\n\nContact Support:\n Name: Tilt",
    "schema": "https://schema.getpostman.com/json/collection/v2.1.0/collection.json",
    "_exporter_id": "4891901"
  },
  "item": [
    {
      "name": "Authorization",
      "item": [
        {
          "name": "Get token",
          "event": [
            {
              "listen": "test",
              "script": {
                "exec": [
                  "pm.test(\"Status code is 200\", function () {",
                  "    pm.response.to.have.status(200);",
                  "});",
                  "pm.test(\"Got bearer access_token\", function () {",
                  "    var jsonData = pm.response.json();",
                  "    pm.expect(jsonData.access_token).to.not.be.empty;",
                  "    pm.expect(jsonData.token_type).to.eql('Bearer');",
                  "});",
                  "",
                  "var jsonData = JSON.parse(responseBody);",
                  "postman.setEnvironmentVariable(\"bearerToken\", jsonData.access_token);"
                ],
                "type": "text/javascript"
              }
            }
          ],
          "request": {
            "auth": {
              "type": "noauth"
            },
            "method": "POST",
            "header": [
              {
                "key": "Content-Type",
                "value": "application/json"
              }
            ],
            "body": {
              "mode": "raw",
              "raw": "{\n    \"username\": \"{{username}}\",\n    \"password\": \"{{password}}\",\n    \"audience\": \"{{audience}}\",\n    \"grant_type\": \"password\",\n    \"client_id\": \"{{client_id}}\"\n}"
            },
            "url": {
              "raw": "{{baseAuthUrl}}/oauth/token",
              "host": [
                "{{baseAuthUrl}}"
              ],
              "path": [
                "oauth",
                "token"
              ]
            },
            "description": "Use your username and password to obtain an access token which you need to use to authenticate your account when using the API."
          },
          "response": []
        }
      ]
    },
    {
      "name": "Resources",
      "item": [
        {
          "name": "List institutions",
          "event": [
            {
              "listen": "test",
              "script": {
                "exec": [
                  "pm.test(\"Status code is 200\", function () {",
                  "    pm.response.to.have.status(200);",
                  "});",
                  "var jsonData = pm.response.json();",
                  "pm.test(\"Institutions returned correctly\", function () {",
                  "    pm.expect(jsonData.data).to.be.an(\"array\");",
                  "});",
                  "pm.test(\"Tilt institution present\", function () {",
                  "    const iname = pm.environment.get(\"account_institution\");",
                  "    const i = jsonData.data.find(m => m.id === iname);",
                  "    pm.expect(i).to.be.an(\"object\", iname + \" institution not found in array\");",
                  "});"
                ],
                "type": "text/javascript",
                "packages": {}
              }
            }
          ],
          "request": {
            "method": "GET",
            "header": [],
            "url": {
              "raw": "{{baseUrl}}/v1/resources/institutions/{{country}}?list=true",
              "host": [
                "{{baseUrl}}"
              ],
              "path": [
                "v1",
                "resources",
                "institutions",
                "{{country}}"
              ],
              "query": [
                {
                  "key": "list",
                  "value": "true"
                }
              ]
            },
            "description": "List available institutions for a country. Required for account verification and creating transfers."
          },
          "response": []
        },
        {
          "name": "Fetch institution",
          "event": [
            {
              "listen": "test",
              "script": {
                "exec": [
                  "pm.test(\"Status code is 200\", function () {",
                  "    pm.response.to.have.status(200);",
                  "});",
                  "var jsonData = pm.response.json();",
                  "pm.test(\"Institutions returned correctly\", function () {",
                  "    pm.expect(jsonData.data).to.be.an(\"array\");",
                  "});",
                  "pm.test(\"Tilt institution present\", function () {",
                  "    const iname = pm.environment.get(\"account_institution\");",
                  "    const i = jsonData.data.find(m => m.id === iname);",
                  "    pm.expect(i).to.be.an(\"object\", iname + \" institution not found in array\");",
                  "});"
                ],
                "type": "text/javascript",
                "packages": {},
                "requests": {}
              }
            }
          ],
          "request": {
            "method": "GET",
            "header": [],
            "url": {
              "raw": "{{baseUrl}}/v1/resources/institutions/:institution",
              "host": [
                "{{baseUrl}}"
              ],
              "path": [
                "v1",
                "resources",
                "institutions",
                ":institution"
              ],
              "variable": [
                {
                  "key": "institution",
                  "value": "zw_bancabc"
                }
              ]
            },
            "description": "List available institutions for a country. Required for account verification and creating transfers."
          },
          "response": []
        },
        {
          "name": "List institutions (banks)",
          "event": [
            {
              "listen": "test",
              "script": {
                "exec": [
                  "pm.test(\"Status code is 200\", function () {",
                  "    pm.response.to.have.status(200);",
                  "});",
                  "var jsonData = pm.response.json();",
                  "pm.test(\"Institutions returned correctly\", function () {",
                  "    pm.expect(jsonData.data).to.be.an(\"array\");",
                  "});"
                ],
                "type": "text/javascript",
                "packages": {},
                "requests": {}
              }
            }
          ],
          "request": {
            "method": "GET",
            "header": [],
            "url": {
              "raw": "{{baseUrl}}/v1/resources/institutions/:country/?tag=bank&list=true",
              "host": [
                "{{baseUrl}}"
              ],
              "path": [
                "v1",
                "resources",
                "institutions",
                ":country",
                ""
              ],
              "query": [
                {
                  "key": "tag",
                  "value": "bank"
                },
                {
                  "key": "list",
                  "value": "true"
                }
              ],
              "variable": [
                {
                  "key": "country",
                  "value": "{{country}}"
                }
              ]
            },
            "description": "List available institutions for a country. Required for account verification and creating transfers."
          },
          "response": []
        },
        {
          "name": "List institutions (mobile money)",
          "event": [
            {
              "listen": "test",
              "script": {
                "exec": [
                  "pm.test(\"Status code is 200\", function () {",
                  "    pm.response.to.have.status(200);",
                  "});",
                  "var jsonData = pm.response.json();",
                  "pm.test(\"Institutions returned correctly\", function () {",
                  "    pm.expect(jsonData.data).to.be.an(\"array\");",
                  "});"
                ],
                "type": "text/javascript",
                "packages": {},
                "requests": {}
              }
            }
          ],
          "request": {
            "method": "GET",
            "header": [],
            "url": {
              "raw": "{{baseUrl}}/v1/resources/institutions/:country/?tags=mobile_money&list=true",
              "host": [
                "{{baseUrl}}"
              ],
              "path": [
                "v1",
                "resources",
                "institutions",
                ":country",
                ""
              ],
              "query": [
                {
                  "key": "tags",
                  "value": "mobile_money"
                },
                {
                  "key": "list",
                  "value": "true"
                }
              ],
              "variable": [
                {
                  "key": "country",
                  "value": "{{country}}"
                }
              ]
            },
            "description": "List available institutions for a country. Required for account verification and creating transfers."
          },
          "response": []
        }
      ]
    },
    {
      "name": "Your account",
      "item": [
        {
          "name": "Fetch account balance",
          "event": [
            {
              "listen": "test",
              "script": {
                "exec": [
                  "var jsonData = pm.response.json();",
                  "pm.test(\"Status code is 200\", function () {",
                  "    pm.response.to.have.status(200);",
                  "    pm.expect(jsonData.responseMessage).to.eql(\"Fetched account balance\");",
                  "});",
                  "pm.test(\"Balance returned\", function () {",
                  "    pm.expect(jsonData.data.balance).to.be.an(\"number\");",
                  "    pm.expect(jsonData.data.currency).to.be.an(\"string\");",
                  "});"
                ],
                "type": "text/javascript"
              }
            }
          ],
          "request": {
            "method": "GET",
            "header": [],
            "url": {
              "raw": "{{baseUrl}}/v1/accounts/:institution/:account_number/balance",
              "host": [
                "{{baseUrl}}"
              ],
              "path": [
                "v1",
                "accounts",
                ":institution",
                ":account_number",
                "balance"
              ],
              "variable": [
                {
                  "key": "institution",
                  "value": "{{account_institution}}",
                  "description": "(Required) "
                },
                {
                  "key": "account_number",
                  "value": "{{account_number}}"
                }
              ]
            },
            "description": "Gets the real-time balance of an account that the requesting client has permission to view."
          },
          "response": []
        },
        {
          "name": "List transactions",
          "event": [
            {
              "listen": "test",
              "script": {
                "exec": [
                  "pm.test(\"Status code is 200\", function () {",
                  "    pm.response.to.have.status(200);",
                  "});",
                  "var jsonData = pm.response.json();",
                  "pm.test(\"Transactions should be an array\", function () {",
                  "    pm.expect(jsonData.data.count).to.be.an(\"number\");",
                  "    pm.expect(jsonData.data.transactions).to.be.an(\"array\");",
                  "});"
                ],
                "type": "text/javascript"
              }
            }
          ],
          "protocolProfileBehavior": {
            "disabledSystemHeaders": {
              "accept": true
            }
          },
          "request": {
            "method": "GET",
            "header": [
              {
                "key": "Accept",
                "value": "application/json",
                "description": "Request a specific content-type for the response"
              }
            ],
            "url": {
              "raw": "{{baseUrl}}/v1/accounts/:institution/:account_number/transactions",
              "host": [
                "{{baseUrl}}"
              ],
              "path": [
                "v1",
                "accounts",
                ":institution",
                ":account_number",
                "transactions"
              ],
              "query": [
                {
                  "key": "to_datetime",
                  "value": "2021-03-09T08:00:00+0000",
                  "disabled": true
                },
                {
                  "key": "from_datetime",
                  "value": "2022-05-30T14:50:00+0000",
                  "disabled": true
                }
              ],
              "variable": [
                {
                  "key": "institution",
                  "value": "{{account_institution}}"
                },
                {
                  "key": "account_number",
                  "value": "{{account_number}}"
                }
              ]
            },
            "description": "The transactions resource can be used to retrieve transaction data for an account that the requesting client has permission to view.\n\nTransaction data is available up to 90 days, after which historical data will need to be requested from your account manager.\n\nOpening and closing balances are calculated nightly and are not available for transactions on the current day.\n\nUse the Accept header to specify the response format, such as `text/csv`."
          },
          "response": []
        },
        {
          "name": "List available statements",
          "event": [
            {
              "listen": "test",
              "script": {
                "exec": [
                  "pm.test(\"Status code is 200\", function () {",
                  "    pm.response.to.have.status(200);",
                  "});",
                  "var jsonData = pm.response.json();",
                  "pm.test(\"Statements returned\", function () {",
                  "    pm.expect(jsonData.data).to.be.an(\"array\");",
                  "    pm.expect(jsonData.data[0].statement_id).to.not.be.empty;",
                  "    pm.expect(jsonData.data[0].opening_balance).to.be.a('number')",
                  "    pm.expect(jsonData.data[0].closing_balance).to.be.a('number')",
                  "    pm.expect(jsonData.data[0].transactions_count).to.be.a('number');",
                  "});",
                  "pm.test(\"A statement is present\", function () {",
                  "    pm.expect(jsonData.data).to.be.an(\"array\");",
                  "    pm.expect(jsonData.data[0].statement_id).to.not.be.empty;",
                  "    pm.expect(jsonData.data[0].opening_balance).to.be.a('number')",
                  "    pm.expect(jsonData.data[0].closing_balance).to.be.a('number')",
                  "    pm.expect(jsonData.data[0].transactions_count).to.be.a('number');",
                  "});",
                  "",
                  "pm.collectionVariables.set(\"__statement_id\", pm.response.json().data[0].statement_id);"
                ],
                "type": "text/javascript"
              }
            }
          ],
          "request": {
            "method": "GET",
            "header": [],
            "url": {
              "raw": "{{baseUrl}}/v1/accounts/:institution/:account_number/statements",
              "host": [
                "{{baseUrl}}"
              ],
              "path": [
                "v1",
                "accounts",
                ":institution",
                ":account_number",
                "statements"
              ],
              "query": [
                {
                  "key": "from_datetime",
                  "value": "2022-05-01T00:00:00",
                  "description": "Specifies start date and time for filtering of the statements. If this is not populated, the start date will be open ended",
                  "disabled": true
                },
                {
                  "key": "to_datetime",
                  "value": "2022-025-07T13:00:00Z",
                  "description": "Specifies end date and time for filtering of the statement. If this is not populated, the end date will be open ended",
                  "disabled": true
                },
                {
                  "key": "search",
                  "value": "weekly",
                  "type": "text",
                  "disabled": true
                }
              ],
              "variable": [
                {
                  "key": "institution",
                  "value": "{{account_institution}}"
                },
                {
                  "key": "account_number",
                  "value": "{{account_number}}"
                }
              ]
            },
            "description": "The statements resource can be used to retrieve a list of available statements for an account that the requesting client has permission to view.\n\nStatement transaction data can then be fetched from the referenced link as it will not be included when listing statements."
          },
          "response": []
        },
        {
          "name": "Fetch an account statement",
          "event": [
            {
              "listen": "test",
              "script": {
                "exec": [
                  "pm.test(\"Status code is 200\", function () {",
                  "    pm.response.to.have.status(200);",
                  "    pm.expect(pm.response.json().responseMessage).to.eql('Fetched statement');",
                  "});",
                  "pm.test(\"A statement is present\", function () {",
                  "    var jsonData = pm.response.json();",
                  "    pm.expect(jsonData.data).to.be.an(\"object\");",
                  "    pm.expect(jsonData.data.statement_id).to.eql(pm.collectionVariables.get('__statement_id'));",
                  "    pm.expect(jsonData.data.account).to.eql(pm.environment.get('account_number'));",
                  "    pm.expect(jsonData.data.institution).to.eql(pm.environment.get('account_institution'));",
                  "    pm.expect(jsonData.data.opening_balance).to.be.a('number');",
                  "    pm.expect(jsonData.data.closing_balance).to.be.a('number');",
                  "    pm.expect(jsonData.data.transactions_count).to.be.a('number');",
                  "    pm.expect(jsonData.data.transactions).to.be.an(\"array\");",
                  "});"
                ],
                "type": "text/javascript"
              }
            }
          ],
          "protocolProfileBehavior": {
            "disabledSystemHeaders": {
              "accept": true
            }
          },
          "request": {
            "method": "GET",
            "header": [
              {
                "key": "Accept",
                "value": "text/csv",
                "disabled": true
              }
            ],
            "url": {
              "raw": "{{baseUrl}}/v1/accounts/:institution/:account_number/statements/:statement_id",
              "host": [
                "{{baseUrl}}"
              ],
              "path": [
                "v1",
                "accounts",
                ":institution",
                ":account_number",
                "statements",
                ":statement_id"
              ],
              "variable": [
                {
                  "key": "institution",
                  "value": "{{account_institution}}",
                  "description": "(Required) "
                },
                {
                  "key": "account_number",
                  "value": "{{account_number}}",
                  "description": "(Required) "
                },
                {
                  "key": "statement_id",
                  "value": "{{__statement_id}}"
                }
              ]
            },
            "description": "The statements resource can be used to retrieve a specific statement if the requesting client has permission to view the related account.\n\nStatement transaction data will be included in the response if available or a link will be provided to an archived statement where available.\n\nTransaction data is generally available for 90 days before being archived.\n\nUse the Accept header to specify the response format, such as `text/csv`."
          },
          "response": []
        },
        {
          "name": "Account Withdrawal",
          "event": [
            {
              "listen": "test",
              "script": {
                "exec": [
                  "pm.test(\"Successful POST request\", function () {",
                  "    pm.expect(pm.response.code).to.be.oneOf([200, 201]);",
                  "});",
                  "pm.test(\"Transfer returned and correct\", function () {",
                  "    var jsonData = pm.response.json();",
                  "    pm.expect(jsonData.data.transfer_id).to.not.be.empty;",
                  "    pm.expect(jsonData.data.status).to.equal('SUCCESSFUL');",
                  "    //pm.expect(jsonData.responseMessage).to.equal('Transfer successful');",
                  "    pm.expect(jsonData.data.external_transaction_id).to.eql(pm.collectionVariables.get('__external_transaction_id'));",
                  "    pm.expect(jsonData.data.instruction.debtor).to.not.be.empty;",
                  "    pm.expect(jsonData.data.instruction.creditor).to.not.be.empty;",
                  "    pm.expect(jsonData.data.actions).to.not.be.empty;",
                  "});",
                  "pm.test(\"Actions returned correctly\", function () {",
                  "    var jsonData = pm.response.json();",
                  "    pm.expect(jsonData.data.actions).to.be.an(\"array\");",
                  "    const action = jsonData.data.actions.find(m => m.status === 'SUCCESSFUL');",
                  "    pm.expect(action).to.be.an(\"object\", \"SUCCESSFUL action not found\");",
                  "    pm.expect(action._meta.cause).to.not.be.empty;",
                  "    pm.expect(action._meta.trace_api_log_id).to.not.be.empty;",
                  "    //pm.expect(action._meta.financial_transaction_log_id).to.not.be.empty;",
                  "});",
                  ""
                ],
                "type": "text/javascript"
              }
            },
            {
              "listen": "prerequest",
              "script": {
                "exec": [
                  "pm.collectionVariables.set(\"__external_transaction_id\", require('uuid').v4());"
                ],
                "type": "text/javascript"
              }
            }
          ],
          "request": {
            "method": "POST",
            "header": [
              {
                "key": "Content-Type",
                "value": "application/json"
              },
              {
                "key": "Content-Type",
                "value": "application/json",
                "disabled": true
              }
            ],
            "body": {
              "mode": "raw",
              "raw": "{\n    \"instruction\": {\n        \"external_transaction_id\": \"{{__external_transaction_id}}\",\n        \"amount\": 100,\n        \"narration\": \"Send to bank test\",\n        \"notifications\": [\n            {\n                \"on_status\": [\n                    \"ACCEPTED\",\n                    \"SUCCESSFUL\",\n                    \"FAILED\"\n                ],\n                \"to_url\": \"https://webhook.site/xxx\"\n            }\n        ]\n    }\n}"
            },
            "url": {
              "raw": "{{baseUrl}}/v1/accounts/:institution/:account_number/withdraw",
              "host": [
                "{{baseUrl}}"
              ],
              "path": [
                "v1",
                "accounts",
                ":institution",
                ":account_number",
                "withdraw"
              ],
              "variable": [
                {
                  "key": "institution",
                  "value": "{{account_institution}}"
                },
                {
                  "key": "account_number",
                  "value": "{{account_number}}"
                }
              ]
            },
            "description": "Create a transfer"
          },
          "response": []
        }
      ]
    },
    {
      "name": "Lookup recipient account",
      "item": [
        {
          "name": "Lookup account",
          "event": [
            {
              "listen": "test",
              "script": {
                "exec": [
                  "pm.test(\"Status code is 200\", function () {",
                  "    pm.response.to.have.status(200);",
                  "});",
                  "pm.test(\"Account matches expected results\", function () {",
                  "    var jsonData = pm.response.json();",
                  "    pm.expect(jsonData.data.institution).to.eql(pm.environment.get('recipient_institution'));",
                  "    pm.expect(jsonData.data.account_number).to.eql(pm.request.toJSON().url.path[4]);",
                  "    pm.expect(jsonData.data.status).to.not.be.empty;",
                  "    //todo",
                  "});"
                ],
                "type": "text/javascript",
                "packages": {},
                "requests": {}
              }
            }
          ],
          "request": {
            "method": "GET",
            "header": [],
            "url": {
              "raw": "{{baseUrl}}/v1/accounts/:institution/:account_number",
              "host": [
                "{{baseUrl}}"
              ],
              "path": [
                "v1",
                "accounts",
                ":institution",
                ":account_number"
              ],
              "variable": [
                {
                  "key": "institution",
                  "value": "zw_bancabc",
                  "description": "(Required) Institution identifier as found in the institution api\n"
                },
                {
                  "key": "account_number",
                  "value": "123456789"
                }
              ]
            },
            "description": "Fetch information for an account number if the institution supports account discovery."
          },
          "response": []
        }
      ]
    },
    {
      "name": "Send local transfer",
      "item": [
        {
          "name": "Send local transfer",
          "event": [
            {
              "listen": "test",
              "script": {
                "exec": [
                  "pm.test(\"Successful POST request\", function () {",
                  "    pm.expect(pm.response.code).to.be.oneOf([200, 201]);",
                  "});",
                  "pm.test(\"Transfer returned\", function () {",
                  "    var jsonData = pm.response.json();",
                  "    pm.expect(jsonData.data.transfer_id).to.not.be.empty;",
                  "    pm.expect(jsonData.data.status).to.not.be.empty;",
                  "    pm.expect(jsonData.data.external_transaction_id).to.eql(pm.collectionVariables.get('__external_transaction_id'));",
                  "    pm.expect(jsonData.data.instruction.debtor).to.not.be.empty;",
                  "    pm.expect(jsonData.data.instruction.creditor).to.not.be.empty;",
                  "    pm.expect(jsonData.data.actions).to.not.be.empty;",
                  "});",
                  "pm.test(\"Transfer is pending\", function () {",
                  "    var jsonData = pm.response.json();",
                  "    pm.expect(jsonData.data.status).to.equal('PENDING');",
                  "});",
                  "pm.collectionVariables.set(\"__transfer_id\", pm.response.json().data.transfer_id);",
                  ""
                ],
                "type": "text/javascript",
                "packages": {},
                "requests": {}
              }
            },
            {
              "listen": "prerequest",
              "script": {
                "exec": [
                  "pm.collectionVariables.set(\"__external_transaction_id\", require('uuid').v4());"
                ],
                "type": "text/javascript",
                "packages": {},
                "requests": {}
              }
            }
          ],
          "request": {
            "method": "POST",
            "header": [
              {
                "key": "Content-Type",
                "value": "application/json"
              },
              {
                "key": "Content-Type",
                "value": "application/json",
                "disabled": true
              }
            ],
            "body": {
              "mode": "raw",
              "raw": "{\n    \"instruction\": {\n        \"debtor\": {\n            \"institution\": \"{{account_institution}}\",\n            \"account_number\": \"{{account_number}}\"\n        },\n        \"creditor\": {\n            \"institution\": \"zw_bancabc\",\n            \"account_number\": \"123456789\"\n        },\n        \"amount\": 10,\n        \"narration\": \"test\",\n        \"external_transaction_id\": \"{{__external_transaction_id}}\",\n        \"currency\": \"{{currency}}\",\n        \"scheme\": \"local_transfer\",\n        \"notifications\": [\n            {\n                \"on_status\": [\n                    \"SUCCESSFUL\",\n                    \"FAILED\",\n                    \"PENDING\"\n                ],\n                \"to_url\": \"\"\n            }\n        ]\n    }\n}"
            },
            "url": {
              "raw": "{{baseUrl}}/v1/transfers",
              "host": [
                "{{baseUrl}}"
              ],
              "path": [
                "v1",
                "transfers"
              ]
            },
            "description": "Create a transfer"
          },
          "response": []
        },
        {
          "name": "Verify that transfer was received",
          "event": [
            {
              "listen": "test",
              "script": {
                "exec": [
                  "pm.test(\"Status code is 200\", function () {",
                  "    pm.response.to.have.status(200);",
                  "});",
                  "pm.test(\"Transfer returned\", function () {",
                  "    var jsonData = pm.response.json();",
                  "    pm.expect(jsonData.data.transfer_id).to.not.be.empty;",
                  "    pm.expect(jsonData.responseMessage).to.equal('A request has been received for this external_transaction_id');",
                  "    pm.expect(jsonData.data.external_transaction_id).to.eql(pm.collectionVariables.get('__external_transaction_id'));",
                  "    pm.expect(jsonData.data.instruction.debtor).to.not.be.empty;",
                  "    pm.expect(jsonData.data.instruction.creditor).to.not.be.empty;",
                  "    pm.expect(jsonData.data.actions).to.not.be.empty;",
                  "});",
                  "pm.collectionVariables.set(\"__transfer_id\", pm.response.json().data.transfer_id);",
                  ""
                ],
                "type": "text/javascript"
              }
            }
          ],
          "request": {
            "method": "GET",
            "header": [],
            "url": {
              "raw": "{{baseUrl}}/v1/transfers/verify/:external_transaction_id",
              "host": [
                "{{baseUrl}}"
              ],
              "path": [
                "v1",
                "transfers",
                "verify",
                ":external_transaction_id"
              ],
              "variable": [
                {
                  "key": "external_transaction_id",
                  "value": "{{__external_transaction_id}}",
                  "description": "(Required) "
                }
              ]
            },
            "description": "Verify if a particular external transaction id has been received and processed by Tilt"
          },
          "response": []
        },
        {
          "name": "Fetch transfer by id",
          "event": [
            {
              "listen": "test",
              "script": {
                "exec": [
                  "pm.test(\"Status code is 200\", function () {",
                  "    pm.response.to.have.status(200);",
                  "});",
                  "pm.test(\"Transfer returned\", function () {",
                  "    var jsonData = pm.response.json();",
                  "    pm.expect(jsonData.data.transfer_id).to.eql(pm.collectionVariables.get(\"__transfer_id\"));",
                  "    pm.expect(jsonData.responseMessage).to.equal('Fetched transfer');",
                  "    pm.expect(jsonData.data.external_transaction_id).to.eql(pm.collectionVariables.get('__external_transaction_id'));",
                  "    pm.expect(jsonData.data.instruction.debtor).to.not.be.empty;",
                  "    pm.expect(jsonData.data.instruction.creditor).to.not.be.empty;",
                  "    pm.expect(jsonData.data.actions).to.not.be.empty;",
                  "});",
                  "",
                  "pm.test(\"Last action present\", function () {",
                  "    const action = pm.response.json().data.actions.pop();",
                  "    var jsonData = pm.response.json();",
                  "    pm.expect(jsonData.data.actions).to.be.an(\"array\");",
                  "    pm.expect(action).to.be.an(\"object\", \"last action not found\");",
                  "    pm.expect(action.status).to.eql(jsonData.data.status);",
                  "});"
                ],
                "type": "text/javascript"
              }
            }
          ],
          "request": {
            "method": "GET",
            "header": [],
            "url": {
              "raw": "{{baseUrl}}/v1/transfers/:transfer_id",
              "host": [
                "{{baseUrl}}"
              ],
              "path": [
                "v1",
                "transfers",
                ":transfer_id"
              ],
              "variable": [
                {
                  "key": "transfer_id",
                  "value": "{{__transfer_id}}",
                  "description": "(Required) Transfer ID issued by the platform"
                }
              ]
            },
            "description": "Fetch a transfer using transfer_id issued by Tilt"
          },
          "response": []
        },
        {
          "name": "Resend last webhook",
          "event": [
            {
              "listen": "test",
              "script": {
                "exec": [
                  "pm.test(\"Status code is 200\", function () {",
                  "    pm.response.to.have.status(200);",
                  "});",
                  "var jsonData = pm.response.json();",
                  "pm.test(\"response present\", function () {",
                  "    pm.expect(jsonData.data.response.http_code).to.exist;",
                  "});",
                  "pm.test(\"webhook present\", function () {",
                  "    pm.expect(jsonData.data.webhook.request_id).to.not.be.empty;",
                  "    pm.expect(jsonData.data.webhook.url).to.not.be.empty;",
                  "    pm.expect(jsonData.data.webhook.message).to.not.be.empty;",
                  "});"
                ],
                "type": "text/javascript"
              }
            }
          ],
          "request": {
            "method": "POST",
            "header": [
              {
                "key": "Content-Type",
                "value": "application/json",
                "type": "text"
              }
            ],
            "body": {
              "mode": "raw",
              "raw": "",
              "options": {
                "raw": {
                  "language": "json"
                }
              }
            },
            "url": {
              "raw": "{{baseUrl}}/v1/transfers/:transfer_id/resend-notification",
              "host": [
                "{{baseUrl}}"
              ],
              "path": [
                "v1",
                "transfers",
                ":transfer_id",
                "resend-notification"
              ],
              "variable": [
                {
                  "key": "transfer_id",
                  "value": "{{__transfer_id}}"
                }
              ]
            },
            "description": "Fetch a payment using payment_id issued by Tilt"
          },
          "response": []
        }
      ],
      "description": "The Transfers API allows you to send money directly into a recipient's account"
    },
    {
      "name": "Mock Samples",
      "item": [
        {
          "name": "Lookup recipient",
          "item": [
            {
              "name": "Success",
              "event": [
                {
                  "listen": "test",
                  "script": {
                    "exec": [
                      "pm.test(\"Status code is 200\", function () {",
                      "    pm.response.to.have.status(200);",
                      "});"
                    ],
                    "type": "text/javascript",
                    "packages": {}
                  }
                }
              ],
              "request": {
                "method": "GET",
                "header": [],
                "url": {
                  "raw": "{{baseUrl}}/v1/accounts/:institution/:account_number",
                  "host": [
                    "{{baseUrl}}"
                  ],
                  "path": [
                    "v1",
                    "accounts",
                    ":institution",
                    ":account_number"
                  ],
                  "variable": [
                    {
                      "key": "institution",
                      "value": "zm_airtel",
                      "description": "(Required) Institution identifier as found in the institution api\n"
                    },
                    {
                      "key": "account_number",
                      "value": "260970000100",
                      "description": "(Required) Account number (or mobile number for wallet) to lookup"
                    }
                  ]
                },
                "description": "Fetch information for an account number if the institution supports account discovery."
              },
              "response": []
            },
            {
              "name": "Account not found",
              "event": [
                {
                  "listen": "test",
                  "script": {
                    "exec": [
                      "pm.test(\"Status code is 200\", function () {",
                      "    pm.response.to.have.status(200);",
                      "});"
                    ],
                    "type": "text/javascript",
                    "packages": {}
                  }
                }
              ],
              "request": {
                "method": "GET",
                "header": [],
                "url": {
                  "raw": "{{baseUrl}}/v1/accounts/:institution/:account_number",
                  "host": [
                    "{{baseUrl}}"
                  ],
                  "path": [
                    "v1",
                    "accounts",
                    ":institution",
                    ":account_number"
                  ],
                  "variable": [
                    {
                      "key": "institution",
                      "value": "zm_airtel",
                      "description": "(Required) Institution identifier as found in the institution api\n"
                    },
                    {
                      "key": "account_number",
                      "value": "0970000600",
                      "description": "(Required) Account number (or mobile number for wallet) to lookup"
                    }
                  ]
                },
                "description": "Fetch information for an account number if the institution supports account discovery."
              },
              "response": []
            },
            {
              "name": "Institution error",
              "event": [
                {
                  "listen": "test",
                  "script": {
                    "exec": [
                      "pm.test(\"Status code is 200\", function () {",
                      "    pm.response.to.have.status(200);",
                      "});"
                    ],
                    "type": "text/javascript",
                    "packages": {}
                  }
                }
              ],
              "request": {
                "method": "GET",
                "header": [],
                "url": {
                  "raw": "{{baseUrl}}/v1/accounts/:institution/:account_number",
                  "host": [
                    "{{baseUrl}}"
                  ],
                  "path": [
                    "v1",
                    "accounts",
                    ":institution",
                    ":account_number"
                  ],
                  "variable": [
                    {
                      "key": "institution",
                      "value": "zm_airtel",
                      "description": "(Required) Institution identifier as found in the institution api\n"
                    },
                    {
                      "key": "account_number",
                      "value": "0970000700",
                      "description": "(Required) Account number (or mobile number for wallet) to lookup"
                    }
                  ]
                },
                "description": "Fetch information for an account number if the institution supports account discovery."
              },
              "response": []
            }
          ]
        },
        {
          "name": "Send local transfer",
          "item": [
            {
              "name": "Send - SUCCESSFUL",
              "event": [
                {
                  "listen": "test",
                  "script": {
                    "exec": [
                      "pm.test('Successful response', function () {",
                      "    pm.expect(pm.response.code).to.be.oneOf([",
                      "        200,",
                      "        201",
                      "    ]);",
                      "});",
                      "",
                      "pm.test(\"Transfer data OK\", function () {",
                      "    pm.expect(pm.response.json().data.transfer_id).to.not.be.empty;",
                      "    pm.expect(pm.response.json().data.status).to.equal('SUCCESSFUL');",
                      "    //pm.expect(jsonData.responseMessage).to.equal('Transfer successful');",
                      "    pm.expect(pm.response.json().data.external_transaction_id).to.eql(pm.collectionVariables.get('__external_transaction_id'));",
                      "    pm.expect(pm.response.json().data.instruction.debtor).to.not.be.empty;",
                      "    pm.expect(pm.response.json().data.instruction.creditor).to.not.be.empty;",
                      "});",
                      "",
                      "pm.test(\"Actions returned correctly\", function () {",
                      "    pm.expect(pm.response.json().data.actions).to.be.an(\"array\");",
                      "    const action = pm.response.json().data.actions.find(m => m.status === 'SUCCESSFUL');",
                      "    pm.expect(action).to.be.an(\"object\", \"SUCCESSFUL action not found\");",
                      "});",
                      "",
                      "pm.collectionVariables.set(\"__transfer_id\", pm.response.json().data.transfer_id);"
                    ],
                    "type": "text/javascript",
                    "packages": {}
                  }
                },
                {
                  "listen": "prerequest",
                  "script": {
                    "exec": [
                      "pm.collectionVariables.set(\"__external_transaction_id\", require('uuid').v4());"
                    ],
                    "type": "text/javascript",
                    "packages": {}
                  }
                }
              ],
              "request": {
                "method": "POST",
                "header": [
                  {
                    "key": "Content-Type",
                    "value": "application/json"
                  },
                  {
                    "key": "Content-Type",
                    "value": "application/json",
                    "disabled": true
                  }
                ],
                "body": {
                  "mode": "raw",
                  "raw": "{\n    \"instruction\": {\n        \"debtor\": {\n            \"institution\": \"{{account_institution}}\",\n            \"account_number\": \"{{account_number}}\"\n        },\n        \"creditor\": {\n            \"institution\": \"zm_airtel\",\n            \"account_number\": \"0970000100\"\n        },\n        \"amount\": 100,\n        \"narration\": \"mock success\",\n        \"external_transaction_id\": \"{{__external_transaction_id}}\",\n        \"currency\": \"{{currency}}\",\n        \"scheme\": \"local_transfer\",\n        \"notifications\": [\n            {\n                \"on_status\": [\n                    \"ACCEPTED\",\n                    \"SUCCESSFUL\",\n                    \"FAILED\",\n                    \"PENDING\"\n                ],\n                \"to_url\": \"\"\n            }\n        ]\n    }\n}"
                },
                "url": {
                  "raw": "{{baseUrl}}/v1/transfers",
                  "host": [
                    "{{baseUrl}}"
                  ],
                  "path": [
                    "v1",
                    "transfers"
                  ]
                },
                "description": "Create a transfer"
              },
              "response": []
            },
            {
              "name": "Send - FAILED (institution error)",
              "event": [
                {
                  "listen": "test",
                  "script": {
                    "exec": [
                      "pm.test('Successful response', function () {",
                      "    pm.expect(pm.response.code).to.be.oneOf([",
                      "        200,",
                      "        201",
                      "    ]);",
                      "});",
                      "",
                      "pm.test(\"Transfer data OK\", function () {",
                      "    pm.expect(pm.response.json().data.transfer_id).to.not.be.empty;",
                      "    pm.expect(pm.response.json().data.status).to.equal('SUCCESSFUL');",
                      "    //pm.expect(jsonData.responseMessage).to.equal('Transfer successful');",
                      "    pm.expect(pm.response.json().data.external_transaction_id).to.eql(pm.collectionVariables.get('__external_transaction_id'));",
                      "    pm.expect(pm.response.json().data.instruction.debtor).to.not.be.empty;",
                      "    pm.expect(pm.response.json().data.instruction.creditor).to.not.be.empty;",
                      "});",
                      "",
                      "pm.test(\"Actions returned correctly\", function () {",
                      "    pm.expect(pm.response.json().data.actions).to.be.an(\"array\");",
                      "    const action = pm.response.json().data.actions.find(m => m.status === 'SUCCESSFUL');",
                      "    pm.expect(action).to.be.an(\"object\", \"SUCCESSFUL action not found\");",
                      "});",
                      "",
                      "pm.collectionVariables.set(\"__transfer_id\", pm.response.json().data.transfer_id);"
                    ],
                    "type": "text/javascript",
                    "packages": {}
                  }
                },
                {
                  "listen": "prerequest",
                  "script": {
                    "exec": [
                      "pm.collectionVariables.set(\"__external_transaction_id\", require('uuid').v4());"
                    ],
                    "type": "text/javascript",
                    "packages": {}
                  }
                }
              ],
              "request": {
                "method": "POST",
                "header": [
                  {
                    "key": "Content-Type",
                    "value": "application/json"
                  },
                  {
                    "key": "Content-Type",
                    "value": "application/json",
                    "disabled": true
                  }
                ],
                "body": {
                  "mode": "raw",
                  "raw": "{\n    \"instruction\": {\n        \"debtor\": {\n            \"institution\": \"{{account_institution}}\",\n            \"account_number\": \"{{account_number}}\"\n        },\n        \"creditor\": {\n            \"institution\": \"zm_airtel\",\n            \"account_number\": \"0970000500\"\n        },\n        \"amount\": 100,\n        \"narration\": \"mock failed\",\n        \"external_transaction_id\": \"{{__external_transaction_id}}\",\n        \"currency\": \"{{currency}}\",\n        \"scheme\": \"local_transfer\",\n        \"notifications\": [\n            {\n                \"on_status\": [\n                    \"ACCEPTED\",\n                    \"SUCCESSFUL\",\n                    \"FAILED\",\n                    \"PENDING\"\n                ],\n                \"to_url\": \"\"\n            }\n        ]\n    }\n}"
                },
                "url": {
                  "raw": "{{baseUrl}}/v1/transfers",
                  "host": [
                    "{{baseUrl}}"
                  ],
                  "path": [
                    "v1",
                    "transfers"
                  ]
                },
                "description": "Create a transfer"
              },
              "response": []
            },
            {
              "name": "Send - FAILED (account not found)",
              "event": [
                {
                  "listen": "test",
                  "script": {
                    "exec": [
                      "pm.test('Successful response', function () {",
                      "    pm.expect(pm.response.code).to.be.oneOf([",
                      "        200,",
                      "        201",
                      "    ]);",
                      "});",
                      "",
                      "pm.test(\"Transfer data OK\", function () {",
                      "    pm.expect(pm.response.json().data.transfer_id).to.not.be.empty;",
                      "    pm.expect(pm.response.json().data.status).to.equal('SUCCESSFUL');",
                      "    //pm.expect(jsonData.responseMessage).to.equal('Transfer successful');",
                      "    pm.expect(pm.response.json().data.external_transaction_id).to.eql(pm.collectionVariables.get('__external_transaction_id'));",
                      "    pm.expect(pm.response.json().data.instruction.debtor).to.not.be.empty;",
                      "    pm.expect(pm.response.json().data.instruction.creditor).to.not.be.empty;",
                      "});",
                      "",
                      "pm.test(\"Actions returned correctly\", function () {",
                      "    pm.expect(pm.response.json().data.actions).to.be.an(\"array\");",
                      "    const action = pm.response.json().data.actions.find(m => m.status === 'SUCCESSFUL');",
                      "    pm.expect(action).to.be.an(\"object\", \"SUCCESSFUL action not found\");",
                      "});",
                      "",
                      "pm.collectionVariables.set(\"__transfer_id\", pm.response.json().data.transfer_id);"
                    ],
                    "type": "text/javascript",
                    "packages": {}
                  }
                },
                {
                  "listen": "prerequest",
                  "script": {
                    "exec": [
                      "pm.collectionVariables.set(\"__external_transaction_id\", require('uuid').v4());"
                    ],
                    "type": "text/javascript",
                    "packages": {}
                  }
                }
              ],
              "request": {
                "method": "POST",
                "header": [
                  {
                    "key": "Content-Type",
                    "value": "application/json"
                  },
                  {
                    "key": "Content-Type",
                    "value": "application/json",
                    "disabled": true
                  }
                ],
                "body": {
                  "mode": "raw",
                  "raw": "{\n    \"instruction\": {\n        \"debtor\": {\n            \"institution\": \"{{account_institution}}\",\n            \"account_number\": \"{{account_number}}\"\n        },\n        \"creditor\": {\n            \"institution\": \"zm_airtel\",\n            \"account_number\": \"0970000600\"\n        },\n        \"amount\": 100,\n        \"narration\": \"mock failed\",\n        \"external_transaction_id\": \"{{__external_transaction_id}}\",\n        \"currency\": \"{{currency}}\",\n        \"scheme\": \"local_transfer\",\n        \"notifications\": [\n            {\n                \"on_status\": [\n                    \"ACCEPTED\",\n                    \"SUCCESSFUL\",\n                    \"FAILED\",\n                    \"PENDING\"\n                ],\n                \"to_url\": \"\"\n            }\n        ]\n    }\n}"
                },
                "url": {
                  "raw": "{{baseUrl}}/v1/transfers",
                  "host": [
                    "{{baseUrl}}"
                  ],
                  "path": [
                    "v1",
                    "transfers"
                  ]
                },
                "description": "Create a transfer"
              },
              "response": []
            },
            {
              "name": "Send - FAILED (account error)",
              "event": [
                {
                  "listen": "test",
                  "script": {
                    "exec": [
                      "pm.test('Successful response', function () {",
                      "    pm.expect(pm.response.code).to.be.oneOf([",
                      "        200,",
                      "        201",
                      "    ]);",
                      "});",
                      "",
                      "pm.test(\"Transfer data OK\", function () {",
                      "    pm.expect(pm.response.json().data.transfer_id).to.not.be.empty;",
                      "    pm.expect(pm.response.json().data.status).to.equal('SUCCESSFUL');",
                      "    //pm.expect(jsonData.responseMessage).to.equal('Transfer successful');",
                      "    pm.expect(pm.response.json().data.external_transaction_id).to.eql(pm.collectionVariables.get('__external_transaction_id'));",
                      "    pm.expect(pm.response.json().data.instruction.debtor).to.not.be.empty;",
                      "    pm.expect(pm.response.json().data.instruction.creditor).to.not.be.empty;",
                      "});",
                      "",
                      "pm.test(\"Actions returned correctly\", function () {",
                      "    pm.expect(pm.response.json().data.actions).to.be.an(\"array\");",
                      "    const action = pm.response.json().data.actions.find(m => m.status === 'SUCCESSFUL');",
                      "    pm.expect(action).to.be.an(\"object\", \"SUCCESSFUL action not found\");",
                      "});",
                      "",
                      "pm.collectionVariables.set(\"__transfer_id\", pm.response.json().data.transfer_id);"
                    ],
                    "type": "text/javascript",
                    "packages": {}
                  }
                },
                {
                  "listen": "prerequest",
                  "script": {
                    "exec": [
                      "pm.collectionVariables.set(\"__external_transaction_id\", require('uuid').v4());"
                    ],
                    "type": "text/javascript",
                    "packages": {}
                  }
                }
              ],
              "request": {
                "method": "POST",
                "header": [
                  {
                    "key": "Content-Type",
                    "value": "application/json"
                  },
                  {
                    "key": "Content-Type",
                    "value": "application/json",
                    "disabled": true
                  }
                ],
                "body": {
                  "mode": "raw",
                  "raw": "{\n    \"instruction\": {\n        \"debtor\": {\n            \"institution\": \"{{account_institution}}\",\n            \"account_number\": \"{{account_number}}\"\n        },\n        \"creditor\": {\n            \"institution\": \"zm_airtel\",\n            \"account_number\": \"0970000700\"\n        },\n        \"amount\": 100,\n        \"narration\": \"mock failed\",\n        \"external_transaction_id\": \"{{__external_transaction_id}}\",\n        \"currency\": \"{{currency}}\",\n        \"scheme\": \"local_transfer\",\n        \"notifications\": [\n            {\n                \"on_status\": [\n                    \"ACCEPTED\",\n                    \"SUCCESSFUL\",\n                    \"FAILED\",\n                    \"PENDING\"\n                ],\n                \"to_url\": \"\"\n            }\n        ]\n    }\n}"
                },
                "url": {
                  "raw": "{{baseUrl}}/v1/transfers",
                  "host": [
                    "{{baseUrl}}"
                  ],
                  "path": [
                    "v1",
                    "transfers"
                  ]
                },
                "description": "Create a transfer"
              },
              "response": []
            },
            {
              "name": "Send - PENDING > SUCCESSFUL",
              "event": [
                {
                  "listen": "test",
                  "script": {
                    "exec": [
                      "pm.test('Successful response', function () {",
                      "    pm.expect(pm.response.code).to.be.oneOf([",
                      "        200,",
                      "        201",
                      "    ]);",
                      "});",
                      "",
                      "pm.test(\"Transfer data OK\", function () {",
                      "    pm.expect(pm.response.json().data.transfer_id).to.not.be.empty;",
                      "    pm.expect(pm.response.json().data.status).to.equal('SUCCESSFUL');",
                      "    //pm.expect(jsonData.responseMessage).to.equal('Transfer successful');",
                      "    pm.expect(pm.response.json().data.external_transaction_id).to.eql(pm.collectionVariables.get('__external_transaction_id'));",
                      "    pm.expect(pm.response.json().data.instruction.debtor).to.not.be.empty;",
                      "    pm.expect(pm.response.json().data.instruction.creditor).to.not.be.empty;",
                      "});",
                      "",
                      "pm.test(\"Actions returned correctly\", function () {",
                      "    pm.expect(pm.response.json().data.actions).to.be.an(\"array\");",
                      "    const action = pm.response.json().data.actions.find(m => m.status === 'SUCCESSFUL');",
                      "    pm.expect(action).to.be.an(\"object\", \"SUCCESSFUL action not found\");",
                      "});",
                      "",
                      "pm.collectionVariables.set(\"__transfer_id\", pm.response.json().data.transfer_id);"
                    ],
                    "type": "text/javascript",
                    "packages": {}
                  }
                },
                {
                  "listen": "prerequest",
                  "script": {
                    "exec": [
                      "pm.collectionVariables.set(\"__external_transaction_id\", require('uuid').v4());"
                    ],
                    "type": "text/javascript",
                    "packages": {}
                  }
                }
              ],
              "request": {
                "method": "POST",
                "header": [
                  {
                    "key": "Content-Type",
                    "value": "application/json"
                  },
                  {
                    "key": "Content-Type",
                    "value": "application/json",
                    "disabled": true
                  }
                ],
                "body": {
                  "mode": "raw",
                  "raw": "{\n    \"instruction\": {\n        \"debtor\": {\n            \"institution\": \"{{account_institution}}\",\n            \"account_number\": \"{{account_number}}\"\n        },\n        \"creditor\": {\n            \"institution\": \"zm_airtel\",\n            \"account_number\": \"0970000200\"\n        },\n        \"amount\": 100,\n        \"narration\": \"mock pending > success\",\n        \"external_transaction_id\": \"{{__external_transaction_id}}\",\n        \"currency\": \"{{currency}}\",\n        \"scheme\": \"local_transfer\",\n        \"notifications\": [\n            {\n                \"on_status\": [\n                    \"ACCEPTED\",\n                    \"SUCCESSFUL\",\n                    \"FAILED\",\n                    \"PENDING\"\n                ],\n                \"to_url\": \"\"\n            }\n        ]\n    }\n}"
                },
                "url": {
                  "raw": "{{baseUrl}}/v1/transfers",
                  "host": [
                    "{{baseUrl}}"
                  ],
                  "path": [
                    "v1",
                    "transfers"
                  ]
                },
                "description": "Create a transfer"
              },
              "response": []
            },
            {
              "name": "Send - PENDING > FAILED",
              "event": [
                {
                  "listen": "test",
                  "script": {
                    "exec": [
                      "pm.test('Successful response', function () {",
                      "    pm.expect(pm.response.code).to.be.oneOf([",
                      "        200,",
                      "        201",
                      "    ]);",
                      "});",
                      "",
                      "pm.test(\"Transfer data OK\", function () {",
                      "    pm.expect(pm.response.json().data.transfer_id).to.not.be.empty;",
                      "    pm.expect(pm.response.json().data.status).to.equal('SUCCESSFUL');",
                      "    //pm.expect(jsonData.responseMessage).to.equal('Transfer successful');",
                      "    pm.expect(pm.response.json().data.external_transaction_id).to.eql(pm.collectionVariables.get('__external_transaction_id'));",
                      "    pm.expect(pm.response.json().data.instruction.debtor).to.not.be.empty;",
                      "    pm.expect(pm.response.json().data.instruction.creditor).to.not.be.empty;",
                      "});",
                      "",
                      "pm.test(\"Actions returned correctly\", function () {",
                      "    pm.expect(pm.response.json().data.actions).to.be.an(\"array\");",
                      "    const action = pm.response.json().data.actions.find(m => m.status === 'SUCCESSFUL');",
                      "    pm.expect(action).to.be.an(\"object\", \"SUCCESSFUL action not found\");",
                      "});",
                      "",
                      "pm.collectionVariables.set(\"__transfer_id\", pm.response.json().data.transfer_id);"
                    ],
                    "type": "text/javascript",
                    "packages": {}
                  }
                },
                {
                  "listen": "prerequest",
                  "script": {
                    "exec": [
                      "pm.collectionVariables.set(\"__external_transaction_id\", require('uuid').v4());"
                    ],
                    "type": "text/javascript",
                    "packages": {}
                  }
                }
              ],
              "request": {
                "method": "POST",
                "header": [
                  {
                    "key": "Content-Type",
                    "value": "application/json"
                  },
                  {
                    "key": "Content-Type",
                    "value": "application/json",
                    "disabled": true
                  }
                ],
                "body": {
                  "mode": "raw",
                  "raw": "{\n    \"instruction\": {\n        \"debtor\": {\n            \"institution\": \"{{account_institution}}\",\n            \"account_number\": \"{{account_number}}\"\n        },\n        \"creditor\": {\n            \"institution\": \"zm_airtel\",\n            \"account_number\": \"0970000300\"\n        },\n        \"amount\": 100,\n        \"narration\": \"mock pending > failed\",\n        \"external_transaction_id\": \"{{__external_transaction_id}}\",\n        \"currency\": \"{{currency}}\",\n        \"scheme\": \"local_transfer\",\n        \"notifications\": [\n            {\n                \"on_status\": [\n                    \"ACCEPTED\",\n                    \"SUCCESSFUL\",\n                    \"FAILED\",\n                    \"PENDING\"\n                ],\n                \"to_url\": \"\"\n            }\n        ]\n    }\n}"
                },
                "url": {
                  "raw": "{{baseUrl}}/v1/transfers",
                  "host": [
                    "{{baseUrl}}"
                  ],
                  "path": [
                    "v1",
                    "transfers"
                  ]
                },
                "description": "Create a transfer"
              },
              "response": []
            }
          ]
        }
      ]
    }
  ],
  "auth": {
    "type": "bearer",
    "bearer": [
      {
        "key": "token",
        "value": "{{bearerToken}}",
        "type": "string"
      }
    ]
  },
  "event": [
    {
      "listen": "prerequest",
      "script": {
        "type": "text/javascript",
        "exec": [
          ""
        ]
      }
    },
    {
      "listen": "test",
      "script": {
        "type": "text/javascript",
        "exec": [
          ""
        ]
      }
    }
  ],
  "variable": [
    {
      "key": "__external_transaction_id",
      "value": ""
    },
    {
      "key": "__payment_id",
      "value": ""
    },
    {
      "key": "__transfer_id",
      "value": ""
    }
  ]
}