Nhảy tới nội dung

Bắt đầu hỗ trợ ở phiên bản:

  • API: 2.5.3
Lưu ý

Với API version ﹤ 2.23.0, phải gọi api login trước khi gọi api này và cần xin cấp quyền tại trang Quản lý ứng dụng

Cho phép ứng dụng hiển thị giao diện yêu cầu bỏ theo dõi Official Account để người dùng xác nhận.

Parameters

Object object

PropertyTypeDefaultRequiredDescriptionMinimum Version
idstringtrueId của Official Account
successfunctionCallback function khi gọi api thành công
failfunctionCallback function khi gọi api thất bại

Sample Code

import { unfollowOA } from "zmp-sdk/apis";

const unfollow = () => {
unfollowOA({
id: "xxxx",
success: (res) => {},
fail: (err) => {},
});
};

Hoặc

import { unfollowOA } from "zmp-sdk/apis";

const unfollow = async () => {
try {
const res = await unfollowOA({
id: "xxxx",
});
} catch (error) {
// xử lý khi gọi api thất bại
console.log(error);
}
};