Amazon Pinpoint 支持终止 - Amazon Pinpoint

终止支持通知:AWS 将于 2026 年 10 月 30 日终止对 Amazon Pinpoint 的支持。2026 年 10 月 30 日之后,您将不再能够访问 Amazon Pinpoint 控制台或 Amazon Pinpoint 资源(端点、客户细分、营销活动、旅程和分析)。有关更多信息,请参阅 Amazon Pinpoint 终止支持注意:与短信、语音、移动推送、OTP 和电话号码验证相关的 API 不受此变更的影响,AWS End User Messaging 支持这些功能。

Amazon Pinpoint 支持终止

经过深思熟虑,我们决定终止对 Amazon Pinpoint 的支持,自 2026 年 10 月 30 日起生效。自 2025 年 5 月 20 日起,Amazon Pinpoint 将不再接受新客户。作为在 2025 年 5 月 20 日之前注册该服务的账户的现有客户,您可以继续使用 Amazon Pinpoint 功能。2026 年 10 月 30 日之后,您将无法再使用 Amazon Pinpoint。

如今,客户将 Amazon Pinpoint 要么用于其参与功能(端点、客户细分、营销活动、旅程和分析),要么用于其消息渠道 API(短信、彩信、推送、WhatsApp 和文本转语音消息功能)。我们已经为这两组客户制定了注销计划。

这对您意味着什么

如果您使用的是 Amazon Pinpoint 参与功能(端点、客户细分、营销活动、旅程和分析),我们建议您迁移到 Amazon Connect 主动参与解决方案(例如 Amazon Connect 对外营销宣传Amazon Connect Customer Profiles),通过统一的绩效跟踪以及使用一个统一应用程序管理对内(例如客户支持)和对外(例如主动沟通)的能力,推动跨渠道的个性化的及时参与。如果您使用的是事件收集和移动分析,我们建议您使用 Amazon Kinesis

Amazon Pinpoint 通信渠道(短信、彩信、推送、WhatsApp 和文本转语音消息传送功能)于 2024 年第 3 季度更名为 AWS End User Messaging,并将继续满足开发者向客户传送消息的需求。此变更不会影响与短信、语音、移动推送、OTP 和电话号码验证相关的 API 的使用。如果您使用 Amazon Pinpoint 发送电子邮件,我们建议您迁移到 Amazon Simple Email Service(SES)。如果您目前在 Amazon Pinpoint 中使用电子邮件送达率控制面板,我们将在 2026 年 10 月 30 日之前在 SES 中提供类似功能。

迁移步骤:Amazon Pinpoint 参与的过渡功能

寻求参与功能的客户

要使用 Amazon Connect 的主动参与功能,包括客户细分、消息模板、营销活动、旅程、分析,请按照本指南操作,将 Amazon Pinpoint 参与功能迁移到 Amazon Connect。

迁移端点和客户细分

Amazon Pinpoint 端点可以建模为 Amazon Connect Customer Profiles。使用 Customer Profiles 可以将多个端点组合成单个配置文件,还可以将多达 3 个电子邮件地址和 4 个电话号码建模为单个配置文件。要迁移您的端点,您可以

  1. 创建不带筛选条件的 Amazon Pinpoint 客户细分,有效地涵盖您的所有端点。

  2. 将该客户细分导出到 S3 存储桶或本地计算机。

  3. 将转换后的端点上传到 Customer Profiles,然后使用 Customer Profiles 的 S3 连接器在 Customer Profiles 中创建数据集成

如果您想将端点聚合到单个客户配置文件下,则可以解析下载的 Amazon Pinpoint 客户细分,以便在单个配置文件下收集电子邮件地址和电话号码。这是一个 Python 脚本示例,用于读取 JSON 格式的导出文件并创建可以导入到 Customer Profiles 中的配置文件。

