Tags API
addTag
Anchor link toPOST
https://api.pushwoosh.com/json/1.3/addTag
สร้างแท็กในบัญชีของคุณ
Request body
Anchor link toName | Type | Description |
---|---|---|
auth* | string | โทเค็นการเข้าถึง API จาก Pushwoosh Control Panel |
tag* | object | พารามิเตอร์ของแท็ก |
tag.name* | string | ชื่อแท็ก |
tag.type* | integer | ประเภทแท็ก ดูค่าที่เป็นไปได้ด้านล่าง |
tag.application_specific | boolean | กำหนดว่าค่าแท็กควรจะแตกต่างกันสำหรับหลายแอป หรือเป็นค่าเดียวกันในทุกแอป |
{ "status_code": 200, "status_message": "OK", "response": { "result": true }}
{ "request": { "auth": "yxoPUlwqm…………pIyEX4H", // จำเป็น โทเค็นการเข้าถึง API จาก Pushwoosh Control Panel "tag": { "name": "TAG_NAME", // จำเป็น "type": 1, // จำเป็น ดูค่าที่เป็นไปได้ด้านล่าง "application_specific": true, // ไม่บังคับ กำหนดว่าค่าแท็กควรจะแตกต่างกันหรือไม่ // สำหรับหลายแอป หรือเป็นค่าเดียวกันในทุกแอป "user_specific": true // ไม่บังคับ ใช้สำหรับแท็กที่เป็น application_specific } }}
ประเภทค่าแท็กที่เป็นไปได้:
- 1 - Integer (จำนวนเต็ม)
- 2 - String (สตริง)
- 3 - List (รายการ)
- 4 - Date (วันที่)
- 5 - Boolean (บูลีน)
- 6 - Decimal (ทศนิยม) เช่น 19.95
- 7 - Version (เวอร์ชัน) เช่น “1.0.0.0”
deleteTag
Anchor link toPOST
https://api.pushwoosh.com/json/1.3/deleteTag
ลบแท็กพร้อมข้อมูลที่เกี่ยวข้องทั้งหมดออกจากฐานข้อมูลโดยสมบูรณ์
Request body
Anchor link toName | Type | Description |
---|---|---|
auth* | string | โทเค็นการเข้าถึง API จาก Pushwoosh Control Panel |
tag* | object | พารามิเตอร์ของแท็ก |
tag.name* | string | ชื่อของแท็กที่จะลบ |
{ "status_code": 200, "status_message": "OK", "response": { "result": true }}
{ "request": { "auth": "yxoPUlwqm…………pIyEX4H", // จำเป็น โทเค็นการเข้าถึง API จาก Pushwoosh Control Panel "tag": { "name": "TAG_NAME" // จำเป็น ชื่อของแท็กที่จะลบ } }}
listTags
Anchor link toPOST
https://api.pushwoosh.com/json/1.3/listTags
ดึงรายการแท็กทั้งหมดในบัญชี
Request body
Anchor link toName | Type | Description |
---|---|---|
auth* | string | โทเค็นการเข้าถึง API จาก Pushwoosh Control Panel |
{ "status_code": 200, "status_message": "OK", "response": { "tags": [{ "name":"Language", "type":2, "isApplicationSpecific": false }, { "name":"List tag", "type":3, "isApplicationSpecific": false }] }}
{ "request":{ "auth": "yxoPUlwqm…………pIyEX4H" // โทเค็นการเข้าถึง API จาก Pushwoosh Control Panel }}
ประเภทของแท็ก:
- 1 - Integer (จำนวนเต็ม)
- 2 - String (สตริง)
- 3 - List (รายการ)
- 4 - Date (วันที่)
- 5 - Boolean (บูลีน)
- 6 - Decimal (ทศนิยม) เช่น 19.95
- 7 - Version (เวอร์ชัน) เช่น “1.0.0.0”