Name:
interface
Value:
Amplify has re-imagined the way frontend developers build fullstack applications. Develop and deploy without the hassle.

Choose your framework/language

Gen1 DocsLegacy

Page updated Mar 26, 2026

メッセージをクリア

AWS will end support for Amazon Pinpoint on October 30, 2026,, and is no longer accepting any new users as of May 20 (see the linked doc). The guidance is to use AWS End User Messaging for push notifications and SMS, Amazon Simple Email Service for sending emails, Amazon Connect for campaigns, journeys, endpoints, and engagement analytics. Pinpoint recommends Amazon Kinesis for event collection and mobile analytics.

メッセージがユーザーのデバイスに同期されたら、clearMessages() を使用して同期されたメッセージをクリアできます。

src/index.js
import { clearMessages } from 'aws-amplify/in-app-messaging';
await clearMessages();

注: アプリに認証機能が実装されている場合は、ユーザーのログイン間で clearMessages() を呼び出して、特定のユーザーセグメント向けのメッセージを削除することをお勧めします。これは、アプリケーションが共有デバイスのシナリオで使用されることが予想される場合に特に重要です。