{"activeVersionTag":"latest","latestAvailableVersionTag":"latest","collection":{"info":{"_postman_id":"414d6abb-ae59-3b2a-7bc0-7b410721b3c4","name":"PiConnect - SaaS","description":"Local (desktop) application (Windows, iOS, Android, etc) transactions are completed with a simple RESTful GET, followed by a conversion of the response:\r\n\r\n    Step 1: RESTful GET to launch the EMV device and receive an *encrypted result string*\r\n    Step 2: RESTful POST to convert the encyrpted result string into readable JSON    \r\n---- \r\n\r\n>**REQUEST FIELDS for GET (EMV device launch and response)**  \r\n\r\nField | Description | Format | M/O (Mandatory/Optional)\r\n--- | --- | --- | ---\r\nmethod | CreditSale, CreditAuth, CreditCapture, CreditReturn, CreditVoid, DebitSale, DebitReturn, DebitVoid, CloseBatch, CloseAllBatches, Initialize, QuickRead, TransactionDetails, FailedTransactions, TotalTransactions, LastBatch, ForceBatchClose, EBTSale, EBTReturn, EBTReturn | AN(25) | M\r\naccount |   Payment Innovator's issued account # | N(10) | M\r\nsn | deviceid | AN(25) | M\r\nip | device local ip address | ANC(25) | O\r\namount | transaction amount | N(9)n.nn | M\r\nticketid | ticket, receipt, invoice | AN(18) | M\r\nuserid | clerk or system user | AN(18) | M\r\ntip | tip amount | N(9)n.nn | O\r\ntipreq | set to 1 for tip at terminal | N(1) | O\r\nsignature | set to 0 for no signature, 1 for signature | N(1) | O\r\nl2taxamount | tax amount | N(9)n.nn | M for level2\r\nl2custcode | corp card customer id | AN(18) | M for level2\r\nl2purchaseorder | purchase order number | N(18) | M for level2\r\nnotes | comments or notes | AN(25) | O\r\ntoken | secure token representing card# | N(16) | M for token transactions\r\nexpirationdate | mmyy | N(4) | O for token transactions\r\ncardtype | VISA, MASTERCARD, DISCOVER, AMEX, JCB | AN(10) | O for token transactions\r\nptk | Pi transaction key | ANC (18) | O (optionally used for follow-on transactions such as Void, Capture)\r\n\r\n\r\n>**REQUEST FIELDS for POST - CONVERT TO JSON**  \r\n\r\nField | Description | Format | M/O (Mandatory/Optional)\r\n--- | --- | --- | ---\r\nresponse | encrypted response from EMV device | ANC(100) | M\r\naccount |   Payment Innovator's issued account # | N(10) | M\r\nsn | deviceid | AN(25) | M\r\nmode | 2 for all transactions except closebatch (1) |A(1) | M\r\n\r\n\r\n>**RESPONSE FIELDS**  \r\n\r\nField | Description | Format\r\n--- | --- | ---\r\nTransactionResult | true (successful) / false (unsuccessful) | AN(18)\r\nPTK | Pi transaction key (used for follow-on transactions (CreditAdjust, CreditCapture, CreditVoid) | ANC(18)\r\nResponseCode | processor specific response code | AN(18)\r\nApprovedAmount | confirmation of amount processed (check for partial approvals) | n.nn\r\nTransactionID | transaction reference | AN(18)\r\nAuthCode | approval/authorization code | AN(18)\r\nToken | secure token representing card# | AN(16)\r\nCardType | VISA, MASTERCARD, DISCOVER, AMEX, JCB | AN(10)\r\nAccountNum | last 4 of card number | N(4)\r\nExpirationDate | mmyy | N(4)\r\nTicketID | ticket, receipt, invoice | AN(18)\r\nResponseMsg | processor message *important to display for unsuccessful transactions* | AN(25)\r\nHostCode | processor code | AN(25)\r\nTimestamp | time of transaction | N(16)\r\nAvsResponse | A,E,N,R,S,U,W,X,Y,Z,G,B,C,D,I,M,P | AN(2)\r\nCvResponse | M,N,P,S,U | N(4)\r\nCardHolder | cardholder name from card-present transaction | AN(25)\r\nBusinessId | PIConnect account number | N(10)\r\nUniqueId | unique transaction id | AN(25)\r\nTransType | transaction type confirmation | AN(25)\r\nEntryMode | CHIP, SWIPE, MANUAL, CONTACTLESS | AN(25)\r\nRefNum | processor or device reference number | N(25)\r\nSerialNo | device serial number or id | N(25)\r\nAmountDue | populated for partial approvals for some processors | n.nn\r\nTipAmount | confirmation of tip amount | n.nn \r\nHostResponse | processor or device response | AN(25)\r\nExtraBalance | balance on certain card types | n.nn\r\nCardBin | card bin range | N(6)\r\n(Multiple EMV response fields) | Tc, Tvr, Aid, Tsi, Atc, AppLab, AppPN, lad, Arc, Cid, Cvm | AN(25)\r\nMethod | Internal Pi transaction type | ANC(10)  \r\n  \r\n----  \r\n\r\n>**SANDBOX / DEVICE EMULATOR**  \r\n\r\n  *Use sn=31415926 for all emulator testing (yes, those are the digits in honor of Pi)*\r\n\r\nAmount | Response | ResultMessage\r\n--- | --- | ---\r\nAll amounts except those listed below | Approval | OK \r\n13.10 | Decline | COMM ERROR\r\n13.11 | Decline | DECLINE\r\n13.12 | Decline | TRACK INVALID\r\n13.13 | Decline | REF NO MISSING\r\n13.14 | Decline | ABORTED\r\n13.15 | Decline | TIMEOUT\r\n13.16 | Decline | RECEIVE ERROR\r\n13.17 | Decline | DUP TRANSACTION (SWIPE)\r\n13.18 | Decline | DUP TRANSACTION (EMV)\r\n13.19 | Decline | CONNECT ERROR\r\n----  \r\n\r\n>**EXAMPLE RESPONSE**  \r\n\r\n    {\r\n    \"TransactionResult\": \"true\",\r\n    \"PTK\": \"BbrU6swH29\",                  // Important to store\r\n    \"ResponseCode\": \"000000\",\r\n    \"ApprovedAmount\": 23.24,\r\n    \"TransactionID\": \"4\",\r\n    \"AuthCode\": \"TAS456\",\r\n    \"Token\": \"Xj02K6IZfo5M2142\",          // Important to store for card-on-file purposes\r\n    \"CardType\": \"VISA\",                   // Important to store for card-on-file purposes\r\n    \"AccountNum\": \"2142\",                 // Important to store for card-on-file purposes\r\n    \"ExpDate\": \"0121\",                    // Important to store for card-on-file purposes\r\n    \"TicketID\": \"R2324\",\r\n    \"ResponseMsg\": \"OK\",\r\n    \"HostCode\": \"00\",\r\n    \"Timestamp\": \"20180210121119\",\r\n    \"AvsResponse\": null,\r\n    \"CardHolder\": \"PAYMENT INNOVATORS/TEST T\",\r\n    \"BusinessId\": \"1512407959\",\r\n    \"UniqueId\": \"5a7f520ab83b2\",\r\n    \"TransType\": \"SALE\",\r\n    \"EntryMode\": \"CHIP\",\r\n    \"RefNum\": \"804120502567\",\r\n    \"SerialNo\": \"53211269\",\r\n    \"AmountDue\": \"0\",\r\n    \"TipAmount\": 0,\r\n    \"CvResponse\": null,\r\n    \"HostResponse\": \"APPROVAL TAS456\",\r\n    \"ExtraBalance\": null,\r\n    \"CardBin\": \"441840\",\r\n    \"Tc\": \"A003D\",\r\n    \"Tvr\": \"8080008000\",\r\n    \"Aid\": \"A0000000031010\",\r\n    \"Tsi\": \"6C00\",\r\n    \"Atc\": \"003D\",\r\n    \"AppLab\": \"Visa Credit\",\r\n    \"AppPN\": null,\r\n    \"Iad\": \"06010A03600000\",\r\n    \"Arc\": \"00\",\r\n    \"Cid\": \"40\",\r\n    \"Cvm\": null,\r\n    \"Method\":\"Credit\"\r\n    }","schema":"https://schema.getpostman.com/json/collection/v2.0.0/collection.json","isPublicCollection":false,"owner":"360438","team":82263,"collectionId":"414d6abb-ae59-3b2a-7bc0-7b410721b3c4","publishedId":"RVnSJNXa","public":true,"publicUrl":"https://api-saas.piconnect.io","privateUrl":"https://go.postman.co/documentation/360438-414d6abb-ae59-3b2a-7bc0-7b410721b3c4","customColor":{"top-bar":"2199DE","right-sidebar":"303030","highlight":"2199DE"},"documentationLayout":"classic-double-column","version":"8.11.2","publishDate":"2018-03-07T16:57:51.000Z","activeVersionTag":"latest","documentationTheme":"light","metaTags":{},"logos":{}},"statusCode":200},"environments":[],"user":{"authenticated":false,"permissions":{"publish":false}},"run":{"button":{"js":"https://run.pstmn.io/button.js","css":"https://run.pstmn.io/button.css"}},"web":"https://www.getpostman.com/","team":{"logo":"https://res.cloudinary.com/postman/image/upload/t_team_logo_pubdoc/v1/team/4efb337b51b2406f7820f05e49e0114ad37658285d3cbf16b2aa9ceb68cfe2cb","favicon":"https://piconnect.io/favicon.ico"},"isEnvFetchError":false,"languages":"[{\"key\":\"csharp\",\"label\":\"C#\",\"variant\":\"HttpClient\"},{\"key\":\"csharp\",\"label\":\"C#\",\"variant\":\"RestSharp\"},{\"key\":\"curl\",\"label\":\"cURL\",\"variant\":\"cURL\"},{\"key\":\"dart\",\"label\":\"Dart\",\"variant\":\"http\"},{\"key\":\"go\",\"label\":\"Go\",\"variant\":\"Native\"},{\"key\":\"http\",\"label\":\"HTTP\",\"variant\":\"HTTP\"},{\"key\":\"java\",\"label\":\"Java\",\"variant\":\"OkHttp\"},{\"key\":\"java\",\"label\":\"Java\",\"variant\":\"Unirest\"},{\"key\":\"javascript\",\"label\":\"JavaScript\",\"variant\":\"Fetch\"},{\"key\":\"javascript\",\"label\":\"JavaScript\",\"variant\":\"jQuery\"},{\"key\":\"javascript\",\"label\":\"JavaScript\",\"variant\":\"XHR\"},{\"key\":\"c\",\"label\":\"C\",\"variant\":\"libcurl\"},{\"key\":\"nodejs\",\"label\":\"NodeJs\",\"variant\":\"Axios\"},{\"key\":\"nodejs\",\"label\":\"NodeJs\",\"variant\":\"Native\"},{\"key\":\"nodejs\",\"label\":\"NodeJs\",\"variant\":\"Request\"},{\"key\":\"nodejs\",\"label\":\"NodeJs\",\"variant\":\"Unirest\"},{\"key\":\"objective-c\",\"label\":\"Objective-C\",\"variant\":\"NSURLSession\"},{\"key\":\"ocaml\",\"label\":\"OCaml\",\"variant\":\"Cohttp\"},{\"key\":\"php\",\"label\":\"PHP\",\"variant\":\"cURL\"},{\"key\":\"php\",\"label\":\"PHP\",\"variant\":\"Guzzle\"},{\"key\":\"php\",\"label\":\"PHP\",\"variant\":\"HTTP_Request2\"},{\"key\":\"php\",\"label\":\"PHP\",\"variant\":\"pecl_http\"},{\"key\":\"powershell\",\"label\":\"PowerShell\",\"variant\":\"RestMethod\"},{\"key\":\"python\",\"label\":\"Python\",\"variant\":\"http.client\"},{\"key\":\"python\",\"label\":\"Python\",\"variant\":\"Requests\"},{\"key\":\"r\",\"label\":\"R\",\"variant\":\"httr\"},{\"key\":\"r\",\"label\":\"R\",\"variant\":\"RCurl\"},{\"key\":\"ruby\",\"label\":\"Ruby\",\"variant\":\"Net::HTTP\"},{\"key\":\"shell\",\"label\":\"Shell\",\"variant\":\"Httpie\"},{\"key\":\"shell\",\"label\":\"Shell\",\"variant\":\"wget\"},{\"key\":\"swift\",\"label\":\"Swift\",\"variant\":\"URLSession\"}]","languageSettings":[{"key":"csharp","label":"C#","variant":"HttpClient"},{"key":"csharp","label":"C#","variant":"RestSharp"},{"key":"curl","label":"cURL","variant":"cURL"},{"key":"dart","label":"Dart","variant":"http"},{"key":"go","label":"Go","variant":"Native"},{"key":"http","label":"HTTP","variant":"HTTP"},{"key":"java","label":"Java","variant":"OkHttp"},{"key":"java","label":"Java","variant":"Unirest"},{"key":"javascript","label":"JavaScript","variant":"Fetch"},{"key":"javascript","label":"JavaScript","variant":"jQuery"},{"key":"javascript","label":"JavaScript","variant":"XHR"},{"key":"c","label":"C","variant":"libcurl"},{"key":"nodejs","label":"NodeJs","variant":"Axios"},{"key":"nodejs","label":"NodeJs","variant":"Native"},{"key":"nodejs","label":"NodeJs","variant":"Request"},{"key":"nodejs","label":"NodeJs","variant":"Unirest"},{"key":"objective-c","label":"Objective-C","variant":"NSURLSession"},{"key":"ocaml","label":"OCaml","variant":"Cohttp"},{"key":"php","label":"PHP","variant":"cURL"},{"key":"php","label":"PHP","variant":"Guzzle"},{"key":"php","label":"PHP","variant":"HTTP_Request2"},{"key":"php","label":"PHP","variant":"pecl_http"},{"key":"powershell","label":"PowerShell","variant":"RestMethod"},{"key":"python","label":"Python","variant":"http.client"},{"key":"python","label":"Python","variant":"Requests"},{"key":"r","label":"R","variant":"httr"},{"key":"r","label":"R","variant":"RCurl"},{"key":"ruby","label":"Ruby","variant":"Net::HTTP"},{"key":"shell","label":"Shell","variant":"Httpie"},{"key":"shell","label":"Shell","variant":"wget"},{"key":"swift","label":"Swift","variant":"URLSession"}],"languageOptions":[{"label":"C# - HttpClient","value":"csharp - HttpClient - C#"},{"label":"C# - RestSharp","value":"csharp - RestSharp - C#"},{"label":"cURL - cURL","value":"curl - cURL - cURL"},{"label":"Dart - http","value":"dart - http - Dart"},{"label":"Go - Native","value":"go - Native - Go"},{"label":"HTTP - HTTP","value":"http - HTTP - HTTP"},{"label":"Java - OkHttp","value":"java - OkHttp - Java"},{"label":"Java - Unirest","value":"java - Unirest - Java"},{"label":"JavaScript - Fetch","value":"javascript - Fetch - JavaScript"},{"label":"JavaScript - jQuery","value":"javascript - jQuery - JavaScript"},{"label":"JavaScript - XHR","value":"javascript - XHR - JavaScript"},{"label":"C - libcurl","value":"c - libcurl - C"},{"label":"NodeJs - Axios","value":"nodejs - Axios - NodeJs"},{"label":"NodeJs - Native","value":"nodejs - Native - NodeJs"},{"label":"NodeJs - Request","value":"nodejs - Request - NodeJs"},{"label":"NodeJs - Unirest","value":"nodejs - Unirest - NodeJs"},{"label":"Objective-C - NSURLSession","value":"objective-c - NSURLSession - Objective-C"},{"label":"OCaml - Cohttp","value":"ocaml - Cohttp - OCaml"},{"label":"PHP - cURL","value":"php - cURL - PHP"},{"label":"PHP - Guzzle","value":"php - Guzzle - PHP"},{"label":"PHP - HTTP_Request2","value":"php - HTTP_Request2 - PHP"},{"label":"PHP - pecl_http","value":"php - pecl_http - PHP"},{"label":"PowerShell - RestMethod","value":"powershell - RestMethod - PowerShell"},{"label":"Python - http.client","value":"python - http.client - Python"},{"label":"Python - Requests","value":"python - Requests - Python"},{"label":"R - httr","value":"r - httr - R"},{"label":"R - RCurl","value":"r - RCurl - R"},{"label":"Ruby - Net::HTTP","value":"ruby - Net::HTTP - Ruby"},{"label":"Shell - Httpie","value":"shell - Httpie - Shell"},{"label":"Shell - wget","value":"shell - wget - Shell"},{"label":"Swift - URLSession","value":"swift - URLSession - Swift"}],"layoutOptions":[{"value":"classic-single-column","label":"Single Column"},{"value":"classic-double-column","label":"Double Column"}],"versionOptions":[],"environmentOptions":[{"value":"0","label":"No Environment"}],"canonicalUrl":"https://api-saas.piconnect.io/view/metadata/RVnSJNXa"}