from collections import defaultdict import json def process_pinpoint_endpoints(input_file, output_file): # Dictionary to store grouped endpoints by user ID grouped_endpoints = defaultdict(list) endpoints = [] # Read the input file with open(input_file, 'r') as file: for line in file: endpoints.append(json.loads(line)) # Group endpoints by user ID for endpoint in endpoints: user_id = endpoint.get('User', {}).get('UserId') if user_id: grouped_endpoints[user_id].append(endpoint) # Convert grouped endpoints to Customer Profiles format # We will assume the userId is stored as an AccountNumber # since the AccountNumber can be queried customer_profiles = [] for user_id, user_endpoints in grouped_endpoints.items(): profile = { 'AccountNumber': user_id, 'Attributes': {}, 'Address': {} } phone_numbers = set() email_addresses = set() output_dict = {} for endpoint in user_endpoints: # Extract attributes attributes = endpoint.get('Attributes', {}) for key, value_list in attributes.items(): if len(value_list) == 1: output_dict[key] = value_list[0] else: for i, item in enumerate(value_list): output_dict[f"{key}_{i}"] = item demographics = endpoint.get('Demographic') for key, value in demographics.items(): attributes[f"Demographic_{key}"] = value location = endpoint.get('Location', {}) profile['Address']['City'] = location['City'] profile['Address']['Country'] = location['Country'] profile['Address']['PostalCode'] = location['PostalCode'] profile['Address']['County'] = location['Region'] profile['Attributes']['Latitude'] = location['Latitude'] profile['Attributes']['Longitude'] = location['Longitude'] metrics = endpoint.get('Metrics', {}) for key, value in metrics.items(): profile['Attributes'][f"Metrics_{key}"] = str(value) user = endpoint.get('User', {}) user_attributes = user.get('UserAttributes', {}) for key, value_list in user_attributes.items(): if len(value_list) == 1: output_dict[key] = value_list[0] else: for i, item in enumerate(value_list): output_dict[f"UserAttributes.{key}_{i}"] = item profile['Attributes'].update(output_dict) # Extract phone number address = endpoint.get('Address') if (endpoint.get('ChannelType') == 'SMS' or endpoint.get('ChannelType') == 'VOICE') and address: phone_numbers.add(address) # Extract email address if endpoint.get('ChannelType') == 'EMAIL' and address: email_addresses.add(address) # Assigning the phone numbers to the different parameters in the Customer Profile for i, phone_number in enumerate(phone_numbers): if i == 0: profile['PhoneNumber'] = phone_number elif i == 1: profile['HomePhoneNumber'] = phone_number elif i == 2: profile['MobilePhoneNumber'] = phone_number elif i == 3: profile['BusinessPhoneNumber'] = phone_number else: profile['Attributes'][f"PhoneNumber_{i}"] = phone_number # Assigning the email addresses to the different parameters in the Customer Profile for i, email_address in enumerate(email_addresses): if i == 0: profile['EmailAddress'] = email_address elif i == 1: profile['PersonalEmailAddress'] = email_address elif i == 2: profile['BusinessEmailAddress'] = email_address else: profile['Attributes'][f"EmailAddress_{i}"] = email_address customer_profiles.append(profile) # Write the output to a file with open(output_file, 'w') as f: json.dump(customer_profiles, f, indent=2) print(f"Processed {len(endpoints)} endpoints into {len(customer_profiles)} customer profiles.") # Example usage input_file = 'pinpoint_endpoints.json' output_file = 'customer_profiles.json' process_pinpoint_endpoints(input_file, output_file)

迁移频道配置

按照入门步骤的说明,在 Amazon Connect 中启用短信电子邮件通信。

迁移模板

Amazon Connect 中的模板使用与 Amazon Pinpoint 相同的消息呈现引擎(Handlebars)。但是,属性占位符的表示方式有所不同。

  1. 您可以使用我们现有的 Amazon Pinpoint API 来提取模板(例如,get-email-templateget-sms-template)。或者,您可以按照本指南编辑模板,以便复制其内容。

  2. 提取模板后,更新其占位符。例如,您之前的 Amazon Pinpoint 模板使用了类似 {{User.UserAttributes.PurchaseHistory}} 的占位符。现在可以将这些占位符更改为 {{Attributes.Customer.Attributes.PurchaseHistory}}

  3. 接下来,在 Amazon Q in Connect 中使用 create-message-template API 创建模板,或者遵循本指南创建消息模板。

要映射您的属性,请遵循之前将端点映射到配置文件时所做的映射(前缀为 Attributes.Customer)。

迁移营销活动

对于每个营销活动,我们建议您使用 get-campaign API 来提取其定义,然后使用营销活动创建指南在 Amazon Connect 中重新创建。

迁移旅程

Amazon Connect 尚未完全支持旅程。如果可以使用 Amazon Connect 营销活动解决您的旅程使用案例,我们建议您评估这些使用案例。如果可以解决,请按照与上述类似的方法使用 get-journey API 提取其定义,然后使用《营销活动创建指南》在 Amazon Connect 中重新创建该定义。

事件收集和移动分析客户

Amplify SDK 客户

如果您使用 Amplify SDK 向 Amazon Pinpoint 发送事件以更新端点、触发营销活动或旅程或者分析应用程序的使用情况,则可以迁移到使用 Kinesis。使用 Kinesis 可以将事件流式传输到您选择的计算平台,让事件向 Customer Profiles 发送更新,从而更新应用程序用户的配置文件并触发 Amazon Connect 活动。

Put-Events 客户

如果您仅使用 Amazon Pinpoint 将事件从您的网络/移动应用程序流式传输到 Kinesis 流,则您现在可以使用 Amplify SDK 将事件直接流式传输到 Kinesis。

