Transfer / การส่งพอยท์ ดึงพอยท์

ใช้สำหรับส่งพอยท์ ดึงพอยท์ ของลูกค้า

endpoint
POST /api/business/this/point
Request parameters
#PropertyDescription
1 type ประเภทของการโอนพอยท์ (send, pull)
2 receiver หมายเลขโทรศัพท์ หรือ PointSpot ID
3 amount จำนวน (สำหรับใช้อัตราแปลงพอยท์คำนวณ)
4 point พอยท์ที่ต้องการส่ง
5 remark หมายเหตุ เช่น เลขที่บิล ประเภทสินค้า
6 img ลิงค์รูปภาพ
7 tag # แท๊ก สำหรับทำป้ายกำกับ
8 preregister สถานะการสมัครสมาชิกล่วงหน้า
9 profile ข้อมูลลูกค้าสำหรับลงทะเบียน
10 receipt_coupon คูปองแนบที่ต้องการส่ง
POST point
POST /api/business/this/point HTTP/1.1
Host: globalapi.pointspot.co
Authorization: Bearer {{business_token}}
Content-Type: application/json
Content-Length: {{content_length}}

{
  "type" : "send",
  "receiver" : {{mobile_number}},
  "amount" : 523,
  "point" : 52,
  "remark" : "ซื้อสินค้า 523 บาท",
  "img" : {{image_url}},
  "tag" : [1,2],
  "preregister" : true,
  "profile" : [{{first_name}}, {{last_name}}],
  "receipt_coupon" : [425]
}
Response parameters
#PropertyDescription
1 result สถานะของการทำงาน
2 trans_hash #hash ของรายการโอน
3 transaction #hash ของรายการโอน
4 business_code รหัสธุรกิจ
5 business_name ชื่อธุรกิจ
6 member_badge_code รหัสสมาชิกของ PointSpot หรือ pointspot_id
7 trans_remark หมายเหตุ
8 trans_status สถานะของรายการ
9 trans_type ประเภทรายการ
10 img รูปภาพแนบ
11 amount จำนวน
12 point พอยท์ที่ทำการโอน
RESPONSE
{
  "result": true,
  "route": "POST /api/business/this/point",
  "method": "api/business/point",
  "eventDate": "2019-12-10T10:24:07.199Z",
  "data": [
    {
      "trans_hash": "0x7ecdbef70de74a162f4ac64a38906da5a44da2bbf1d4040f4eee2319f03bb35a",
      "transaction": "0x7ecdbef70de74a162f4ac64a38906da5a44da2bbf1d4040f4eee2319f03bb35a"
      "business_code": "3bf54632",
      "business_name": "PointSpot Cafe`",
      "member_badge_code": 180014,
      "trans_remark": "ซื้อสินค้า 523 บาท",
      "trans_status": "pending",
      "trans_type": "send",
      "img": "",
      "amount": 523,
      "point": 52,
      "create_by": "business_3bf54632",
      "eventtime": 1575973448166,
      "unique_id": "71fb5c4e",
      "chksum": {{chksum}},
    }
  ]
}