openharmony 鸿蒙 js-apis-reminderAgentManager-sys

2025-06-12 浏览 (1)

@ohos.reminderAgentManager (Agent-Powered Reminders) (System API)

The reminderAgentManager module provides APIs related to agent-powered reminders. When your application is frozen or exits, the timing and notification functions of your application will be taken over by a system service running in the background. You can use the APIs to create scheduled reminders for countdown timers, calendar events, and alarm clocks.

NOTE

The initial APIs of this module are supported since API version 9. Newly added APIs will be marked with a superscript to indicate their earliest API version.

This topic describes only system APIs provided by the module. For details about its public APIs, see @ohos.reminderAgentManager (Agent-Powered Reminders).

Modules to Import

import reminderAgentManager from '@ohos.reminderAgentManager';

ActionButtonType

Enumerates the button types.

System capability: SystemCapability.Notification.ReminderAgent

NameValueDescription
ACTION_BUTTON_TYPE_CUSTOM10+2Custom button.

ActionButton

Defines the button on the reminder displayed.

System capability: SystemCapability.Notification.ReminderAgent

NameTypeMandatoryDescription
wantAgent10+WantAgentNoInformation about the ability that is displayed after the button is clicked.
dataShareUpdate11+DataShareUpdateNoThe application database will be updated after a click on the button.

DataShareUpdate11+

Defines the parameter information used to update the database.

The data provider needs to set the ID, read/write permissions, and basic information of the table to be shared under proxyDatas in the module.json5 file. For details about the configuration method, see Data Proxy.

System capability: SystemCapability.Notification.ReminderAgent

NameTypeMandatoryDescription
uristringYesURI of the data, which is the unique identifier for cross-application data access.
equalToRecord<string, number |string |boolean>YesFilter criteria. Currently, only equal to is supported.
valueValueBucketYesNew data.

ReminderRequestCalendar

Defines a reminder for a calendar event.

System capability: SystemCapability.Notification.ReminderAgent

NameTypeMandatoryDescription
rruleWantAgent12+WantAgentNoCustom reminder, which specifies the ServiceExtensionAbility to start.

你可能感兴趣的鸿蒙文章

harmony 鸿蒙Background Tasks Kit

harmony 鸿蒙BackgroundProcessManager

harmony 鸿蒙TransientTask

harmony 鸿蒙TransientTask_DelaySuspendInfo

harmony 鸿蒙background_process_manager.h

harmony 鸿蒙DeviceUsageStatistics Error Codes

harmony 鸿蒙backgroundTaskManager Error Codes

harmony 鸿蒙reminderAgentManager Error Codes

harmony 鸿蒙workScheduler Error Codes

harmony 鸿蒙@ohos.WorkSchedulerExtensionAbility (Deferred Task Scheduling Callbacks)

  • 所属分类: 后端技术
  • 本文标签: 软件 鸿蒙
  • 版权声明: 本文链接 https://seaxiang.com/blog/3MhF6U