createReminder
Tạo nhắc hẹn
api.createReminder(options, threadId[, type])
Parameters
options
CreateReminderOptions
threadId
string
type
ThreadType?
mặc định
ThreadType.User
Return
Promise<CreateReminderResponse>
Types
export type CreateReminderOptions = {
title: string;
emoji?: string;
startTime?: number;
repeat?: ReminderRepeatMode;
};
export type CreateReminderUser = ReminderUser;
export type CreateReminderGroup = Omit<ReminderGroup, "responseMem">;
export type CreateReminderResponse = CreateReminderUser | CreateReminderGroup;
Examples
const startTime = new Date();
startTime.setHours(22, 0, 0, 0);
api
.createReminder({
title: "Đến hẹn đi ăn tối.",
startTime: startTime.getTime()
})
.then(console.log)
.catch(console.error);
Related
Last updated