不可用的功能

截至目前,以下 Amazon Pinpoint 参与功能在 Amazon Connect 中尚不可用。

  • 应用程序内消息

  • 在营销活动中推送(GCM、APNS、百度等)通知

  • 自定义渠道

  • 已导入客户细分

  • 历程

注销步骤:将数据导出到第三方

如果您想删除所有 Amazon Pinpoint 数据,请随时直接使用 delete-app API 删除应用程序。之后,请遵循关于删除模板的本指南来删除所有未使用的消息模板。

或者,如果要提取所有资源并进行存储,请按照以下步骤操作。

了解如何查看、监控和管理 SageMaker 端点。

要注销端点,您可以

  • 创建不带筛选条件的 Amazon Pinpoint 客户细分,有效地涵盖您的所有端点。

  • 将该客户细分导出到 S3 存储桶或本地计算机。

客户细分、营销活动和旅程

要将您的客户细分、营销活动和旅程排除在外,请使用我们的 API 或 UI 对它们进行检索。为此,您可以使用我们的 get-segmentget-campaignget-journey API。

消息模板

要注销模板,您可以使用 list-templates API,然后使用特定于渠道的 API:

Amazon Pinpoint 和移动分析

要从 Amazon Pinpoint Analytics 或 Mobile Analytics 中注销您的事件和 KPI,您可以使用以下选项:

  1. 要在迁移之前导出将来的原始事件,客户可以加入事件数据流。

  2. 客户可以使用以下命令导出过去 3 个月的 KPI:

