Chuyển tới nội dung chính

API Lấy thông tin trạng thái gửi tin qua SĐT

API cho phép đối tác truy xuất trạng thái gửi tin qua SĐT.

Lưu ý

Quyền cần có: Gửi tin qua số điện thoại

HTTP request

Example request

curl
-X GET
-H "Content-Type: application/json"
"https://business.openapi.zalo.me/message/status?message_id=message_id&phone=phone"

Tham số header

Tham sốKiểu dữ liệuTính bắt buộcMô tả
access_token

string

yes

Đoạn mã cần truyền vào để xác minh quyền sử dụng API. Xem thêm tài liệu tham khảo

Tham số

Tham sốKiểu dữ liệuTính bắt buộcMô tả

message_id

string

yes

ID của thông báo cần lấy thông tin trạng thái.

Example respond

{
"message": "Success",
"data": {
"delivery_time": "1600328011517",
"message": "The message was delivered to the user's phone",
"status": 1
},
"error": 0
}

Cấu trúc thuộc tính data

Thuộc tínhKiểu dữ liệuMô tả

delivery_time

string

Thời gian thiết bị của người dùng nhận được tin qua SĐT.

status

int

Trạng thái của tin qua SĐT.

message

string

Mô tả trạng thái tin qua SĐT. Các giá trị trả về:

  • -1: The message does not exist
  • 0: The message is pushed successfully to Zalo server but has not yet delivered to user’s phone
  • 1: The message was delivered to the user's phone