MantaGO
  • 文件說明
  • 文件說明
    • 會員API
      • 帳號綁定
      • 解除帳號綁定
      • 會員列表
      • 會員資料
    • 用戶推播
    • 設定webview網址
    • 設定回呼網址
    • API Token與Secret Key換發
  • 常見問題
    • 如何取得Token
    • 錯誤代碼
  • 情境範例
    • 購物車下單後推播訊息
Powered by GitBook
On this page
  1. 文件說明
  2. 會員API

會員資料

用會員的經過加密的 MantaGo ID,來取得所屬於某機器人的特定會員之資料

Request Url :

POST https://mantago.cc/api/openapi/client/:clientId

Request headers :

Name
Description

Content-Type

application/json

Authorization

Bearer {API Token}

Request body:

Name
Type
Description
Required

secret

String

API Secret

O

Query parameter :

Name
Type
Description
Required

botId

String

經過加密的機器人ID

O

platformClientId

String

會員的 LINE / FB Messenger / Instagram ID

如『Request Parameter』的『clientId』為空白,則為O,否則為為X

platform

String

會員帳號所屬平台:line / facebook / instagram

如『Request Parameter』的『clientId』為空白,則為O,否則為X

Request Parameter:

Name
Type
Description
Required

clientId

String

MantaGo的經過加密的會員 ID

如『Query parameter』的『platformClientId』和『platform』任一為空白,則為O,否則為X

Response Result:

Name
Type
Description

success

Boolean

表示取得資料成功與否

message

String

表示成功取得資料與否之訊息

client

Object

會員資料

client:

Name
Type
Description

clientId

String

會員的 LINE / FB Messenger / Instagram ID

clientName

String

會員的 LINE / FB Messenger / Instagram 名稱

clientHeadshot

String

會員的大頭貼

platform

String

會員帳號所屬平台:line / facebook / instagram

remark

Array[Object]

會員的備註

isBlock

Boolean

該帳號是否主動封鎖機器人

customerId

String

客戶ID

userName

String

會員設定之名稱

userEmail

String

會員設定之Email

userPhone

String

會員設定之電話

userBirthday

String

會員設定之生日

userAddress

String

會員設定之地址

createdAt

Date

會員資料建立時間

updatedAt

Date

會員資料最後更新時間

lastInteractAt

Date

會員上次與機器人互動之時間

autoTags

Array[Object]

會員自動標籤

tags

Array[Object]

會員手動標籤

tourTags

Array[Object]

會員預約標籤

personalTags

Array[Object]

會員個性標籤

remark:

Name
Type
Description

text

String

備註內容

dateTime

Date

備註建立時間

autoTags:

Name
Type
Description

name

String

標籤名稱

createdAt

Date

標籤建立時間

tags:

Name
Type
Description

name

String

標籤名稱

createdAt

Date

標籤建立時間

tourTags

Name
Type
Description

name

String

標籤名稱

createdAt

Date

標籤建立時間

personalTags

Name
Type
Description

name

String

標籤名稱

createdAt

Date

標籤建立時間

Response example :

URL:

POST https://mantago.cc/api/openapi/client/"thisIsMyClientId"?botId="thisIsMyId"

結果:

{
    "success": true,
    "message": "Get client successfully",
    "client": {
        "clientId": "1234567890ABCDEFG",
        "clientName": "魟小魚",
        "clientHeadshot": "https://this.is.headshot.com.tw",
        "platform": "line",
        "remark": [
            {
                "text": "cute",
                "dateTime": "2022-01-04T06:32:26.628Z"
            }
        ],
        "isBlock": false,
        "customerId": null,
        "userName": "小魟魚",
        "userEmail": "myEmail@mantago.cc",
        "userPhone": "0912345678",
        "userAddress": "999 太平洋市魟魚區小魟魚路1號1樓",
        "userBirthday": "1990-03-11T00:00:00.000Z",
        "createdAt": "2022-10-04T11:00:22.225Z",
        "updatedAt": "2022-10-07T09:52:46.001Z",
        "lastInteractAt": "2022-10-06T02:29:48.920Z",
        "autoTags": [
            {
                "name": "Hey",
                "createdAt": "2022-08-29T09:04:34.259Z"
            }
        ],
        "tags": [
            {
                "name": "Holo",
                "createdAt": "2022-09-12T04:16:58.959Z"
            }
        ],
        "tourTags": [
            {
                "name": "太平洋",
                "createdAt": "2022-08-29T09:04:34.259Z"
            }
        ],
        "personalTags": [
            {
                "name": "甜",
                "createdAt": "2022-09-12T04:16:58.959Z"
            }
        ]
    }
}
Previous會員列表Next用戶推播

Last updated 9 months ago