AWS パートナーセントラル API リファレンスが再構築されました。サポートされている API オペレーションの詳細については、 AWS パートナーセントラル API リファレンスを参照してください。
翻訳は機械翻訳により提供されています。提供された翻訳内容と英語版の間で齟齬、不一致または矛盾がある場合、英語版が優先します。
AWS Partner Central Channel API の通知
チャネル API のイベントは、ステータスの変更やチャネル関連のアクティビティの詳細に関するリアルタイムの通知を提供します。これらのイベントは、システムをAWS Partner Central と同期させ、タイムリーな応答と更新を確保するのに役立ちます。
前提条件
AWS Partner Central Channel API からイベントにアクセスして管理するには、適切な IAM アクセス許可が必要です。EventBridge で使用可能なアクション、リソース、および条件キーの詳細については、「Amazon EventBridge ユーザーガイド」の「Amazon EventBridge での IAM ポリシー条件EventBridge」を参照してください。条件キーの 1 つは です。これを使用してevents:detail-type、特定のイベントタイプにアクセス許可の範囲を設定できます。
次のポリシー例は、イベントのアクセス許可をカスタマイズして範囲を設定する方法を示しています。AllowPutRuleForPartnercentralChannelEvents ステートメントは、aws.partnercentral-channelソースからのイベントに対してのみ、ルールの作成を許可します。
IAM ポリシーの詳細な例については、EventBridge アクセス許可に関する AWS ドキュメントを参照してください。
{ "Version": "2012-10-17", "Statement": [ { "Sid": "AllowPutRuleForPartnerCentralChannelEvents", "Effect": "Allow", "Action": "events:PutRule", "Resource": "*", "Condition": { "StringEquals": { "events:source": "aws.partnercentral-channel" } } } ] }
イベントをモニタリングするように Amazon EventBridge を設定する
チャネル API イベントをモニタリングするには、キャプチャするイベントに一致する EventBridge ルールを作成します。AWS Management ConsoleまたはAWS SDKs を使用して、ルールを作成および管理できます。以下のセクションでは、両方の方法を使用してルールを作成する方法について説明します。使用する方法にかかわらず、米国東部 (バージニア北部) us-east-1リージョンでルールを作成する必要があります。
AWS Management Consoleセットアップ
を使用して EventBridge ルールを設定するにはAWS Management Console、「Amazon EventBridge ユーザーガイド」の「Amazon EventBridge のイベントに対応するルールの作成EventBridge」の手順に従います。ルールを作成するときは、イベントバスをデフォルトに設定し、米国東部 (バージニア北部) us-east-1リージョンでルールを作成する必要があります。
イベントルールの例を次に示します。
{ "source": ["aws.partnercentral-channel"], "detail": { "catalog": ["AWS"] } }
AWS SDK のセットアップ
AWS SDKs を使用して、プログラムで EventBridge ルールを作成および管理できます。詳細については、「Amazon EventBridge API リファレンス」の「PutRule」を参照してください。
次の例では、AWS SDK for Python (Boto3) を使用しています。
import boto3 client = boto3.client('events', region_name='us-east-1') response = client.put_rule( Name='ChannelHandshakeCreatedRule', EventPattern= '{ "source": ["aws.partnercentral-channel"], "detail-type": ["Channel Handshake Created"], "detail": {"catalog": ["AWS"]} }', State='ENABLED' ) print('Rule ARN:', response['RuleArn'])
チャネル API イベントの詳細
以下のセクションでは、チャネル API イベントタイプ、それらをトリガーするシナリオ、およびイベント例について説明します。
イベントタイプ
以下は、イベントタイプとそのトリガーです。
-
チャネルハンドシェイクの作成: 新しいチャネルハンドシェイクの作成時にトリガーされます。
-
Channel Handshake Accepted: 新しいチャネルハンドシェイクが受け入れられるとトリガーされます。
-
チャネルハンドシェイクが拒否されました: 新しいチャネルハンドシェイクが拒否されるとトリガーされます。
作成されたチャネルハンドシェイク
次の例は、さまざまなハンドシェイクタイプの一般的なチャネルハンドシェイク作成イベントを示しています。
サービス期間ハンドシェイクの開始:
{ "version": "0", "id": "01234567-0123-0123-0123-0123456789ab", "detail-type": "Channel Handshake Created", "source": "aws.partnercentral-channel", "account": "789789789789", "time": "2025-02-01T00:00:00Z", "region": "us-east-1", "resources": [ "arn:aws:partnercentral:us-east-1:123123123123:catalog/AWS/channel-handshake/ch-abc123def456g" ], "detail": { "requestId": "12345678-1234-1234-1234-123456789abc", "catalog": "AWS", "associatedResourceIdentifier": "rs-jkl012mno345p", "handshakeType": "START_SERVICE_PERIOD", "id": "ch-abc123def456g", "receiverAccountId": "789789789789", "ownerAccountId": "123123123123", "senderAccountId": "456456456456", "senderDisplayName": "TestDisplayName", "handshakeDetail": { "startServicePeriodHandshakeDetail": { "servicePeriodType": "MINIMUM_NOTICE_PERIOD", "minimumNoticeDays": "14", "endDate": null, "startDate": "2025-02-02T00:00:00Z", "note": "Test note example" } } } }
サービス期間のハンドシェイクを取り消す:
{ "version": "0", "id": "01234567-0123-0123-0123-0123456789ab", "detail-type": "Channel Handshake Created", "source": "aws.partnercentral-channel", "account": "789789789789", "time": "2025-02-01T00:00:00Z", "region": "us-east-1", "resources": [ "arn:aws:partnercentral:us-east-1:123123123123:catalog/AWS/channel-handshake/ch-def456ghi789j" ], "detail": { "requestId": "12345678-1234-1234-1234-123456789abc", "catalog": "AWS", "associatedResourceIdentifier": "rs-jkl012mno345p", "handshakeType": "REVOKE_SERVICE_PERIOD", "id": "ch-def456ghi789j", "ownerAccountId": "123123123123", "receiverAccountId": "789789789789", "senderAccountId": "456456456456", "senderDisplayName": "TestDisplayName", "handshakeDetail": { "revokeServicePeriodHandshakeDetail": { "servicePeriodType": "MINIMUM_NOTICE_PERIOD", "minimumNoticeDays": "14", "endDate": null, "startDate": "2025-02-02T00:00:00Z", "note": "Test note example" } } } }
プログラム管理アカウントのハンドシェイク:
{ "version": "0", "id": "01234567-0123-0123-0123-0123456789ab", "detail-type": "Channel Handshake Created", "source": "aws.partnercentral-channel", "account": "456456456456", "time": "2025-02-01T00:00:00Z", "region": "us-east-1", "resources": [ "arn:aws:partnercentral:us-east-1:123123123123:catalog/AWS/channel-handshake/ch-ghi789jkl012m" ], "detail": { "requestId": "12345678-1234-1234-1234-123456789abc", "catalog": "AWS", "associatedResourceIdentifier": "pma-abc123def456g", "handshakeType": "PROGRAM_MANAGEMENT_ACCOUNT", "id": "ch-ghi789jkl012m", "ownerAccountId": "123123123123", "receiverAccountId": "456456456456", "senderAccountId": "123123123123", "senderDisplayName": "TestDisplayName", "handshakeDetail": { "programManagementAccountHandshakeDetail": { "program": "SOLUTION_PROVIDER" } } } }
チャネルハンドシェイクが受け入れられました
次の例は、さまざまなハンドシェイクタイプの一般的な Channel Handshake Accepted イベントを示しています。
サービス期間ハンドシェイクの開始:
{ "version": "0", "id": "01234567-0123-0123-0123-0123456789ab", "detail-type": "Channel Handshake Accepted", "source": "aws.partnercentral-channel", "account": "123123123123", "time": "2025-02-01T00:00:00Z", "region": "us-east-1", "resources": [ "arn:aws:partnercentral:us-east-1:123123123123:catalog/AWS/channel-handshake/ch-abc123def456g" ], "detail": { "requestId": "12345678-1234-1234-1234-123456789abc", "catalog": "AWS", "associatedResourceIdentifier": "rs-jkl012mno345p", "handshakeType": "START_SERVICE_PERIOD", "id": "ch-abc123def456g", "ownerAccountId": "123123123123", "receiverAccountId": "789789789789", "senderAccountId": "456456456456", "senderDisplayName": "TestDisplayName", "handshakeDetail": { "startServicePeriodHandshakeDetail": { "servicePeriodType": "MINIMUM_NOTICE_PERIOD", "minimumNoticeDays": "14", "endDate": null, "startDate": "2025-02-02T00:00:00Z", "note": "Test note example" } } } }
サービス期間のハンドシェイクを取り消す:
{ "version": "0", "id": "01234567-0123-0123-0123-0123456789ab", "detail-type": "Channel Handshake Accepted", "source": "aws.partnercentral-channel", "account": "123123123123", "time": "2025-02-01T00:00:00Z", "region": "us-east-1", "resources": [ "arn:aws:partnercentral:us-east-1:123123123123:catalog/AWS/channel-handshake/ch-def456ghi789j" ], "detail": { "requestId": "12345678-1234-1234-1234-123456789abc", "catalog": "AWS", "associatedResourceIdentifier": "rs-jkl012mno345p", "handshakeType": "REVOKE_SERVICE_PERIOD", "id": "ch-def456ghi789j", "ownerAccountId": "123123123123", "receiverAccountId": "789789789789", "senderAccountId": "456456456456", "senderDisplayName": "TestDisplayName", "handshakeDetail": { "revokeServicePeriodHandshakeDetail": { "servicePeriodType": "MINIMUM_NOTICE_PERIOD", "minimumNoticeDays": "14", "endDate": null, "startDate": "2025-02-02T00:00:00Z", "note": "Test note example" } } } }
プログラム管理アカウントのハンドシェイク:
{ "version": "0", "id": "01234567-0123-0123-0123-0123456789ab", "detail-type": "Channel Handshake Accepted", "source": "aws.partnercentral-channel", "account": "123123123123", "time": "2025-02-01T00:00:00Z", "region": "us-east-1", "resources": [ "arn:aws:partnercentral:us-east-1:123123123123:catalog/AWS/channel-handshake/ch-ghi789jkl012m" ], "detail": { "requestId": "12345678-1234-1234-1234-123456789abc", "catalog": "AWS", "associatedResourceIdentifier": "pma-abc123def456g", "handshakeType": "PROGRAM_MANAGEMENT_ACCOUNT", "id": "ch-ghi789jkl012m", "ownerAccountId": "123123123123", "receiverAccountId": "456456456456", "senderAccountId": "123123123123", "senderDisplayName": "TestDisplayName", "handshakeDetail": { "programManagementAccountHandshakeDetail": { "program": "SOLUTION_PROVIDER" } } } }
チャネルハンドシェイクが拒否されました
次の例は、さまざまなハンドシェイクタイプの一般的なチャネルハンドシェイク拒否イベントを示しています。
サービス期間ハンドシェイクの開始:
{ "version": "0", "id": "01234567-0123-0123-0123-0123456789ab", "detail-type": "Channel Handshake Rejected", "source": "aws.partnercentral-channel", "account": "123123123123", "time": "2025-02-01T00:00:00Z", "region": "us-east-1", "resources": [ "arn:aws:partnercentral:us-east-1:123123123123:catalog/AWS/channel-handshake/ch-abc123def456g" ], "detail": { "requestId": "12345678-1234-1234-1234-123456789abc", "catalog": "AWS", "associatedResourceIdentifier": "rs-jkl012mno345p", "handshakeType": "START_SERVICE_PERIOD", "id": "ch-abc123def456g", "ownerAccountId": "123123123123", "receiverAccountId": "789789789789", "senderAccountId": "456456456456", "senderDisplayName": "TestDisplayName", "handshakeDetail": { "startServicePeriodHandshakeDetail": { "servicePeriodType": "MINIMUM_NOTICE_PERIOD", "minimumNoticeDays": "14", "endDate": null, "startDate": "2025-02-02T00:00:00Z", "note": "Test note example" } } } }
サービス期間のハンドシェイクを取り消す:
{ "version": "0", "id": "01234567-0123-0123-0123-0123456789ab", "detail-type": "Channel Handshake Rejected", "source": "aws.partnercentral-channel", "account": "123123123123", "time": "2025-02-01T00:00:00Z", "region": "us-east-1", "resources": [ "arn:aws:partnercentral:us-east-1:123123123123:catalog/AWS/channel-handshake/ch-def456ghi789j" ], "detail": { "requestId": "12345678-1234-1234-1234-123456789abc", "catalog": "AWS", "associatedResourceIdentifier": "rs-jkl012mno345p", "handshakeType": "REVOKE_SERVICE_PERIOD", "id": "ch-def456ghi789j", "ownerAccountId": "123123123123", "receiverAccountId": "789789789789", "senderAccountId": "456456456456", "senderDisplayName": "TestDisplayName", "handshakeDetail": { "revokeServicePeriodHandshakeDetail": { "servicePeriodType": "MINIMUM_NOTICE_PERIOD", "minimumNoticeDays": "14", "endDate": null, "startDate": "2025-02-02T00:00:00Z", "note": "Test note example" } } } }
プログラム管理アカウントハンドシェイク:
{ "version": "0", "id": "01234567-0123-0123-0123-0123456789ab", "detail-type": "Channel Handshake Rejected", "source": "aws.partnercentral-channel", "account": "123123123123", "time": "2025-02-01T00:00:00Z", "region": "us-east-1", "resources": [ "arn:aws:partnercentral:us-east-1:123123123123:catalog/AWS/channel-handshake/ch-ghi789jkl012m" ], "detail": { "requestId": "12345678-1234-1234-1234-123456789abc", "catalog": "AWS", "associatedResourceIdentifier": "pma-abc123def456g", "handshakeType": "PROGRAM_MANAGEMENT_ACCOUNT", "id": "ch-ghi789jkl012m", "ownerAccountId": "123123123123", "receiverAccountId": "456456456456", "senderAccountId": "123123123123", "senderDisplayName": "TestDisplayName", "handshakeDetail": { "programManagementAccountHandshakeDetail": { "program": "SOLUTION_PROVIDER" } } } }