{ "info": { "_postman_id": "6936ca51-cee4-4749-9c23-2cfcd688c322", "name": "Paynetics APIs", "schema": "https://schema.getpostman.com/json/collection/v2.1.0/collection.json", "_exporter_id": "25950916" }, "item": [ { "name": "Onboarding", "item": [ { "name": "Success scenarios", "item": [ { "name": "Application create", "event": [ { "listen": "prerequest", "script": { "exec": [ "var json = {", " \"products\": [", " \"pos\",", " ],", " \"due_diligence\": \"CDD\",", " \"questionnaire\": {", " \"source_of_funds\": \"sale_of_real_estate\",", " \"projected_monthly_volume\": 1", " },", " \"acquiring\": {", " \"ecommerce\": {", " \"fee_group\": \"test\",", " \"descriptor\": \"dsa\",", " \"supported_authorization_types\": [", " \"moto\"", " ]", " },", " \"pos\": {", " \"fee_group\": \"test\",", " \"descriptor\": \"dsa\",", " \"supported_authorization_types\": [", " \"moto\"", " ]", " }", " },", " \"company\": {", " \"legal_name\": pm.variables.replaceIn(\"{{$randomCompanyName}}\"),", " \"trade_name\": pm.variables.replaceIn(\"{{$randomCompanyName}}\"),", " \"legal_form\": \"other\",", " \"legal_form_description\": \"dsa\",", " \"is_sie\": false,", " \"uic\": pm.variables.replaceIn(\"{{$timestamp}}\"),", " \"currency\": \"BGN\",", " \"address_of_shop\": \"dsa\",", " \"incorporation_date\": \"2025-01-01 13:45:30\",", " \"business_activity\": \"second-hand-store\",", " \"industry\": \"22\",", " \"contact_email\": \"asd@a.com\",", " \"mobile_phone\": \"+3591234\",", " \"country\": \"BG\",", " \"country_of_incorporation\": \"TR\",", " \"county\": \"asd\",", " \"city\": \"Sofia\",", " \"zip\": \"asd\",", " \"address1\": \"///\",", " \"address2\": \"asd\",", " \"correspondence_address\": \"correspondence_address\",", " \"website\": \"https://sandbox.payoo.cloud\",", " \"documents\": [", " {", " \"file\": \"iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVR42mNksP3/HwADvgI9/iYBsgAAAABJRU5ErkJggg==\",", " \"file_type\": \"jpg\",", " \"document_type\": \"picture-of-shop\",", " \"is_video\": true", " },", " {", " \"file\": \"iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVR42mNksP3/HwADvgI9/iYBsgAAAABJRU5ErkJggg==\",", " \"file_type\": \"jpg\",", " \"document_type\": \"incorporation-documents\",", " \"is_video\": true", " },", " {", " \"file\": \"iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVR42mNksP3/HwADvgI9/iYBsgAAAABJRU5ErkJggg==\",", " \"file_type\": \"jpg\",", " \"document_type\": \"aml-screening\",", " \"is_video\": true", " },", " {", " \"file\": \"iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVR42mNksP3/HwADvgI9/iYBsgAAAABJRU5ErkJggg==\",", " \"file_type\": \"jpg\",", " \"document_type\": \"company-screening-report\",", " \"is_video\": true", " }", " ],", " \"company_members\": [", " {", " \"first_name\": pm.variables.replaceIn(\"{{$randomFirstName}}\"),", " \"last_name\": pm.variables.replaceIn(\"{{$randomLastName}}\"),", " \"birthday\": \"2010-12-12\",", " \"mobile_phone\": \"+359898\",", " \"county\": \"dsadsa\",", " \"legal_name\": \"das\",", " \"ownership\": true,", " \"unique_identifier\": \"test\",", " \"nationality\": \"BG\",", " \"place_of_birth\": \"2010-06-08\",", " \"zip\": \"1000\",", " \"legal_form\": \"other\",", " \"uic\": \"dsappn0dasdsa00\",", " \"country_of_residence\": \"BG\",", " \"address_1\": \"12\",", " \"city\": \"Sofia\",", " \"contact_email\": pm.variables.replaceIn(\"{{$randomExampleEmail}}\"),", " \"type\": [", " \"ceo\"", " ],", " \"is_sip\": false,", " \"pep_declaration\": true,", " \"pep_related_declaration\": true,", " \"country\": \"BG\",", " \"documents\": [", " {", " \"file\": \"iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVR42mNksP3/HwADvgI9/iYBsgAAAABJRU5ErkJggg==\",", " \"file_type\": \"jpg\",", " \"document_type\": \"id-screening-report\",", " \"is_video\": true", " },", " {", " \"file\": \"iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVR42mNksP3/HwADvgI9/iYBsgAAAABJRU5ErkJggg==\",", " \"file_type\": \"jpg\",", " \"document_type\": \"bill\",", " \"is_video\": true", " },", " {", " \"file\": \"iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVR42mNksP3/HwADvgI9/iYBsgAAAABJRU5ErkJggg==\",", " \"file_type\": \"jpg\",", " \"document_type\": \"idcard-back\",", " \"is_video\": true", " },", " {", " \"file\": \"iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVR42mNksP3/HwADvgI9/iYBsgAAAABJRU5ErkJggg==\",", " \"file_type\": \"jpg\",", " \"document_type\": \"idcard-front\",", " \"is_video\": true", " },", " {", " \"file\": \"iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVR42mNksP3/HwADvgI9/iYBsgAAAABJRU5ErkJggg==\",", " \"file_type\": \"jpg\",", " \"document_type\": \"proof\",", " \"is_video\": true", " }", " ]", " }", " ]", " }", "}", "json = JSON.stringify(json)", " ", "eval(pm.variables.get('fnSetAuth'));", "setAuth('application_create',json);", "pm.variables.set('body', json);" ], "type": "text/javascript" } }, { "listen": "test", "script": { "exec": [ "var jsonData = pm.response.json();", "var applicationToken = jsonData.authenticated;pm.collectionVariables.set(\"applicationToken\", pm.response.json().data.token);", "var companyMemberToken = jsonData.authenticated;pm.collectionVariables.set(\"companyMemberToken\", pm.response.json().data.company.company_members[0].token);" ], "type": "text/javascript" } } ], "protocolProfileBehavior": { "strictSSL": false }, "request": { "method": "POST", "header": [ { "key": "Content-Type", "name": "Content-Type", "value": "application/x-www-form-urlencoded", "type": "text", "disabled": true } ], "body": { "mode": "raw", "raw": "{{body}}", "options": { "raw": { "language": "json" } } }, "url": { "raw": "{{API_GATEWAY}}/v3/applications", "host": [ "{{API_GATEWAY}}" ], "path": [ "v3", "applications" ] } }, "response": [] }, { "name": "Application update", "event": [ { "listen": "prerequest", "script": { "exec": [ "var json = {", " \"trade_name\": \"Paynetics\",", " \"legal_name\": \"Paynetics AD\",", " \"website\": \"https://paynetics.digital\",", " \"phone\": \"+35900000000\",", " \"mobile_phone\": \"+35900000000\",", " \"country\": \"BG\",", " \"county\": \"Sofia Grad\",", " \"city\": \"Sofia\",", " \"zip\": \"1407\",", " \"address1\": \"James Bouchier 76A\",", " \"address2\": \"Floor 2\",", " \"contact_email\": \"john.doe@paynetics.digital\",", " \"correspondence_address\": \"James Bouchier 76A\",", " \"description_of_activity\": \"Acquiring, Issuing etc.\",", " \"address_of_shop\": \"James Bouchier 76A\",", " \"is_sie\": false", "}", "json = JSON.stringify(json)", " ", "eval(pm.variables.get('fnSetAuth'));", "setAuth('company_update',json);", "pm.variables.set('body', json);" ], "type": "text/javascript" } }, { "listen": "test", "script": { "exec": [ "" ], "type": "text/javascript" } } ], "protocolProfileBehavior": { "strictSSL": false }, "request": { "method": "PUT", "header": [ { "key": "Content-Type", "name": "Content-Type", "value": "application/x-www-form-urlencoded", "type": "text", "disabled": true } ], "body": { "mode": "raw", "raw": "{{body}}", "options": { "raw": { "language": "json" } } }, "url": { "raw": "{{API_GATEWAY}}/v3/applications/{{applicationToken}}/companies", "host": [ "{{API_GATEWAY}}" ], "path": [ "v3", "applications", "{{applicationToken}}", "companies" ] } }, "response": [] }, { "name": "Update company member", "event": [ { "listen": "prerequest", "script": { "exec": [ "var json = {", " \"first_name\": \"John\",", " \"last_name\": \"Doe\",", " \"mobile_phone\": \"+359000000000\",", " \"phone\": \"+359000000000\",", " \"legal_name\": \"Paynetics AD\",", " \"country\": \"BG\",", " \"country_of_residence\": \"BG\",", " \"zip\": \"1407\",", " \"city\": \"Sofia\",", " \"address1\": \"James Bouchier 76A\",", " \"address2\": \"Floor 2\",", " \"county\": \"Sofia Grad\",", " \"ownership\": true,", " \"ownership_percentage\": 10,", " \"pep_declaration\": true,", " \"pep_related_declaration\": true,", " \"is_sip\": true,", " \"contact_email\": \"John Doe\",", " \"status\": \"active\"", "}", "json = JSON.stringify(json)", "", "eval(pm.variables.get('fnSetAuth'));", "setAuth('company_member_update', json);", "pm.variables.set('body', json);" ], "type": "text/javascript" } }, { "listen": "test", "script": { "exec": [ "" ], "type": "text/javascript" } } ], "protocolProfileBehavior": { "strictSSL": false }, "request": { "method": "PUT", "header": [ { "key": "Content-Type", "name": "Content-Type", "value": "application/x-www-form-urlencoded", "type": "text", "disabled": true } ], "body": { "mode": "raw", "raw": "{{body}}", "options": { "raw": { "language": "json" } } }, "url": { "raw": "{{API_GATEWAY}}/v3/applications/{{applicationToken}}/companies/members/{{companyMemberToken}}", "host": [ "{{API_GATEWAY}}" ], "path": [ "v3", "applications", "{{applicationToken}}", "companies", "members", "{{companyMemberToken}}" ] } }, "response": [] }, { "name": "Add company details", "event": [ { "listen": "prerequest", "script": { "exec": [ "var json = {", " \"file\": \"iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVR42mNksP3/HwADvgI9/iYBsgAAAABJRU5ErkJggg==\",", " \"file_type\": \"pdf\",", " \"document_type\": \"passport\"", "}", "json = JSON.stringify(json)", "", "eval(pm.variables.get('fnSetAuth'));", "setAuth('company_add_document', json);", "pm.variables.set('body', json);" ], "type": "text/javascript" } }, { "listen": "test", "script": { "exec": [ "" ], "type": "text/javascript" } } ], "protocolProfileBehavior": { "strictSSL": false }, "request": { "method": "POST", "header": [ { "key": "Content-Type", "name": "Content-Type", "value": "application/x-www-form-urlencoded", "type": "text", "disabled": true } ], "body": { "mode": "raw", "raw": "{{body}}", "options": { "raw": { "language": "json" } } }, "url": { "raw": "{{API_GATEWAY}}/v3/applications/{{applicationToken}}/companies/documents", "host": [ "{{API_GATEWAY}}" ], "path": [ "v3", "applications", "{{applicationToken}}", "companies", "documents" ] } }, "response": [] }, { "name": "Add company member", "event": [ { "listen": "prerequest", "script": { "exec": [ "var json = {", " \"first_name\": \"John\",", " \"last_name\": \"Doe\",", " \"mobile_phone\": \"+359000000000\",", " \"phone\": \"+359000000000\",", " \"legal_name\": \"Paynetics AD\",", " \"uic\": \"123456\",", " \"country\": \"BG\",", " \"country_of_residence\": \"BG\",", " \"zip\": \"1407\",", " \"city\": \"Sofia\",", " \"address1\": \"James Bouchier 76A\",", " \"address2\": \"Floor 2\",", " \"county\": \"Sofia Grad\",", " \"ownership\": true,", " \"ownership_percentage\": 10,", " \"type\": [", " {", " \"type\": \"string\",", " \"enum\": [", " \"ubo\",", " \"ceo\",", " \"representative\",", " \"proxy\",", " \"legal-entity\",", " \"officer\"", " ]", " }", " ],", " \"unique_identifier\": \"123456\",", " \"user\": \"\",", " \"legal_form\": \"sole-trader\",", " \"place_of_birth\": \"BG\",", " \"pep_declaration\": true,", " \"pep_related_declaration\": true,", " \"is_sip\": true,", " \"birthday\": \"1992-03-28\",", " \"nationality\": \"BG\",", " \"contact_email\": \"John Doe\",", " \"documents\": [", " {", " \"file\": \"iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVR42mNksP3/HwADvgI9/iYBsgAAAABJRU5ErkJggg==\",", " \"file_type\": \"pdf\",", " \"document_type\": \"passport\"", " }", " ]", "}", "json = JSON.stringify(json)", "", "eval(pm.variables.get('fnSetAuth'));", "setAuth('company_add_member', json);", "pm.variables.set('body', json);" ], "type": "text/javascript" } }, { "listen": "test", "script": { "exec": [ "" ], "type": "text/javascript" } } ], "protocolProfileBehavior": { "strictSSL": false }, "request": { "method": "POST", "header": [ { "key": "Content-Type", "name": "Content-Type", "value": "application/x-www-form-urlencoded", "type": "text", "disabled": true } ], "body": { "mode": "raw", "raw": "{{body}}", "options": { "raw": { "language": "json" } } }, "url": { "raw": "{{API_GATEWAY}}/v3/applications/{{applicationToken}}/companies/members", "host": [ "{{API_GATEWAY}}" ], "path": [ "v3", "applications", "{{applicationToken}}", "companies", "members" ] } }, "response": [] }, { "name": "Add company member document", "event": [ { "listen": "prerequest", "script": { "exec": [ "var json = {", " \"file\": \"iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVR42mNksP3/HwADvgI9/iYBsgAAAABJRU5ErkJggg==\",", " \"file_type\": \"pdf\",", " \"document_type\": \"passport\"", "}", "json = JSON.stringify(json)", "", "eval(pm.variables.get('fnSetAuth'));", "setAuth('company_member_add_document', json);", "pm.variables.set('body', json);" ], "type": "text/javascript" } }, { "listen": "test", "script": { "exec": [ "" ], "type": "text/javascript" } } ], "protocolProfileBehavior": { "strictSSL": false }, "request": { "method": "POST", "header": [ { "key": "Content-Type", "name": "Content-Type", "value": "application/x-www-form-urlencoded", "type": "text", "disabled": true } ], "body": { "mode": "raw", "raw": "{{body}}", "options": { "raw": { "language": "json" } } }, "url": { "raw": "{{API_GATEWAY}}/v3/applications/{{applicationToken}}/companies/members/{{companyMemberToken}}/documents", "host": [ "{{API_GATEWAY}}" ], "path": [ "v3", "applications", "{{applicationToken}}", "companies", "members", "{{companyMemberToken}}", "documents" ] } }, "response": [] } ] } ] }, { "name": "Users", "item": [ { "name": "Success scenarios", "item": [ { "name": "Create Natural Person", "event": [ { "listen": "prerequest", "script": { "exec": [ "var json = {", " \"email\": pm.variables.replaceIn(\"{{$randomExampleEmail}}\"),", " \"first_name\": pm.variables.replaceIn(\"{{$randomFirstName}}\"),", " \"last_name\": pm.variables.replaceIn(\"{{$randomLastName}}\"),", " \"address1\": \"James Bouchier 76a\",", " \"address2\": \"string\",", " \"country\": \"BG\",", " \"city\": \"Sofia\",", " \"zip\": \"1407\",", " \"phone\": \"+3590000000\",", " \"mobile_phone\": \"+3590000000\",", " \"language\": \"string\",", " \"nationality\": \"BG\",", " \"birthday\": \"1992-12-12\",", " \"place_of_birth\": \"string\",", " \"merchant\": \"string\",", " \"occupation\": \"string\",", " \"education\": \"string\",", " \"info\": \"string\",", " \"money_declaration\": \"string\",", " \"source_of_funds\": \"string\",", " \"external_reference\": \"string\",", " \"registration_ip\": \"string\",", " \"is_san\": \"string\",", " \"peps_declaration\": \"string\",", " \"pep\": \"string\",", " \"pep_relative\": \"string\",", " \"unique_identifier\": \"dadsad\",", " \"id_passport_validity\": \"passport\",", " \"id_passport_number\": \"passport\",", " \"documents\": [", " {", " \"file\": \"iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVR42mNksP3/HwADvgI9/iYBsgAAAABJRU5ErkJggg==\",", " \"file_type\": \"jpg\",", " \"document_type\": \"bill\",", " },", " {", " \"file\": \"iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVR42mNksP3/HwADvgI9/iYBsgAAAABJRU5ErkJggg==\",", " \"file_type\": \"jpg\",", " \"document_type\": \"bankstmt\",", " },", " {", " \"file\": \"iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVR42mNksP3/HwADvgI9/iYBsgAAAABJRU5ErkJggg==\",", " \"file_type\": \"jpg\",", " \"document_type\": \"idcard-front\",", " },", " {", " \"file\": \"iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVR42mNksP3/HwADvgI9/iYBsgAAAABJRU5ErkJggg==\",", " \"file_type\": \"jpg\",", " \"document_type\": \"idcard-back\",", " },", " {", " \"file\": \"iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVR42mNksP3/HwADvgI9/iYBsgAAAABJRU5ErkJggg==\",", " \"file_type\": \"jpg\",", " \"document_type\": \"selfie\",", " },", " {", " \"file\": \"iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVR42mNksP3/HwADvgI9/iYBsgAAAABJRU5ErkJggg==\",", " \"file_type\": \"jpg\",", " \"document_type\": \"aml-screening\",", " }", " ]", "}", "json = JSON.stringify(json)", "", "eval(pm.variables.get('fnSetAuth'));", "setAuth('user_create', json);", "pm.variables.set('body', json);" ], "type": "text/javascript" } }, { "listen": "test", "script": { "exec": [ "var jsonData = pm.response.json();", "var userToken = jsonData.authenticated;pm.collectionVariables.set(\"userToken\", pm.response.json().data.token);" ], "type": "text/javascript" } } ], "protocolProfileBehavior": { "strictSSL": false }, "request": { "method": "POST", "header": [ { "key": "Content-Type", "name": "Content-Type", "value": "application/x-www-form-urlencoded", "type": "text", "disabled": true } ], "body": { "mode": "raw", "raw": "{{body}}", "options": { "raw": { "language": "json" } } }, "url": { "raw": "{{API_GATEWAY}}/v2/users", "host": [ "{{API_GATEWAY}}" ], "path": [ "v2", "users" ] } }, "response": [] }, { "name": "Update Natural Person", "event": [ { "listen": "prerequest", "script": { "exec": [ "var json = {", " ", "}", "json = JSON.stringify(json)", "", "eval(pm.variables.get('fnSetAuth'));", "setAuth('user_update', json);", "pm.variables.set('body', json);" ], "type": "text/javascript" } }, { "listen": "test", "script": { "exec": [ "" ], "type": "text/javascript" } } ], "protocolProfileBehavior": { "strictSSL": false }, "request": { "method": "PUT", "header": [ { "key": "Content-Type", "name": "Content-Type", "value": "application/x-www-form-urlencoded", "type": "text", "disabled": true } ], "body": { "mode": "raw", "raw": "{{body}}", "options": { "raw": { "language": "json" } } }, "url": { "raw": "{{API_GATEWAY}}/v2/users/{{userToken}}", "host": [ "{{API_GATEWAY}}" ], "path": [ "v2", "users", "{{userToken}}" ] } }, "response": [] }, { "name": "Get Details Natural Person", "event": [ { "listen": "prerequest", "script": { "exec": [ "var json = {", " ", "}", "json = JSON.stringify(json)", "", "eval(pm.variables.get('fnSetAuth'));", "setAuth('user_details', json);", "pm.variables.set('body', json);" ], "type": "text/javascript" } }, { "listen": "test", "script": { "exec": [ "" ], "type": "text/javascript" } } ], "protocolProfileBehavior": { "strictSSL": false, "disableBodyPruning": true }, "request": { "method": "GET", "header": [ { "key": "Content-Type", "name": "Content-Type", "value": "application/x-www-form-urlencoded", "type": "text", "disabled": true } ], "body": { "mode": "raw", "raw": "{{body}}", "options": { "raw": { "language": "json" } } }, "url": { "raw": "{{API_GATEWAY}}/v2/users/{{userToken}}", "host": [ "{{API_GATEWAY}}" ], "path": [ "v2", "users", "{{userToken}}" ] } }, "response": [] }, { "name": "Delete Natural Person", "event": [ { "listen": "prerequest", "script": { "exec": [ "var json = {", " ", "}", "json = JSON.stringify(json)", "", "eval(pm.variables.get('fnSetAuth'));", "setAuth('user_remove', json);", "pm.variables.set('body', json);" ], "type": "text/javascript" } }, { "listen": "test", "script": { "exec": [ "" ], "type": "text/javascript" } } ], "protocolProfileBehavior": { "strictSSL": false }, "request": { "method": "DELETE", "header": [ { "key": "Content-Type", "name": "Content-Type", "value": "application/x-www-form-urlencoded", "type": "text", "disabled": true } ], "body": { "mode": "raw", "raw": "{{body}}", "options": { "raw": { "language": "json" } } }, "url": { "raw": "{{API_GATEWAY}}/v2/users/{{userToken}}", "host": [ "{{API_GATEWAY}}" ], "path": [ "v2", "users", "{{userToken}}" ] } }, "response": [] } ] } ] }, { "name": "AML Check", "item": [ { "name": "Success scenarios", "item": [ { "name": "AML check", "event": [ { "listen": "prerequest", "script": { "exec": [ "var json = {", " \"first_name\": \"Dimitar\",", " \"last_name\": \"Tanev\",", " \"address1\": \"James Bouchier 76a\",", " \"birthday\": \"1993-02-02\",", " \"nationality\": \"BG\"", "}", "json = JSON.stringify(json)", "", "eval(pm.variables.get('fnSetAuth'));", "setAuth('aml_check', json);", "pm.variables.set('body', json);" ], "type": "text/javascript" } }, { "listen": "test", "script": { "exec": [ "" ], "type": "text/javascript" } } ], "protocolProfileBehavior": { "strictSSL": false }, "request": { "method": "POST", "header": [ { "key": "Content-Type", "name": "Content-Type", "value": "application/x-www-form-urlencoded", "type": "text", "disabled": true } ], "body": { "mode": "raw", "raw": "{{body}}", "options": { "raw": { "language": "json" } } }, "url": { "raw": "{{API_GATEWAY}}/v1/aml", "host": [ "{{API_GATEWAY}}" ], "path": [ "v1", "aml" ] } }, "response": [] } ] }, { "name": "Negative scenarios", "item": [ { "name": "AML check", "event": [ { "listen": "prerequest", "script": { "exec": [ "var json = {", " \"first_name\": \"John\",", " \"last_name\": \"Doe\",", " \"address1\": \"James Bouchier 76a\",", " \"birthday\": \"1993-02-02\",", " \"nationality\": \"BG\"", "}", "json = JSON.stringify(json)", "", "eval(pm.variables.get('fnSetAuth'));", "setAuth('aml_check', json);", "pm.variables.set('body', json);" ], "type": "text/javascript" } }, { "listen": "test", "script": { "exec": [ "" ], "type": "text/javascript" } } ], "protocolProfileBehavior": { "strictSSL": false }, "request": { "method": "POST", "header": [ { "key": "Content-Type", "name": "Content-Type", "value": "application/x-www-form-urlencoded", "type": "text", "disabled": true } ], "body": { "mode": "raw", "raw": "{{body}}", "options": { "raw": { "language": "json" } } }, "url": { "raw": "{{API_GATEWAY}}/v1/aml", "host": [ "{{API_GATEWAY}}" ], "path": [ "v1", "aml" ] } }, "response": [] } ] } ] }, { "name": "Accounts", "item": [ { "name": "Success scenarios", "item": [ { "name": "Create Real account", "event": [ { "listen": "prerequest", "script": { "exec": [ "var json = {", " \"program\": pm.collectionVariables.get(\"program\"),", "// \"user\": \"{{todo: replace with user token from user create api}}\",", "// \"merchant\": \"{{todo: replace with merchant token from webhook after onboarding}}\",", " \"alias\": \"alias of account\"", "}", "", "json = JSON.stringify(json)", " ", "eval(pm.variables.get('fnSetAuth'));", "setAuth('account_create',json);", "pm.variables.set('body', json);" ], "type": "text/javascript" } }, { "listen": "test", "script": { "exec": [ "var jsonData = JSON.parse(pm.request.body.raw);\r", "    console.log(jsonData)\r", "    pm.collectionVariables.set(\"program\", jsonData.program);\r", "pm.globals.set(\"userToken\", jsonData.usertoken);\r", "   console.log(pm.collectionVariables);\r", "var jsonData = pm.response.json();\r", "var accountToken = jsonData.authenticated;pm.collectionVariables.set(\"accountToken\", pm.response.json().data.token);  \r", "var programcode = jsonData.authenticated;pm.collectionVariables.set(\"programcode\", pm.response.json().data.program);\r", "var balanceToken = jsonData.authenticated;pm.collectionVariables.set(\"balanceToken\", pm.response.json().data.balances[0].token);\r", "" ], "type": "text/javascript" } } ], "protocolProfileBehavior": { "strictSSL": false }, "request": { "method": "POST", "header": [ { "key": "Content-Type", "name": "Content-Type", "value": "application/x-www-form-urlencoded", "type": "text", "disabled": true } ], "body": { "mode": "raw", "raw": "{{body}}", "options": { "raw": { "language": "json" } } }, "url": { "raw": "{{API_GATEWAY}}/v2/accounts", "host": [ "{{API_GATEWAY}}" ], "path": [ "v2", "accounts" ] } }, "response": [] }, { "name": "Create Virtual account", "event": [ { "listen": "prerequest", "script": { "exec": [ "", "var json = {", " \"program\": pm.collectionVariables.get(\"program\"), ", "// \"user\": \"{{todo: replace with user token from user create api}}\",", "// \"merchant\": \"{{todo: replace with merchant token from webhook after onboarding}}\",", " \"main\": pm.collectionVariables.get(\"accountToken\"), //token from account creation will be used or you can replace it with other account token real account", "}", "json = JSON.stringify(json)", " ", "eval(pm.variables.get('fnSetAuth'));", "setAuth('account_create',json);", "pm.variables.set('body', json);" ], "type": "text/javascript" } }, { "listen": "test", "script": { "exec": [ "var jsonData = pm.response.json();\r", "var accountToken = jsonData.authenticated;\r", "pm.collectionVariables.set(\"accountToken\", pm.response.json().data.token)\r", "var programcode = jsonData.authenticated;\r", "pm.collectionVariables.set(\"programcode\", pm.response.json().data.program)\r", "" ], "type": "text/javascript" } } ], "protocolProfileBehavior": { "strictSSL": false }, "request": { "method": "POST", "header": [ { "key": "Content-Type", "name": "Content-Type", "value": "application/x-www-form-urlencoded", "type": "text", "disabled": true } ], "body": { "mode": "raw", "raw": "{{body}}", "options": { "raw": { "language": "json" } } }, "url": { "raw": "{{API_GATEWAY}}/v2/accounts", "host": [ "{{API_GATEWAY}}" ], "path": [ "v2", "accounts" ] } }, "response": [] }, { "name": "Change account status", "event": [ { "listen": "prerequest", "script": { "exec": [ "var json = {", " \"status\": \"blocked\"", "}", "json = JSON.stringify(json)", "eval(pm.variables.get('fnSetAuth'));", "setAuth('account_status', json);", "pm.variables.set('body', json);", "", "" ], "type": "text/javascript" } } ], "protocolProfileBehavior": { "strictSSL": false }, "request": { "method": "PUT", "header": [ { "key": "Content-Type", "name": "Content-Type", "value": "application/x-www-form-urlencoded", "type": "text", "disabled": true } ], "body": { "mode": "raw", "raw": "{\r\n \"status\": \"blocked\"\r\n}", "options": { "raw": { "language": "json" } } }, "url": { "raw": "{{API_GATEWAY}}/v2/accounts/{{accountToken}}/status", "host": [ "{{API_GATEWAY}}" ], "path": [ "v2", "accounts", "{{accountToken}}", "status" ], "query": [ { "key": "account", "value": "4fc4ec90-1b02-4c7f-9e74-0d210fd1df66", "disabled": true } ] } }, "response": [] }, { "name": "Terminate Account", "event": [ { "listen": "prerequest", "script": { "exec": [ "eval(pm.variables.get('fnSetAuth'));", "setAuth('account_terminate');" ], "type": "text/javascript" } } ], "protocolProfileBehavior": { "strictSSL": false }, "request": { "method": "DELETE", "header": [ { "key": "Content-Type", "name": "Content-Type", "value": "application/x-www-form-urlencoded", "type": "text" } ], "url": { "raw": "{{API_GATEWAY}}/v2/accounts/{{accountToken}}", "host": [ "{{API_GATEWAY}}" ], "path": [ "v2", "accounts", "{{accountToken}}" ] } }, "response": [] }, { "name": "Get Account List", "event": [ { "listen": "prerequest", "script": { "exec": [ "eval(pm.variables.get('fnSetAuth'));", "setAuth('accounts_list');" ], "type": "text/javascript" } } ], "protocolProfileBehavior": { "strictSSL": false }, "request": { "method": "GET", "header": [ { "key": "Content-Type", "name": "Content-Type", "value": "application/x-www-form-urlencoded", "type": "text", "disabled": true }, { "key": "merchant", "value": "ae65dd87-ad62-4d50-8ba0-0740f33a62fd", "type": "text", "disabled": true }, { "key": "user", "value": "", "type": "text", "disabled": true }, { "key": "program", "value": "wallet_usd", "type": "text", "disabled": true } ], "url": { "raw": "{{API_GATEWAY}}/v2/accounts/1/10", "host": [ "{{API_GATEWAY}}" ], "path": [ "v2", "accounts", "1", "10" ], "query": [ { "key": "merchant", "value": "{uuid}", "disabled": true }, { "key": "user", "value": "{uuid}", "disabled": true }, { "key": "program", "value": "{code}", "disabled": true }, { "key": "page", "value": "1", "disabled": true }, { "key": "limit", "value": "1", "disabled": true } ] } }, "response": [] }, { "name": "Get Account Details", "event": [ { "listen": "prerequest", "script": { "exec": [ "eval(pm.variables.get('fnSetAuth'));", "setAuth('account_details');" ], "type": "text/javascript" } } ], "protocolProfileBehavior": { "strictSSL": false }, "request": { "method": "GET", "header": [ { "key": "Content-Type", "name": "Content-Type", "value": "application/x-www-form-urlencoded", "type": "text" } ], "url": { "raw": "{{API_GATEWAY}}/v2/accounts/{{accountToken}}", "host": [ "{{API_GATEWAY}}" ], "path": [ "v2", "accounts", "{{accountToken}}" ] } }, "response": [] } ] }, { "name": "Negative scenarios", "item": [ { "name": "Create account without merchant or/and user fields", "event": [ { "listen": "prerequest", "script": { "exec": [ "var json = {", " \"program\": pm.collectionVariables.get(\"program\"),", " \"skip_iban_generation\": false,", " \"alias\": \"alias of account\"", "}", "console.log(222,pm.collectionVariables)", "json = JSON.stringify(json)", " ", "eval(pm.variables.get('fnSetAuth'));", "setAuth('account_create',json);", "pm.variables.set('body', json);" ], "type": "text/javascript" } }, { "listen": "test", "script": { "exec": [ "var jsonData = JSON.parse(pm.request.body.raw);\r", "    console.log(jsonData)\r", "    pm.collectionVariables.set(\"program\", jsonData.program);\r", "pm.globals.set(\"userToken\", jsonData.usertoken);\r", "   console.log(pm.collectionVariables);\r", "var jsonData = pm.response.json();\r", "var accountToken = jsonData.authenticated;pm.collectionVariables.set(\"accountToken\", pm.response.json().data.token);  \r", "var programcode = jsonData.authenticated;pm.collectionVariables.set(\"programcode\", pm.response.json().data.program);\r", "var balanceToken = jsonData.authenticated;pm.collectionVariables.set(\"balanceToken\", pm.response.json().data.balances[0].token);\r", "" ], "type": "text/javascript" } } ], "protocolProfileBehavior": { "strictSSL": false }, "request": { "method": "POST", "header": [ { "key": "Content-Type", "name": "Content-Type", "value": "application/x-www-form-urlencoded", "type": "text", "disabled": true } ], "body": { "mode": "raw", "raw": "{{body}}", "options": { "raw": { "language": "json" } } }, "url": { "raw": "{{API_GATEWAY}}/v2/accounts", "host": [ "{{API_GATEWAY}}" ], "path": [ "v2", "accounts" ] } }, "response": [] }, { "name": "Create account with invalid user/merchant tokens", "event": [ { "listen": "prerequest", "script": { "exec": [ "", "var json = {", " \"program\": pm.collectionVariables.get(\"programcode\"),", " \"merchant\": \"d42bab03-f94f-4872-a22e-6f9008d353f\",", " \"main\": pm.collectionVariables.get(\"accountToken\"), ", " \"user\": \"801171e1fea3a95a72d5ce652dc41afc0a06f276b547ee9\"", "}", "json = JSON.stringify(json)", " ", "eval(pm.variables.get('fnSetAuth'));", "setAuth('account_create',json);", "pm.variables.set('body', json);" ], "type": "text/javascript" } }, { "listen": "test", "script": { "exec": [ "var jsonData = pm.response.json();\r", "var accountToken = jsonData.authenticated;\r", "pm.collectionVariables.set(\"accountToken\", pm.response.json().data.token)\r", "var programcode = jsonData.authenticated;\r", "pm.collectionVariables.set(\"programcode\", pm.response.json().data.program)\r", "" ], "type": "text/javascript" } } ], "protocolProfileBehavior": { "strictSSL": false }, "request": { "method": "POST", "header": [ { "key": "Content-Type", "name": "Content-Type", "value": "application/x-www-form-urlencoded", "type": "text", "disabled": true } ], "body": { "mode": "raw", "raw": "{{body}}", "options": { "raw": { "language": "json" } } }, "url": { "raw": "{{API_GATEWAY}}/v2/accounts", "host": [ "{{API_GATEWAY}}" ], "path": [ "v2", "accounts" ] } }, "response": [] }, { "name": "Terminate account with invalid account token", "event": [ { "listen": "prerequest", "script": { "exec": [ "eval(pm.variables.get('fnSetAuth'));", "setAuth('account_terminate');" ], "type": "text/javascript" } } ], "protocolProfileBehavior": { "strictSSL": false }, "request": { "method": "DELETE", "header": [ { "key": "Content-Type", "name": "Content-Type", "value": "application/x-www-form-urlencoded", "type": "text" } ], "url": { "raw": "{{API_GATEWAY}}/v2/accounts/883551c0-03ac-4df6-934e-f08b24df", "host": [ "{{API_GATEWAY}}" ], "path": [ "v2", "accounts", "883551c0-03ac-4df6-934e-f08b24df" ] } }, "response": [] }, { "name": "Get account details with invalid account token", "event": [ { "listen": "prerequest", "script": { "exec": [ "eval(pm.variables.get('fnSetAuth'));", "setAuth('account_details');" ], "type": "text/javascript" } } ], "protocolProfileBehavior": { "strictSSL": false }, "request": { "method": "GET", "header": [ { "key": "Content-Type", "name": "Content-Type", "value": "application/x-www-form-urlencoded", "type": "text" } ], "url": { "raw": "{{API_GATEWAY}}/v2/accounts/883551c0-03ac-4df6-934e-f08b24df", "host": [ "{{API_GATEWAY}}" ], "path": [ "v2", "accounts", "883551c0-03ac-4df6-934e-f08b24df" ] } }, "response": [] } ] } ] }, { "name": "Cards", "item": [ { "name": "Success scenarios", "item": [ { "name": "Create Virtual card", "event": [ { "listen": "prerequest", "script": { "exec": [ "var json = {", " \"account\": pm.collectionVariables.get(\"accountToken\"), // {{todo: change with account token or execute account creation before}}", " \"emboss_name\": \"Nikoleta\",", " \"emboss_name_line4\": \"Nikoleta Ltd\",", " \"fulfil1\": \"123456\",", " \"fulfil2\": \"789123\",", " \"thermal_line1\": \"123456\",", " \"thermal_line2\": \"789123\",", " \"active\": true,", " \"pin\": \"1234\",", " \"type\": \"virtual\",", " \"first_name\": \"Николета\",", " \"last_name\": \"Николета\",", " \"alias\": \"Shopping Card\",", " \"delivery_details\": {", " \"city\": \"Sofia\",", " \"country\": \"BG\",", " \"county\": \"Sofia Grad\",", " \"zip\": \"1407\",", " \"address1\": \"James Bouchier 76A\",", " \"method\": \"0\",", " \"code\": \"plastic\",", " \"mobile_phone\": \"+999\"", " },", " \"three_domain_enrolment\": {", " \"otp_sms\": \"+3590000000\",", " \"biometric\": true", " }", "}", " ", "json = JSON.stringify(json)", "", "eval(pm.variables.get('fnSetAuth'));", "setAuth('card_create',json);", "pm.variables.set('body', json);" ], "type": "text/javascript" } }, { "listen": "test", "script": { "exec": [ "var jsonData = pm.response.json();\r", "var cardToken = jsonData.authenticated;\r", "pm.collectionVariables.set(\"cardToken\", pm.response.json().data.token)\r", "\r", "\r", "" ], "type": "text/javascript" } } ], "protocolProfileBehavior": { "strictSSL": false }, "request": { "method": "POST", "header": [], "body": { "mode": "raw", "raw": "{{body}}", "options": { "raw": { "language": "json" } } }, "url": { "raw": "{{API_GATEWAY}}/v2/cards", "host": [ "{{API_GATEWAY}}" ], "path": [ "v2", "cards" ] } }, "response": [] }, { "name": "Create Plastic Card", "event": [ { "listen": "prerequest", "script": { "exec": [ "var json = {", " \"account\": pm.collectionVariables.get(\"accountToken\"), // {{todo: change with account token or execute account creation before}}", " \"emboss_name\": \"Nikoleta\",", " \"emboss_name_line4\": \"Nikoleta Ltd\",", " \"fulfil1\": \"123456\",", " \"fulfil2\": \"789123\",", " \"thermal_line1\": \"123456\",", " \"thermal_line2\": \"789123\",", " \"active\": true,", " \"pin\": \"1234\",", " \"type\": \"plastic\",", " \"first_name\": \"Николета\",", " \"last_name\": \"Николета\",", " \"alias\": \"Shopping Card\",", " \"delivery_details\": {", " \"city\": \"Sofia\",", " \"country\": \"BG\",", " \"county\": \"Sofia Grad\",", " \"zip\": \"1407\",", " \"address1\": \"James Bouchier 76A\",", " \"method\": \"0\",", " \"code\": \"plastic\",", " \"mobile_phone\": \"+999\"", " },", " \"three_domain_enrolment\": {", " \"otp_sms\": \"+3590000000\",", " \"biometric\": true", " }", "}", " ", "", " ", "json = JSON.stringify(json)", "", "eval(pm.variables.get('fnSetAuth'));", "setAuth('card_create',json);", "pm.variables.set('body', json);" ], "type": "text/javascript" } }, { "listen": "test", "script": { "exec": [ "var jsonData = pm.response.json();\r", "var cardToken = jsonData.authenticated;\r", "pm.collectionVariables.set(\"cardToken\", pm.response.json().data.token)\r", "\r", "\r", "" ], "type": "text/javascript" } } ], "protocolProfileBehavior": { "strictSSL": false }, "request": { "method": "POST", "header": [], "body": { "mode": "raw", "raw": "{{body}}", "options": { "raw": { "language": "json" } } }, "url": { "raw": "{{API_GATEWAY}}/v2/cards", "host": [ "{{API_GATEWAY}}" ], "path": [ "v2", "cards" ] } }, "response": [] }, { "name": "Create non-personalized virtual card", "event": [ { "listen": "prerequest", "script": { "exec": [ "var json = {", " \"program\": pm.collectionVariables.get('program'), //{{todo set the program on collection level or overwrite it here}}", " \"type\": \"virtual\",", "", "}", " ", "json = JSON.stringify(json)", "", "eval(pm.variables.get('fnSetAuth'));", "setAuth('card_create',json);", "pm.variables.set('body', json);" ], "type": "text/javascript" } }, { "listen": "test", "script": { "exec": [ "var jsonData = pm.response.json();\r", "var cardToken = jsonData.authenticated;\r", "pm.collectionVariables.set(\"cardToken\", pm.response.json().data.token)\r", "\r", "\r", "" ], "type": "text/javascript" } } ], "protocolProfileBehavior": { "strictSSL": false }, "request": { "method": "POST", "header": [], "body": { "mode": "raw", "raw": "{{body}}", "options": { "raw": { "language": "json" } } }, "url": { "raw": "{{API_GATEWAY}}/v2/cards", "host": [ "{{API_GATEWAY}}" ], "path": [ "v2", "cards" ] } }, "response": [] }, { "name": "Create non-personalized plastic card", "event": [ { "listen": "prerequest", "script": { "exec": [ "var json = {", " \"emboss_name\": \"John Doe\",", " \"program\": pm.collectionVariables.get('program'), //{{todo set the program on collection level or overwrite it here}}", " \"type\": \"plastic\",", " \"delivery_details\": {", " \"city\": \"Sofia\",", " \"country\": \"BG\",", " \"county\": \"Sofia Grad\",", " \"zip\": \"1407\",", " \"address1\": \"James Bouchier 76A\",", " \"method\": \"0\",", " \"code\": \"plastic\",", " \"mobile_phone\": \"+999\"", " },", "", "", "}", " ", "json = JSON.stringify(json)", "", "eval(pm.variables.get('fnSetAuth'));", "setAuth('card_create',json);", "pm.variables.set('body', json);" ], "type": "text/javascript" } }, { "listen": "test", "script": { "exec": [ "var jsonData = pm.response.json();\r", "var cardToken = jsonData.authenticated;\r", "pm.collectionVariables.set(\"cardToken\", pm.response.json().data.token)\r", "\r", "\r", "" ], "type": "text/javascript" } } ], "protocolProfileBehavior": { "strictSSL": false }, "request": { "method": "POST", "header": [], "body": { "mode": "raw", "raw": "{{body}}", "options": { "raw": { "language": "json" } } }, "url": { "raw": "{{API_GATEWAY}}/v2/cards", "host": [ "{{API_GATEWAY}}" ], "path": [ "v2", "cards" ] } }, "response": [] }, { "name": "Cards List", "event": [ { "listen": "prerequest", "script": { "exec": [ "eval(pm.variables.get('fnSetAuth'));", "setAuth('cards_list');" ], "type": "text/javascript" } } ], "request": { "method": "GET", "header": [], "url": { "raw": "{{API_GATEWAY}}/v2/cards/1/10", "host": [ "{{API_GATEWAY}}" ], "path": [ "v2", "cards", "1", "10" ] } }, "response": [] }, { "name": "Card Details", "event": [ { "listen": "prerequest", "script": { "exec": [ "eval(pm.variables.get('fnSetAuth'));", "setAuth('card_details');" ], "type": "text/javascript" } } ], "request": { "method": "GET", "header": [], "url": { "raw": "{{API_GATEWAY}}/v2/cards/{{cardToken}}", "host": [ "{{API_GATEWAY}}" ], "path": [ "v2", "cards", "{{cardToken}}" ] } }, "response": [] }, { "name": "Card Number First Half", "event": [ { "listen": "prerequest", "script": { "exec": [ "eval(pm.variables.get('fnSetAuth'));", "setAuth('card_number');" ], "type": "text/javascript" } } ], "request": { "method": "GET", "header": [], "url": { "raw": "{{API_GATEWAY}}/v2/cards/{{cardToken}}/first-half", "host": [ "{{API_GATEWAY}}" ], "path": [ "v2", "cards", "{{cardToken}}", "first-half" ] } }, "response": [] }, { "name": "Card Number Second Half", "event": [ { "listen": "prerequest", "script": { "exec": [ "eval(pm.variables.get('fnSetAuth'));", "setAuth('card_number');" ], "type": "text/javascript" } } ], "request": { "method": "GET", "header": [], "url": { "raw": "{{API_GATEWAY}}/v2/cards/{{cardToken}}/second-half", "host": [ "{{API_GATEWAY}}" ], "path": [ "v2", "cards", "{{cardToken}}", "second-half" ] } }, "response": [] }, { "name": "Get Pin", "event": [ { "listen": "prerequest", "script": { "exec": [ "eval(pm.variables.get('fnSetAuth'));", "setAuth('card_retrieve_pin');" ], "type": "text/javascript" } } ], "protocolProfileBehavior": { "strictSSL": false }, "request": { "method": "GET", "header": [], "url": { "raw": "{{API_GATEWAY}}/v2/cards/{{cardToken}}/pin", "host": [ "{{API_GATEWAY}}" ], "path": [ "v2", "cards", "{{cardToken}}", "pin" ] } }, "response": [] }, { "name": "Send card pin", "event": [ { "listen": "prerequest", "script": { "exec": [ " eval(pm.variables.get('fnSetAuth'));", "setAuth('card_send_pin');" ], "type": "text/javascript" } } ], "protocolProfileBehavior": { "strictSSL": false }, "request": { "method": "POST", "header": [], "url": { "raw": "{{API_GATEWAY}}/v2/cards/{{cardToken}}/pin/send", "host": [ "{{API_GATEWAY}}" ], "path": [ "v2", "cards", "{{cardToken}}", "pin", "send" ] } }, "response": [] }, { "name": "Reset card pin", "event": [ { "listen": "prerequest", "script": { "exec": [ "var json = {", "}", "", "json = JSON.stringify(json)", " ", "eval(pm.variables.get('fnSetAuth'));", "setAuth('card_reset_pin',json);", "pm.variables.set('body', json);" ], "type": "text/javascript" } } ], "protocolProfileBehavior": { "strictSSL": false }, "request": { "method": "DELETE", "header": [], "body": { "mode": "raw", "raw": "{{body}}\n", "options": { "raw": { "language": "json" } } }, "url": { "raw": "{{API_GATEWAY}}/v2/cards/{{cardToken}}/pin/reset", "host": [ "{{API_GATEWAY}}" ], "path": [ "v2", "cards", "{{cardToken}}", "pin", "reset" ] } }, "response": [] }, { "name": "Convert card", "event": [ { "listen": "prerequest", "script": { "exec": [ "eval(pm.variables.get('fnSetAuth'));", "setAuth('card_convert');" ], "type": "text/javascript" } } ], "protocolProfileBehavior": { "strictSSL": false }, "request": { "method": "PUT", "header": [], "url": { "raw": "{{API_GATEWAY}}/v2/cards/{{cardToken}}/convert", "host": [ "{{API_GATEWAY}}" ], "path": [ "v2", "cards", "{{cardToken}}", "convert" ] } }, "response": [] }, { "name": "Activate plastic card", "event": [ { "listen": "prerequest", "script": { "exec": [ "eval(pm.variables.get('fnSetAuth'));", "setAuth('card_activate');" ], "type": "text/javascript" } } ], "protocolProfileBehavior": { "strictSSL": false }, "request": { "method": "PUT", "header": [], "body": { "mode": "raw", "raw": "", "options": { "raw": { "language": "json" } } }, "url": { "raw": "{{API_GATEWAY}}/v2/cards/{{cardToken}}/activate", "host": [ "{{API_GATEWAY}}" ], "path": [ "v2", "cards", "{{cardToken}}", "activate" ] } }, "response": [] }, { "name": "Change card groups", "event": [ { "listen": "prerequest", "script": { "exec": [ "var json = {", " \"usage\": \"usage_group_1\", //{{todo: change with group for your case}}", " \"fees\": \"fee_group_1\", //{{todo: change with group for your case}}", " \"schedule_fees\": \"schedule_fee_group_1\", //{{todo: change with group for your case}}", " \"web_service_fees\": \"web_services_fee_group_1\", //{{todo: change with group for your case}}", " \"limits\": \"limits_group_1\", //{{todo: change with group for your case}}", " \"linkage\": \"linkage_group_1\", //{{todo: change with group for your case}}", " \"mcc\": \"mcc_black_group_1\" //{{todo: change with group for your case}}", "}", " ", "json = JSON.stringify(json)", "", "eval(pm.variables.get('fnSetAuth'));", "setAuth('card_groups',json);", "pm.variables.set('body', json);" ], "type": "text/javascript" } }, { "listen": "test", "script": { "exec": [ "" ], "type": "text/javascript" } } ], "protocolProfileBehavior": { "strictSSL": false }, "request": { "method": "PUT", "header": [], "body": { "mode": "raw", "raw": "{{body}}", "options": { "raw": { "language": "json" } } }, "url": { "raw": "{{API_GATEWAY}}/v2/cards/{{cardToken}}/groups", "host": [ "{{API_GATEWAY}}" ], "path": [ "v2", "cards", "{{cardToken}}", "groups" ] } }, "response": [] }, { "name": "Change card status to Inactive", "event": [ { "listen": "prerequest", "script": { "exec": [ "var json = {", " \"status\": \"inactive\" ", "}", "", "json = JSON.stringify(json)", "", "eval(pm.variables.get('fnSetAuth'));", "setAuth('card_status',json);", "pm.variables.set('body', json);" ], "type": "text/javascript" } } ], "protocolProfileBehavior": { "strictSSL": false }, "request": { "method": "PUT", "header": [], "body": { "mode": "raw", "raw": "{{body}}", "options": { "raw": { "language": "json" } } }, "url": { "raw": "{{API_GATEWAY}}/v2/cards/{{cardToken}}/status", "host": [ "{{API_GATEWAY}}" ], "path": [ "v2", "cards", "{{cardToken}}", "status" ] } }, "response": [] }, { "name": "Change card status to active", "event": [ { "listen": "prerequest", "script": { "exec": [ "var json = {", " \"status\": \"active\" ", "}", " ", "json = JSON.stringify(json)", "", "eval(pm.variables.get('fnSetAuth'));", "setAuth('card_status',json);", "pm.variables.set('body', json);" ], "type": "text/javascript" } } ], "protocolProfileBehavior": { "strictSSL": false }, "request": { "method": "PUT", "header": [], "body": { "mode": "raw", "raw": "{{body}}", "options": { "raw": { "language": "json" } } }, "url": { "raw": "{{API_GATEWAY}}/v2/cards/{{cardToken}}/status", "host": [ "{{API_GATEWAY}}" ], "path": [ "v2", "cards", "{{cardToken}}", "status" ] } }, "response": [] }, { "name": "Terminate card - Virtual/Plastic", "event": [ { "listen": "prerequest", "script": { "exec": [ "eval(pm.variables.get('fnSetAuth'));", "setAuth('card_terminate');" ], "type": "text/javascript" } } ], "protocolProfileBehavior": { "strictSSL": false }, "request": { "method": "DELETE", "header": [], "url": { "raw": "{{API_GATEWAY}}/v2/cards/{{cardToken}}", "host": [ "{{API_GATEWAY}}" ], "path": [ "v2", "cards", "{{cardToken}}" ] } }, "response": [] }, { "name": "Card 3d enable", "event": [ { "listen": "prerequest", "script": { "exec": [ "var json = {", " \"otp_sms\": \"+3590000000\",", " \"biometric\": true", "}", "", "json = JSON.stringify(json)", " ", "eval(pm.variables.get('fnSetAuth'));", "setAuth('card_3ds_enrol',json);", "pm.variables.set('body', json);" ], "type": "text/javascript" } } ], "protocolProfileBehavior": { "strictSSL": false }, "request": { "method": "POST", "header": [], "body": { "mode": "raw", "raw": "{{body}}", "options": { "raw": { "language": "json" } } }, "url": { "raw": "{{API_GATEWAY}}/v2/cards/{{cardToken}}/3ds", "host": [ "{{API_GATEWAY}}" ], "path": [ "v2", "cards", "{{cardToken}}", "3ds" ] } }, "response": [] }, { "name": "Card 3d update", "event": [ { "listen": "prerequest", "script": { "exec": [ "var json = {", " \"otp_sms\": \"+3590000000\",", " \"biometric\": true", "}", "", "json = JSON.stringify(json)", " ", "eval(pm.variables.get('fnSetAuth'));", "setAuth('card_3ds_update',json);", "pm.variables.set('body', json);" ], "type": "text/javascript" } } ], "protocolProfileBehavior": { "strictSSL": false }, "request": { "method": "PUT", "header": [], "body": { "mode": "raw", "raw": "{{body}}", "options": { "raw": { "language": "json" } } }, "url": { "raw": "{{API_GATEWAY}}/v2/cards/{{cardToken}}/3ds", "host": [ "{{API_GATEWAY}}" ], "path": [ "v2", "cards", "{{cardToken}}", "3ds" ] } }, "response": [] }, { "name": "Card 3d remove", "event": [ { "listen": "prerequest", "script": { "exec": [ "eval(pm.variables.get('fnSetAuth'));", "setAuth('card_3ds_remove');", "" ], "type": "text/javascript" } } ], "protocolProfileBehavior": { "strictSSL": false }, "request": { "method": "DELETE", "header": [], "url": { "raw": "{{API_GATEWAY}}/v2/cards/{{cardToken}}/3ds", "host": [ "{{API_GATEWAY}}" ], "path": [ "v2", "cards", "{{cardToken}}", "3ds" ] } }, "response": [] } ] } ] }, { "name": "Transfers", "item": [ { "name": "External transfers", "item": [ { "name": "External Transfer Iban to Iban", "event": [ { "listen": "prerequest", "script": { "exec": [ "var json = {\r", "  \"amount\": 1,\r", "  \"currency\": \"EUR\",\r", "  \"reference\": \"Payment for goods\",\r", "  \"reference2\": \"Items 1,2,3\",\r", "  \"reference3\": \"Additional Info\",\r", "  \"reference4\": \"Additional Info\",\r", "  \"origin_of_funds\": \"dasds\",\r", "  \"description\": \"Merchant 123\",\r", "  \"is_instant\": false,\r", "  \"debtor\": {\r", " \"iban\": \"{{todo: replace with iban from account}}\", \r", "    \"address\": \"BG, Sofia, James Bouchier 76 A\",\r", "    \"name\": \"John Doe\",\r", "  },\r", "  \"creditor\": {\r", "    \"iban\": \"BG27UBBS80021095919740\",\r", "    \"address\": \"BG, Sofia, James Bouchier 76 A\",\r", "    \"name\": \"John Doe\",\r", "    \"country\": \"BG\"\r", "  }\r", "} \r", "json = JSON.stringify(json) \r", "eval(pm.variables.get('fnSetAuth'));\r", "setAuth('transfer',json);\r", "pm.variables.set('body', json);" ], "type": "text/javascript" } } ], "protocolProfileBehavior": { "strictSSL": false }, "request": { "method": "POST", "header": [ { "key": "Content-Type", "name": "Content-Type", "value": "application/json", "type": "text" } ], "body": { "mode": "raw", "raw": "{{body}}", "options": { "raw": { "language": "json" } } }, "url": { "raw": "{{API_GATEWAY}}/v2/transfers", "host": [ "{{API_GATEWAY}}" ], "path": [ "v2", "transfers" ] } }, "response": [] }, { "name": "External Trasfer balance to Iban", "event": [ { "listen": "prerequest", "script": { "exec": [ "var json = {\r", "  \"amount\": 10,\r", "  \"currency\": \"EUR\",\r", "//   \"code\": \"string\",\r", "  \"reference\": \"Payment for goods\",\r", "  \"reference2\": \"Items 1,2,3\",\r", "  \"reference3\": \"Additional Info\",\r", "  \"reference4\": \"Additional Info\",\r", "  \"origin_of_funds\": \"dasds\",\r", "  \"description\": \"Merchant 123\",\r", "  \"is_instant\": false,\r", "  \"debtor\": {\r", "  \"balance\": \"f5df7590-0abf-43d8-bf7a-f44afd129f79\",\r", "    \"address\": \"BG, Sofia, James Bouchier 76 A\",\r", "    \"name\": \"John Doe\",\r", "  },\r", "  \"creditor\": {\r", "    \"iban\": \"IT32G0300203280695959743758\",\r", "    \"address\": \"BG, Sofia, James Bouchier 76 A\",\r", "    \"name\": \"John Doe\",\r", "    \"country\": \"BG\"\r", "  }\r", "} \r", "json = JSON.stringify(json) \r", "eval(pm.variables.get('fnSetAuth'));\r", "setAuth('transfer',json);\r", "pm.variables.set('body', json);" ], "type": "text/javascript" } } ], "protocolProfileBehavior": { "strictSSL": false }, "request": { "method": "POST", "header": [ { "key": "Content-Type", "name": "Content-Type", "value": "application/json", "type": "text" } ], "body": { "mode": "raw", "raw": "{{body}}", "options": { "raw": { "language": "json" } } }, "url": { "raw": "{{PAYOO}}/v2/transfers", "host": [ "{{PAYOO}}" ], "path": [ "v2", "transfers" ] } }, "response": [] }, { "name": "External Transfer Sort code/account number to Sort code/account number", "event": [ { "listen": "prerequest", "script": { "exec": [ "var json = {\r", "  \"amount\": 1,\r", "  \"currency\": \"GBP\",\r", "  \"reference\": \"Payment for goods\",\r", "  \"reference2\": \"Items 1,2,3\",\r", "  \"reference3\": \"Additional Info\",\r", "  \"reference4\": \"Additional Info\",\r", "  \"origin_of_funds\": \"dasds\",\r", "  \"description\": \"Merchant 123\",\r", "  \"is_instant\": false,\r", "  \"debtor\": {\r", "    \"sort_code\": \"040738\",\r", "    \"account_number\": \"{{todo: replace with account number from account}}\",\r", "    \"address\": \"BG, Sofia, James Bouchier 76 A\",\r", "    \"name\": \"John Doe\",\r", "  },\r", "  \"creditor\": {\r", "   \"sort_code\": \"202015\",\r", "    \"account_number\": \"55555555\",\r", "    \"address\": \"BG, Sofia, James Bouchier 76 A\",\r", "    \"name\": \"John Doe\",\r", "  }\r", "} \r", "\r", "json = JSON.stringify(json) \r", "eval(pm.variables.get('fnSetAuth'));\r", "setAuth('transfer',json);\r", "pm.variables.set('body', json);" ], "type": "text/javascript" } } ], "protocolProfileBehavior": { "strictSSL": false }, "request": { "method": "POST", "header": [ { "key": "Content-Type", "name": "Content-Type", "value": "application/json", "type": "text" } ], "body": { "mode": "raw", "raw": "{{body}}", "options": { "raw": { "language": "json" } } }, "url": { "raw": "{{PAYOO}}/v2/transfers", "host": [ "{{PAYOO}}" ], "path": [ "v2", "transfers" ] } }, "response": [] } ] }, { "name": "Internal transfers", "item": [ { "name": "Transfer Sort code/account number to balance", "event": [ { "listen": "prerequest", "script": { "exec": [ "var json = {\r", "  \"amount\": 1,\r", "  \"currency\": \"GBP\",\r", "  \"reference\": \"Payment for goods\",\r", "  \"reference2\": \"Items 1,2,3\",\r", "  \"reference3\": \"Additional Info\",\r", "  \"reference4\": \"Additional Info\",\r", "  \"origin_of_funds\": \"dasds\",\r", "  \"description\": \"Merchant 123\",\r", "  \"is_instant\": false,\r", "  \"debtor\": {\r", "    \"sort_code\": \"040738\",\r", "    \"account_number\": \"{{todo: replace with account number from account}}\",\r", "    \"address\": \"BG, Sofia, James Bouchier 76 A\",\r", "    \"name\": \"John Doe\",\r", "  },\r", "  \"creditor\": {\r", "    \"balance\": \"{{todo: replace with balance of creditor account}}\",\r", "    \"address\": \"BG, Sofia, James Bouchier 76 A\",\r", "    \"name\": \"John Doe\",\r", "  }\r", "} \r", "json = JSON.stringify(json) \r", "eval(pm.variables.get('fnSetAuth'));\r", "setAuth('transfer',json);\r", "pm.variables.set('body', json);" ], "type": "text/javascript" } } ], "protocolProfileBehavior": { "strictSSL": false }, "request": { "method": "POST", "header": [ { "key": "Content-Type", "name": "Content-Type", "value": "application/json", "type": "text" } ], "body": { "mode": "raw", "raw": "{{body}}", "options": { "raw": { "language": "json" } } }, "url": { "raw": "{{PAYOO}}/v2/transfers", "host": [ "{{PAYOO}}" ], "path": [ "v2", "transfers" ] } }, "response": [] }, { "name": "Transfer Sort code/account number to Iban", "event": [ { "listen": "prerequest", "script": { "exec": [ "var json = {\r", "  \"amount\": 0.10,\r", "  \"currency\": \"GBP\",\r", "  \"reference\": \"Payment for goods\",\r", "  \"reference2\": \"Items 1,2,3\",\r", "  \"reference3\": \"Additional Info\",\r", "  \"reference4\": \"Additional Info\",\r", "  \"origin_of_funds\": \"dasds\",\r", "  \"description\": \"Merchant 123\",\r", "  \"is_instant\": false,\r", "  \"debtor\": {\r", "    \"sort_code\": \"040738\",\r", "    \"account_number\": \"{{todo: replace with account number from account}}\",\r", "    \"address\": \"BG, Sofia, James Bouchier 76 A\",\r", "    \"name\": \"John Doe\",\r", "  },\r", "  \"creditor\": {\r", "    \"iban\": \"{{todo: replace with IBAN creditor from account}}\",\r", "    \"address\": \"BG, Sofia, James Bouchier 76 A\",\r", "    \"name\": \"John Doe\",\r", "  }\r", "} \r", "json = JSON.stringify(json) \r", "eval(pm.variables.get('fnSetAuth'));\r", "setAuth('transfer',json);\r", "pm.variables.set('body', json);" ], "type": "text/javascript" } } ], "protocolProfileBehavior": { "strictSSL": false }, "request": { "method": "POST", "header": [ { "key": "Content-Type", "name": "Content-Type", "value": "application/json", "type": "text" } ], "body": { "mode": "raw", "raw": "{{body}}", "options": { "raw": { "language": "json" } } }, "url": { "raw": "{{PAYOO}}/v2/transfers", "host": [ "{{PAYOO}}" ], "path": [ "v2", "transfers" ] } }, "response": [] }, { "name": "Transfer Iban to balance", "event": [ { "listen": "prerequest", "script": { "exec": [ "var json = {\r", "  \"amount\": 2,\r", "  \"currency\": \"BGN\",\r", "  \"reference\": \"Payment for goods\",\r", "  \"reference2\": \"Items 1,2,3\",\r", "  \"reference3\": \"Additional Info\",\r", "  \"reference4\": \"Additional Info\",\r", "  \"origin_of_funds\": \"dasds\",\r", "  \"description\": \"Merchant 123\",\r", "  \"is_instant\": false,\r", "  \"debtor\": {\r", " \"iban\": \"{{todo: replace with debor IBAN from debtor account}}\",\r", "    \"address\": \"BG, Sofia, James Bouchier 76 A\",\r", "    \"name\": \"John Doe\",\r", "  },\r", "  \"creditor\": {\r", "    \"balance\": \"{{todo: replace with balance from creditor account}}\",\r", "    \"address\": \"BG, Sofia, James Bouchier 76 A\",\r", "    \"name\": \"John Doe\",\r", "    \"country\": \"BG\"\r", "  }\r", "} \r", "json = JSON.stringify(json) \r", "eval(pm.variables.get('fnSetAuth'));\r", "setAuth('transfer',json);\r", "pm.variables.set('body', json);" ], "type": "text/javascript" } } ], "protocolProfileBehavior": { "strictSSL": false }, "request": { "method": "POST", "header": [ { "key": "Content-Type", "name": "Content-Type", "value": "application/json", "type": "text" } ], "body": { "mode": "raw", "raw": "{{body}}", "options": { "raw": { "language": "json" } } }, "url": { "raw": "{{PAYOO}}/v2/transfers", "host": [ "{{PAYOO}}" ], "path": [ "v2", "transfers" ] } }, "response": [] }, { "name": "Transfer Iban to external_identifier", "event": [ { "listen": "prerequest", "script": { "exec": [ "var json = {\r", "  \"amount\": 5,\r", "  \"currency\": \"BGN\",\r", "  \"reference\": \"Payment for goods\",\r", "  \"reference2\": \"Items 1,2,3\",\r", "  \"reference3\": \"Additional Info\",\r", "  \"reference4\": \"Additional Info\",\r", "  \"origin_of_funds\": \"dasds\",\r", "  \"description\": \"Merchant 123\",\r", "  \"is_instant\": false,\r", "  \"debtor\": {\r", " \"iban\": \"BG39PATC40021972336789\",\r", "    \"address\": \"BG, Sofia, James Bouchier 76 A\",\r", "    \"name\": \"John Doe\",\r", "  },\r", "  \"creditor\": {\r", "    \"external_identifier\": \"107338867\",\r", "    \"address\": \"BG, Sofia, James Bouchier 76 A\",\r", "    \"name\": \"John Doe\",\r", "    \"country\": \"BG\"\r", "  }\r", "} \r", "json = JSON.stringify(json) \r", "eval(pm.variables.get('fnSetAuth'));\r", "setAuth('transfer',json);\r", "pm.variables.set('body', json);" ], "type": "text/javascript" } } ], "protocolProfileBehavior": { "strictSSL": false }, "request": { "method": "POST", "header": [ { "key": "Content-Type", "name": "Content-Type", "value": "application/json", "type": "text" } ], "body": { "mode": "raw", "raw": "{{body}}", "options": { "raw": { "language": "json" } } }, "url": { "raw": "{{PAYOO}}/v2/transfers", "host": [ "{{PAYOO}}" ], "path": [ "v2", "transfers" ] } }, "response": [] }, { "name": "Transfer Iban to iban", "event": [ { "listen": "prerequest", "script": { "exec": [ "var json = {\r", "  \"amount\": 10.00,\r", "  \"currency\": \"GBP\",\r", "  \"reference\": \"Payment for goods\",\r", "  \"reference2\": \"Items 1,2,3\",\r", "  \"reference3\": \"Additional Info\",\r", "  \"reference4\": \"Additional Info\",\r", "  \"origin_of_funds\": \"dasds\",\r", "  \"description\": \"Merchant 123\",\r", "  \"is_instant\": false,\r", "  \"debtor\": {\r", " \"iban\": \"GB59PATC04073800020562\",\r", "    \"address\": \"BG, Sofia, James Bouchier 76 A\",\r", "    \"name\": \"John Doe\",\r", "  },\r", "  \"creditor\": {\r", "    \"iban\": \"BG35PATC40021977670212\",\r", "    \"address\": \"BG, Sofia, James Bouchier 76 A\",\r", "    \"name\": \"John Doe\",\r", "    \"country\": \"BG\"\r", "  }\r", "} \r", "json = JSON.stringify(json) \r", "eval(pm.variables.get('fnSetAuth'));\r", "setAuth('transfer',json);\r", "pm.variables.set('body', json);" ], "type": "text/javascript" } } ], "protocolProfileBehavior": { "strictSSL": false }, "request": { "method": "POST", "header": [ { "key": "Content-Type", "name": "Content-Type", "value": "application/json", "type": "text" } ], "body": { "mode": "raw", "raw": "{{body}}", "options": { "raw": { "language": "json" } } }, "url": { "raw": "{{PAYOO}}/v2/transfers", "host": [ "{{PAYOO}}" ], "path": [ "v2", "transfers" ] } }, "response": [] }, { "name": "Transfer Iban to sort_code/account_number", "event": [ { "listen": "prerequest", "script": { "exec": [ "var json = {\r", "  \"amount\": 2,\r", "  \"currency\": \"BGN\",\r", "  \"reference\": \"Payment for goods\",\r", "  \"reference2\": \"Items 1,2,3\",\r", "  \"reference3\": \"Additional Info\",\r", "  \"reference4\": \"Additional Info\",\r", "  \"origin_of_funds\": \"dasds\",\r", "  \"description\": \"Merchant 123\",\r", "  \"is_instant\": false,\r", "  \"debtor\": {\r", " \"iban\": \"BG39PATC40021972336789\",\r", "    \"address\": \"BG, Sofia, James Bouchier 76 A\",\r", "    \"name\": \"John Doe\",\r", "  },\r", "  \"creditor\": {\r", "    \"sort_code\": \"040738\",\r", "    \"account_number\": \"00020393\",\r", "    \"address\": \"BG, Sofia, James Bouchier 76 A\",\r", "    \"name\": \"John Doe\",\r", "    \"country\": \"BG\"\r", "  }\r", "} \r", "json = JSON.stringify(json) \r", "eval(pm.variables.get('fnSetAuth'));\r", "setAuth('transfer',json);\r", "pm.variables.set('body', json);" ], "type": "text/javascript" } } ], "protocolProfileBehavior": { "strictSSL": false }, "request": { "method": "POST", "header": [ { "key": "Content-Type", "name": "Content-Type", "value": "application/json", "type": "text" } ], "body": { "mode": "raw", "raw": "{{body}}", "options": { "raw": { "language": "json" } } }, "url": { "raw": "{{PAYOO}}/v2/transfers", "host": [ "{{PAYOO}}" ], "path": [ "v2", "transfers" ] } }, "response": [] }, { "name": "Transfer balance to sort_code/account_number", "event": [ { "listen": "prerequest", "script": { "exec": [ "var json = {\r", "  \"amount\": 3,\r", "  \"currency\": \"GBP\",\r", "  \"reference\": \"Payment for goods\",\r", "  \"reference2\": \"Items 1,2,3\",\r", "  \"reference3\": \"Additional Info\",\r", "  \"reference4\": \"Additional Info\",\r", "  \"origin_of_funds\": \"dasds\",\r", "  \"description\": \"Merchant 123\",\r", "  \"is_instant\": false,\r", "  \"debtor\": {\r", "  \"balance\": \"0053d144-0990-439d-a712-dd0face6ae4e\",\r", "    \"address\": \"BG, Sofia, James Bouchier 76 A\",\r", "    \"name\": \"John Doe\",\r", "  },\r", "  \"creditor\": {\r", "    \"sort_code\": \"040738\",\r", "    \"account_number\": \"00020393\",\r", "    \"address\": \"BG, Sofia, James Bouchier 76 A\",\r", "    \"name\": \"John Doe\",\r", "    \"country\": \"BG\"\r", "  }\r", "} \r", "json = JSON.stringify(json) \r", "eval(pm.variables.get('fnSetAuth'));\r", "setAuth('transfer',json);\r", "pm.variables.set('body', json);" ], "type": "text/javascript" } } ], "protocolProfileBehavior": { "strictSSL": false }, "request": { "method": "POST", "header": [ { "key": "Content-Type", "name": "Content-Type", "value": "application/json", "type": "text" } ], "body": { "mode": "raw", "raw": "{{body}}", "options": { "raw": { "language": "json" } } }, "url": { "raw": "{{PAYOO}}/v2/transfers", "host": [ "{{PAYOO}}" ], "path": [ "v2", "transfers" ] } }, "response": [] }, { "name": "Transfer balance to iban", "event": [ { "listen": "prerequest", "script": { "exec": [ "var json = {\r", "  \"amount\": 0.5,\r", "  \"currency\": \"BGN\",\r", "  \"reference\": \"Payment for goods\",\r", "  \"reference2\": \"Items 1,2,3\",\r", "  \"reference3\": \"Additional Info\",\r", "  \"reference4\": \"Additional Info\",\r", "  \"origin_of_funds\": \"dasds\",\r", "  \"description\": \"Merchant 123\",\r", "  \"is_instant\": false,\r", "  \"debtor\": {\r", "  \"balance\": \"d9f8b9a6-8391-4ae7-8d2b-545e96064790\",\r", "    \"address\": \"BG, Sofia, James Bouchier 76 A\",\r", "    \"name\": \"John Doe\",\r", "  },\r", "  \"creditor\": {\r", "    \"iban\": \"BG39PATC40021972336789\",\r", "    \"address\": \"BG, Sofia, James Bouchier 76 A\",\r", "    \"name\": \"John Doe\",\r", "    \"country\": \"BG\"\r", "  }\r", "} \r", "json = JSON.stringify(json) \r", "eval(pm.variables.get('fnSetAuth'));\r", "setAuth('transfer',json);\r", "pm.variables.set('body', json);" ], "type": "text/javascript" } } ], "protocolProfileBehavior": { "strictSSL": false }, "request": { "method": "POST", "header": [ { "key": "Content-Type", "name": "Content-Type", "value": "application/json", "type": "text" } ], "body": { "mode": "raw", "raw": "{{body}}", "options": { "raw": { "language": "json" } } }, "url": { "raw": "{{PAYOO}}/v2/transfers", "host": [ "{{PAYOO}}" ], "path": [ "v2", "transfers" ] } }, "response": [] }, { "name": "Transfer balance to external_identifier", "event": [ { "listen": "prerequest", "script": { "exec": [ "var json = {\r", "  \"amount\": 7,\r", "  \"currency\": \"GBP\",\r", "  \"reference\": \"Payment for goods\",\r", "  \"reference2\": \"Items 1,2,3\",\r", "  \"reference3\": \"Additional Info\",\r", "  \"reference4\": \"Additional Info\",\r", "  \"origin_of_funds\": \"dasds\",\r", "  \"description\": \"Merchant 123\",\r", "  \"is_instant\": false,\r", "  \"debtor\": {\r", "  \"balance\": \"d9f8b9a6-8391-4ae7-8d2b-545e96064790\",\r", "    \"address\": \"BG, Sofia, James Bouchier 76 A\",\r", "    \"name\": \"John Doe\",\r", "  },\r", "  \"creditor\": {\r", "    \"external_identifier\": \"107337867\",\r", "    \"address\": \"BG, Sofia, James Bouchier 76 A\",\r", "    \"name\": \"John Doe\",\r", "    \"country\": \"BG\"\r", "  }\r", "} \r", "json = JSON.stringify(json) \r", "eval(pm.variables.get('fnSetAuth'));\r", "setAuth('transfer',json);\r", "pm.variables.set('body', json);" ], "type": "text/javascript" } } ], "protocolProfileBehavior": { "strictSSL": false }, "request": { "method": "POST", "header": [ { "key": "Content-Type", "name": "Content-Type", "value": "application/json", "type": "text" } ], "body": { "mode": "raw", "raw": "{{body}}", "options": { "raw": { "language": "json" } } }, "url": { "raw": "{{PAYOO}}/v2/transfers", "host": [ "{{PAYOO}}" ], "path": [ "v2", "transfers" ] } }, "response": [] }, { "name": "Transfer external identifier to balance", "event": [ { "listen": "prerequest", "script": { "exec": [ "var json = {\r", "  \"amount\": 0.5,\r", "  \"currency\": \"GBP\",\r", "  \"reference\": \"Payment for goods\",\r", "  \"reference2\": \"Items 1,2,3\",\r", "  \"reference3\": \"Additional Info\",\r", "  \"reference4\": \"Additional Info\",\r", "  \"origin_of_funds\": \"dasds\",\r", "  \"description\": \"Merchant 123\",\r", "  \"is_instant\": false,\r", "  \"debtor\": {\r", "  \"external_identifier\": \"107337867\",\r", "    \"address\": \"BG, Sofia, James Bouchier 76 A\",\r", "    \"name\": \"John Doe\",\r", "  },\r", "  \"creditor\": {\r", "    \"balance\": \"d9f8b9a6-8391-4ae7-8d2b-545e96064790\",\r", "    \"address\": \"BG, Sofia, James Bouchier 76 A\",\r", "    \"name\": \"John Doe\",\r", "    \"country\": \"BG\"\r", "  }\r", "} \r", "json = JSON.stringify(json) \r", "eval(pm.variables.get('fnSetAuth'));\r", "setAuth('transfer',json);\r", "pm.variables.set('body', json);" ], "type": "text/javascript" } } ], "protocolProfileBehavior": { "strictSSL": false }, "request": { "method": "POST", "header": [ { "key": "Content-Type", "name": "Content-Type", "value": "application/json", "type": "text" } ], "body": { "mode": "raw", "raw": "{{body}}", "options": { "raw": { "language": "json" } } }, "url": { "raw": "{{PAYOO}}/v2/transfers", "host": [ "{{PAYOO}}" ], "path": [ "v2", "transfers" ] } }, "response": [] }, { "name": "Transfer external identifier to iban", "event": [ { "listen": "prerequest", "script": { "exec": [ "var json = {\r", "  \"amount\": 2,\r", "  \"currency\": \"GBP\",\r", "  \"reference\": \"Payment for goods\",\r", "  \"reference2\": \"Items 1,2,3\",\r", "  \"reference3\": \"Additional Info\",\r", "  \"reference4\": \"Additional Info\",\r", "  \"origin_of_funds\": \"dasds\",\r", "  \"description\": \"Merchant 123\",\r", "  \"is_instant\": false,\r", "  \"debtor\": {\r", "  \"external_identifier\": \"107337867\",\r", "\r", "    \"address\": \"BG, Sofia, James Bouchier 76 A\",\r", "    \"name\": \"John Doe\",\r", "  },\r", "  \"creditor\": {\r", "    \"iban\": \"BG83PATC40022922334112\",\r", "    \"address\": \"BG, Sofia, James Bouchier 76 A\",\r", "    \"name\": \"John Doe\",\r", "    \"country\": \"BG\"\r", "  }\r", "} \r", "json = JSON.stringify(json) \r", "eval(pm.variables.get('fnSetAuth'));\r", "setAuth('transfer',json);\r", "pm.variables.set('body', json);" ], "type": "text/javascript" } } ], "protocolProfileBehavior": { "strictSSL": false }, "request": { "method": "POST", "header": [ { "key": "Content-Type", "name": "Content-Type", "value": "application/json", "type": "text" } ], "body": { "mode": "raw", "raw": "{{body}}", "options": { "raw": { "language": "json" } } }, "url": { "raw": "{{PAYOO}}/v2/transfers", "host": [ "{{PAYOO}}" ], "path": [ "v2", "transfers" ] } }, "response": [] }, { "name": "Transfer external identifier to external_identifier", "event": [ { "listen": "prerequest", "script": { "exec": [ "var json = {\r", "  \"amount\": 5,\r", "  \"currency\": \"GBP\",\r", "  \"reference\": \"Payment for goods\",\r", "  \"reference2\": \"Items 1,2,3\",\r", "  \"reference3\": \"Additional Info\",\r", "  \"reference4\": \"Additional Info\",\r", "  \"origin_of_funds\": \"dasds\",\r", "  \"description\": \"Merchant 123\",\r", "  \"is_instant\": false,\r", "  \"debtor\": {\r", "  \"external_identifier\": \"103200676\",\r", "    \"address\": \"BG, Sofia, James Bouchier 76 A\",\r", "    \"name\": \"John Doe\",\r", "  },\r", "  \"creditor\": {\r", "    \"external_identifier\": \"103200677\",\r", "    \"address\": \"BG, Sofia, James Bouchier 76 A\",\r", "    \"name\": \"John Doe\",\r", "    \"country\": \"BG\"\r", "  }\r", "} \r", "json = JSON.stringify(json) \r", "eval(pm.variables.get('fnSetAuth'));\r", "setAuth('transfer',json);\r", "pm.variables.set('body', json);" ], "type": "text/javascript" } } ], "protocolProfileBehavior": { "strictSSL": false }, "request": { "method": "POST", "header": [ { "key": "Content-Type", "name": "Content-Type", "value": "application/json", "type": "text" } ], "body": { "mode": "raw", "raw": "{{body}}", "options": { "raw": { "language": "json" } } }, "url": { "raw": "{{PAYOO}}/v2/transfers", "host": [ "{{PAYOO}}" ], "path": [ "v2", "transfers" ] } }, "response": [] } ] } ] }, { "name": "Transactions", "item": [ { "name": "Success scenarios", "item": [ { "name": "Transaction List", "event": [ { "listen": "prerequest", "script": { "exec": [ "var json = {", "", "}", "json = JSON.stringify(json)", "", "eval(pm.variables.get('fnSetAuth'));", "setAuth('transactions_list', json);", "pm.variables.set('body', json);" ], "type": "text/javascript" } }, { "listen": "test", "script": { "exec": [ "pm.variables.set(\"apiKey\", \"0457ed6ce0c8afe4a554be79ea80d915\");\r", "pm.variables.set(\"apiSecret\", \"58c66ad7c731a\");" ], "type": "text/javascript" } } ], "protocolProfileBehavior": { "strictSSL": false, "disableBodyPruning": true }, "request": { "method": "GET", "header": [ { "key": "Content-Type", "name": "Content-Type", "value": "application/x-www-form-urlencoded", "type": "text", "disabled": true } ], "body": { "mode": "raw", "raw": "{{body}}", "options": { "raw": { "language": "json" } } }, "url": { "raw": "{{API_GATEWAY}}/v2/transactions/1/50", "host": [ "{{API_GATEWAY}}" ], "path": [ "v2", "transactions", "1", "50" ] } }, "response": [] }, { "name": "Transaction List all filters", "event": [ { "listen": "prerequest", "script": { "exec": [ "var json = {", "", "}", "json = JSON.stringify(json)", "", "eval(pm.variables.get('fnSetAuth'));", "setAuth('transactions_list', json);", "pm.variables.set('body', json);" ], "type": "text/javascript" } }, { "listen": "test", "script": { "exec": [ "pm.variables.set(\"apiKey\", \"0457ed6ce0c8afe4a554be79ea80d915\");\r", "pm.variables.set(\"apiSecret\", \"58c66ad7c731a\");" ], "type": "text/javascript" } } ], "protocolProfileBehavior": { "strictSSL": false, "disableBodyPruning": true }, "request": { "method": "GET", "header": [ { "key": "Content-Type", "name": "Content-Type", "value": "application/x-www-form-urlencoded", "type": "text", "disabled": true } ], "body": { "mode": "raw", "raw": "{{body}}", "options": { "raw": { "language": "json" } } }, "url": { "raw": "{{API_GATEWAY}}/v2/transactions/1/50", "host": [ "{{API_GATEWAY}}" ], "path": [ "v2", "transactions", "1", "50" ], "query": [ { "key": "start_date", "value": "", "disabled": true }, { "key": "end_date", "value": "", "disabled": true }, { "key": "type", "value": "", "disabled": true }, { "key": "code", "value": "", "disabled": true }, { "key": "channel", "value": "", "disabled": true }, { "key": "status", "value": "", "disabled": true }, { "key": "merchant", "value": "", "disabled": true }, { "key": "user", "value": "", "disabled": true }, { "key": "reference", "value": "", "disabled": true }, { "key": "show_hidden", "value": "", "disabled": true }, { "key": "account", "value": "", "disabled": true }, { "key": "balance", "value": "", "disabled": true }, { "key": "debit_credit", "value": "", "disabled": true }, { "key": "load_after", "value": "", "disabled": true } ] } }, "response": [] }, { "name": "Transaction Details", "event": [ { "listen": "prerequest", "script": { "exec": [ "var json = {", "", "}", "json = JSON.stringify(json)", "", "eval(pm.variables.get('fnSetAuth'));", "setAuth('transaction_details', json);", "pm.variables.set('body', json);" ], "type": "text/javascript" } }, { "listen": "test", "script": { "exec": [ "pm.variables.set(\"apiKey\", \"0457ed6ce0c8afe4a554be79ea80d915\");\r", "pm.variables.set(\"apiSecret\", \"58c66ad7c731a\");" ], "type": "text/javascript" } } ], "protocolProfileBehavior": { "strictSSL": false, "disableBodyPruning": true }, "request": { "method": "GET", "header": [ { "key": "Content-Type", "name": "Content-Type", "value": "application/x-www-form-urlencoded", "type": "text", "disabled": true } ], "body": { "mode": "raw", "raw": "{{body}}", "options": { "raw": { "language": "json" } } }, "url": { "raw": "{{API_GATEWAY}}/v2/transactions/363415a9-3436-4436-b8f8-14247cec1c1", "host": [ "{{API_GATEWAY}}" ], "path": [ "v2", "transactions", "363415a9-3436-4436-b8f8-14247cec1c1" ] } }, "response": [] } ] }, { "name": "Negative scenarios", "item": [ { "name": "Transaction Details wrong transaction token - entity not found", "event": [ { "listen": "prerequest", "script": { "exec": [ "var json = {", "", "}", "json = JSON.stringify(json)", "", "eval(pm.variables.get('fnSetAuth'));", "setAuth('transaction_details', json);", "pm.variables.set('body', json);" ], "type": "text/javascript" } }, { "listen": "test", "script": { "exec": [ "pm.variables.set(\"apiKey\", \"0457ed6ce0c8afe4a554be79ea80d915\");\r", "pm.variables.set(\"apiSecret\", \"58c66ad7c731a\");" ], "type": "text/javascript" } } ], "protocolProfileBehavior": { "strictSSL": false, "disableBodyPruning": true }, "request": { "method": "GET", "header": [ { "key": "Content-Type", "name": "Content-Type", "value": "application/x-www-form-urlencoded", "type": "text", "disabled": true } ], "body": { "mode": "raw", "raw": "{{body}}", "options": { "raw": { "language": "json" } } }, "url": { "raw": "{{API_GATEWAY}}/v2/transactions/363415a9-3436-4436-b8f8-14247cec1c1", "host": [ "{{API_GATEWAY}}" ], "path": [ "v2", "transactions", "363415a9-3436-4436-b8f8-14247cec1c1" ] } }, "response": [] } ] } ] } ], "event": [ { "listen": "prerequest", "script": { "type": "text/javascript", "exec": [ "function setAuth(operation, content = '') {", "", "let apiKey = pm.collectionVariables.get(\"API_KEY\")", "let apiSecret = pm.collectionVariables.get(\"API_SECRET\");", " ", "", "let ts = Math.round((new Date()).getTime() / 1000,0)", "", "console.log(ts) ", "", "const hash = CryptoJS.HmacSHA256(apiKey + ts + operation + content, apiSecret).toString();", "", " console.log(hash,apiKey,ts);", " ", "pm.request.headers.add({", " key: 'x-api-key',", " value: apiKey", " });", " pm.request.headers.add({", " key: 'x-hash',", " value: hash", " });", " pm.request.headers.add({", " key: 'x-timestamp',", " value: ts", " });", "}", "", "", "pm.variables.set('fnSetAuth', setAuth.toString());" ] } }, { "listen": "test", "script": { "type": "text/javascript", "exec": [ "" ] } } ], "variable": [ { "key": "API_KEY", "value": "", "type": "string" }, { "key": "API_SECRET", "value": "", "type": "string" }, { "key": "API_GATEWAY", "value": "https://api.paynetics.io", "type": "string" } ] }