Difference between revisions of "Pawn2ME:Development/APIv2"

From XcelData Wiki
Jump to: navigation, search
(Created page with "= Pawn2ME Version 2 API Calls = All calls require a store api key. That can be done by an admin via [https://accounts.xceldata.com/ accounts.xceldata.com] == /v2/customers/s...")
 
 
Line 13: Line 13:
 
'''Note:''' The main difference between v1 and v2 is the addition of the country code for mexico number parsing.
 
'''Note:''' The main difference between v1 and v2 is the addition of the country code for mexico number parsing.
  
POST -> https://api.pawn2me.com/v1/customers/signup-user
+
POST -> https://api.pawn2me.com/v2/customers/signup-user
  
 
=== Single Customers ===
 
=== Single Customers ===
Line 32: Line 32:
 
The user must have authorized their device to show up as activated. You will only see the activation status of people who signed up at your store.
 
The user must have authorized their device to show up as activated. You will only see the activation status of people who signed up at your store.
  
POST -> https://api.pawn2me.com/v1/customers/get-updates
+
POST -> https://api.pawn2me.com/v2/customers/get-updates
  
 
<blockquote>{ &quot;token&quot;: &quot;1E17162A-8355-4FF2-8DCD-E5CEE676FD93&quot; }
 
<blockquote>{ &quot;token&quot;: &quot;1E17162A-8355-4FF2-8DCD-E5CEE676FD93&quot; }

Latest revision as of 19:36, 18 January 2019

Pawn2ME Version 2 API Calls

All calls require a store api key. That can be done by an admin via accounts.xceldata.com

/v2/customers/signup-user

In order to use Pawn2ME, customers must first verify their device by activating it, per store.

This endpoint tells the server to send an activation link to a specific sms/email address.

A customer cannot receive notices before activating.

Note: The main difference between v1 and v2 is the addition of the country code for mexico number parsing.

POST -> https://api.pawn2me.com/v2/customers/signup-user

Single Customers

{ "token": "1E17162A-8355-4FF2-8DCD-E5CEE676FD93", "address-type": "sms", "address": "5551234567", "first-name": "Test", "last-name": "Testerson", "id": "D1234567", "language-type": "en", "language-type": "en", "country-code": "1" }

Result:

{ "success": true, "id": "D1234567", "address": "5551234567", "address-country-code": "1" }

/v2/customers/get-updates

This endpoint allows you to know which of your customers are activated or not.

Recording this information allows you to notify the teller that a user is signed up with Pawn2ME and with what account.

The user must have authorized their device to show up as activated. You will only see the activation status of people who signed up at your store.

POST -> https://api.pawn2me.com/v2/customers/get-updates

{ "token": "1E17162A-8355-4FF2-8DCD-E5CEE676FD93" }

Result:

{ "success": true, "updates": [ { "id": "D1111111", "added": "2018-02-06 18:06:21", "updated": "2018-02-06 18:14:32", "activated": true, "device": { "type": "sms", "address": "5551234567" } }, { "id": "D9999999", "added": "2018-02-07 23:10:02",