对于需要在迁移过程中删除 Mobile Analytics 应用程序的客户,您可以使用以下 Python 脚本。此脚本使用 AWS 签名版本 4 通过 Mobile Analytics API 进行身份验证。

  1. 请将以下脚本保存为 delete_mobile_analytics_application.py

    # Copyright 2010-2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. # # This file is licensed under the Apache License, Version 2.0 (the "License"). # You may not use this file except in compliance with the License. A copy of the # License is located at # # http://aws.amazon.com/apache2.0/ # # This file is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS # OF ANY KIND, either express or implied. See the License for the specific # language governing permissions and limitations under the License. # # ABOUT THIS PYTHON SAMPLE: This sample is part of the AWS General Reference # Signing AWS API Requests top available at # https://docs.aws.amazon.com/general/latest/gr/sigv4-signed-request-examples.html # # AWS Version 4 signing example # Delete Mobile Analytics application # See: http://docs.aws.amazon.com/general/latest/gr/sigv4_signing.html # This version makes a DELETE request and passes the signature # in the Authorization header. import sys, os, base64, datetime, hashlib, hmac import requests # pip install requests import argparse # Parse command line arguments parser = argparse.ArgumentParser(description='Delete a Mobile Analytics application') parser.add_argument('--appId', type=str, help='Mobile Analytics application ID to be deleted', required=True) args = parser.parse_args() # ************* REQUEST VALUES ************* delimiter = "/" method = 'DELETE' service = 'mobileanalytics' host = 'mobileanalytics.us-east-1.amazonaws.com' region = 'us-east-1' appId = args.appId # Use the appId from command line arguments endpoint = 'https://mobileanalytics.us-east-1.amazonaws.com/2016-07-01/apps' + delimiter + appId request_parameters = '' # Function for signing. Refer the AWS documentation below for more details. # http://docs.aws.amazon.com/general/latest/gr/signature-v4-examples.html#signature-v4-examples-python def sign(key, msg): return hmac.new(key, msg.encode('utf-8'), hashlib.sha256).digest() # Function for computing signature key. Refer the AWS documentation below for more details. # http://docs.aws.amazon.com/general/latest/gr/signature-v4-examples.html#signature-v4-examples-python. def getSignatureKey(key, dateStamp, regionName, serviceName): kDate = sign(('AWS4' + key).encode('utf-8'), dateStamp) kRegion = sign(kDate, regionName) kService = sign(kRegion, serviceName) kSigning = sign(kService, 'aws4_request') return kSigning # Read AWS access key from environment variables or configuration file. Best practice is NOT # to embed credentials in code. access_key = os.environ.get('AWS_ACCESS_KEY_ID') secret_key = os.environ.get('AWS_SECRET_ACCESS_KEY') session_token = os.environ.get('AWS_SESSION_TOKEN') if access_key is None or secret_key is None: print('No access key is available.') sys.exit() # Create a date for headers and the credential string t = datetime.datetime.now(datetime.UTC) amzdate = t.strftime('%Y%m%dT%H%M%SZ') datestamp = t.strftime('%Y%m%d') # Date w/o time, used in credential scope # ************* TASK 1: CREATE A CANONICAL REQUEST ************* # http://docs.aws.amazon.com/general/latest/gr/sigv4-create-canonical-request.html # Step 1 is to define the verb (GET, POST, etc.)--already done with defining "method" variable above. # Step 2: Create canonical URI--the part of the URI from domain to query # string (use '/' if no path) canonical_uri = '/2016-07-01/apps' + delimiter + appId # Step 3: Create the canonical query string. In this example (a DELETE request), # request parameters are in the query string. Query string values must # be URL-encoded (space=%20). The parameters must be sorted by name. # For this example, the query string is pre-formatted in the request_parameters variable. canonical_querystring = request_parameters # Step 4: Create the canonical headers and signed headers. Header names # must be trimmed and lowercase, and sorted in code point order from # low to high. Note that there is a trailing \n. canonical_headers = 'host:' + host + '\n' + 'x-amz-date:' + amzdate + '\n' # Step 5: Create the list of signed headers. This lists the headers # in the canonical_headers list, delimited with ";" and in alpha order. # Note: The request can include any headers; canonical_headers and # signed_headers lists those that you want to be included in the # hash of the request. "Host" and "x-amz-date" are always required. signed_headers = 'host;x-amz-date' # Step 6: Create payload hash (hash of the request body content). For GET # requests, the payload is an empty string (""). payload_hash = hashlib.sha256(request_parameters.encode('utf-8')).hexdigest() # Step 7: Combine elements to create canonical request canonical_request = method + '\n' + canonical_uri + '\n' + canonical_querystring + '\n' + canonical_headers + '\n' + signed_headers + '\n' + payload_hash # ************* TASK 2: CREATE THE STRING TO SIGN************* # Match the algorithm to the hashing algorithm you use, either SHA-1 or # SHA-256 (recommended) algorithm = 'AWS4-HMAC-SHA256' credential_scope = datestamp + '/' + region + '/' + service + '/' + 'aws4_request' string_to_sign = algorithm + '\n' + amzdate + '\n' + credential_scope + '\n' + hashlib.sha256( canonical_request.encode('utf-8')).hexdigest() # ************* TASK 3: CALCULATE THE SIGNATURE ************* # Create the signing key using the function defined above. signing_key = getSignatureKey(secret_key, datestamp, region, service) # Compute signature by invoking hmac.new method by passing signingkey, string_to_sign signature = hmac.new(signing_key, string_to_sign.encode('utf-8'), hashlib.sha256).hexdigest() # ************* TASK 4: ADD SIGNING INFORMATION TO THE REQUEST ************* # The signing information can be either in a query string value or in # a header named Authorization. This code shows how to use a header. # Create authorization header and add to request headers authorization_header = algorithm + ' ' + 'Credential=' + access_key + '/' + credential_scope + ', ' + 'SignedHeaders=' + signed_headers + ', ' + 'Signature=' + signature # The request can include any headers, but MUST include "host", "x-amz-date", # and (for this scenario) "Authorization". "host" and "x-amz-date" must # be included in the canonical_headers and signed_headers, as noted # earlier. Order here is not significant. # Python note: The 'host' header is added automatically by the Python 'requests' library. headers = { 'x-amz-date': amzdate, 'accept': 'application/hal+json', 'content-type': 'application/json; charset=UTF-8', 'Authorization': authorization_header} if session_token: headers['X-Amz-Security-Token'] = session_token # ************* SEND THE REQUEST ************* request_url = endpoint + '?' + canonical_querystring print('\nBEGIN REQUEST++++++++++++++++++++++++++++++++++++') print('Request URL = ' + request_url) print('Request Headers = ', headers) r = requests.delete(request_url, data=request_parameters, headers=headers) print('\nRESPONSE++++++++++++++++++++++++++++++++++++') print('Response code: %d\n' % r.status_code) print(r.text)
  2. 确保将有效的 AWS 凭证设置为环境变量。

  3. 使用您的 Mobile Analytics 应用程序 ID 运行脚本:

    python delete_mobile_analytics_application.py --appId <YOUR_MOBILE_ANALYTICS_APP_ID>

此脚本向 Mobile Analytics API 发出移除指定应用程序的 DELETE 请求。请务必为需要删除的每个 Mobile Analytics 应用程序运行此脚本。

注意

在 Amazon Pinpoint 终止支持日期之前,活跃的 Mobile Analytics 客户可以继续通过 putEvents API 摄取事件,并在 Amazon Pinpoint 中查看事件。

摘要

拥有至少一个 Amazon Pinpoint 账户的组织可以继续使用 Amazon Pinpoint 参与功能,包括客户细分、营销活动、旅程、分析和电子邮件,直到 2026 年 10 月 30 日该服务的支持终止时为止。

其他资源

还提供有以下资源:

如果您需要协助或有反馈,请联系 AWS 支持