{"id":1278,"date":"2018-08-06T08:00:14","date_gmt":"2018-08-05T23:00:14","guid":{"rendered":"https:\/\/www.itc109.com\/knowledge\/?p=1278"},"modified":"2021-09-30T08:58:39","modified_gmt":"2021-09-29T23:58:39","slug":"get-aws-sns-topic","status":"publish","type":"post","link":"https:\/\/www.itc109.com\/knowledge\/aws\/get-aws-sns-topic","title":{"rendered":"AWS &#8211; SNS\u30c8\u30d4\u30c3\u30af\u60c5\u5831\u306e\u53d6\u5f97"},"content":{"rendered":"<h4><strong>\u6982\u8981<\/strong><\/h4>\n<p>SNS\u306e\u60c5\u5831\u3092\u53d6\u5f97\u3059\u308b\u65b9\u6cd5\u306b\u3064\u3044\u3066\u8a18\u8f09\u3057\u3066\u3044\u307e\u3059\u3002<\/p>\n<blockquote>\n<p><strong>Amazon Simple Notification Service (SNS)<\/strong><br \/>\nAmazon Simple Notification Service (SNS) \u306f\u67d4\u8edf\u306a\u30d5\u30eb\u30de\u30cd\u30fc\u30b8\u30c9\u578b\u306e\u00a0<a href=\"https:\/\/aws.amazon.com\/jp\/pub-sub-messaging\/\">pub\/sub \u30e1\u30c3\u30bb\u30fc\u30b8\u30f3\u30b0<\/a>\/\u30e2\u30d0\u30a4\u30eb\u901a\u77e5\u30b5\u30fc\u30d3\u30b9\u3067\u3001\u767b\u9332\u4e2d\u306e\u30a8\u30f3\u30c9\u30dd\u30a4\u30f3\u30c8\u3084\u30af\u30e9\u30a4\u30a2\u30f3\u30c8\u306b\u914d\u4fe1\u3059\u308b\u30e1\u30c3\u30bb\u30fc\u30b8\u3092\u8abf\u6574\u3067\u304d\u307e\u3059\u3002SNS \u3092\u4f7f\u7528\u3059\u308b\u3068\u3001\u5206\u6563\u30b7\u30b9\u30c6\u30e0\u3084\u30b5\u30fc\u30d3\u30b9\u3001\u30e2\u30d0\u30a4\u30eb\u30c7\u30d0\u30a4\u30b9\u306a\u3069\u3001\u591a\u6570\u306e\u53d7\u4fe1\u8005\u306b\u30e1\u30c3\u30bb\u30fc\u30b8\u3092\u30d5\u30a1\u30f3\u30a2\u30a6\u30c8\u3059\u308b\u3053\u3068\u304c\u3067\u304d\u307e\u3059\u3002\u4efb\u610f\u306e\u898f\u6a21\u306e\u3059\u3079\u3066\u306e\u30a8\u30f3\u30c9\u30dd\u30a4\u30f3\u30c8\u3067\u901a\u77e5\u3092\u30bb\u30c3\u30c8\u30a2\u30c3\u30d7\u3001\u64cd\u4f5c\u3001\u304a\u3088\u3073\u78ba\u5b9f\u306b\u9001\u4fe1\u3067\u304d\u307e\u3059\u3002AWS \u30de\u30cd\u30b8\u30e1\u30f3\u30c8\u30b3\u30f3\u30bd\u30fc\u30eb\u3001AWS \u30b3\u30de\u30f3\u30c9\u30e9\u30a4\u30f3\u30a4\u30f3\u30bf\u30fc\u30d5\u30a7\u30a4\u30b9\u3001\u307e\u305f\u306f AWS SDK \u306e\u308f\u305a\u304b 3 \u3064\u306e\u30b7\u30f3\u30d7\u30eb\u306a API \u3092\u4f7f\u7528\u3057\u3066\u3001\u307b\u3093\u306e\u6570\u5206\u3067 SNS \u3092\u4f7f\u3044\u59cb\u3081\u308b\u3053\u3068\u304c\u3067\u304d\u307e\u3059\u3002SNS \u3092\u4f7f\u7528\u3059\u308b\u3053\u3068\u306b\u3088\u308a\u3001\u5c02\u7528\u30e1\u30c3\u30bb\u30fc\u30b8\u30f3\u30b0\u30bd\u30d5\u30c8\u30a6\u30a7\u30a2\u3084\u30a4\u30f3\u30d5\u30e9\u30b9\u30c8\u30e9\u30af\u30c1\u30e3\u306e\u7ba1\u7406\u3084\u904b\u7528\u306b\u95a2\u9023\u3057\u305f\u8907\u96d1\u3055\u3084\u30aa\u30fc\u30d0\u30fc\u30d8\u30c3\u30c9\u304c\u6392\u9664\u3055\u308c\u307e\u3059\u3002\u00a0<\/p>\n<\/blockquote>\n<p>&nbsp;<\/p>\n<h4><strong>\u624b\u9806<\/strong><\/h4>\n<div class=\"hcb_wrap\">\n<pre class=\"prism line-numbers lang-plain\" data-lang=\"Plain Text\"><code>aws sns list-subscriptions<\/code><\/pre>\n<\/div>\n<p>\u5b9f\u884c\u7d50\u679c <strong>TEXT<\/strong><\/p>\n<div class=\"hcb_wrap\">\n<pre class=\"prism line-numbers lang-plain\" data-lang=\"Plain Text\"><code>SUBSCRIPTIONS warning@example.com 987654321000 email arn:aws:sns:ap-northeast-1:987654321000:warning:c988b83*-57c*-4b1*-abd*-bd6e3af9638* arn:aws:sns:ap-northeast-1:987654321000:warning SUBSCRIPTIONS info@example.com 987654321000 email arn:aws:sns:ap-northeast-1:987654321000:info:cb8b1bd*-aab*-486*-a0b*-d6ae24ed31a* arn:aws:sns:ap-northeast-1:987654321000:info SUBSCRIPTIONS critical@example.com 987654321000 email arn:aws:sns:ap-northeast-1:987654321000:critical:f3a2aee*-98a*-455*-9eb*-d9aca773717* arn:aws:sns:ap-northeast-1:987654321000:critical<\/code><\/pre>\n<\/div>\n<p><strong>TABLE<\/strong><\/p>\n<div class=\"hcb_wrap\">\n<pre class=\"prism line-numbers lang-plain\" data-lang=\"Plain Text\"><code>--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------\r\n|                                                                                           ListSubscriptions                                                                                          |\r\n+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+\r\n||                                                                                            Subscriptions                                                                                           ||\r\n|+-----------------------+---------------+-----------+------------------------------------------------------------------------------------------+-----------------------------------------------------+|\r\n||       Endpoint        |     Owner     | Protocol  |                                     SubscriptionArn                                      |                      TopicArn                       ||\r\n|+-----------------------+---------------+-----------+------------------------------------------------------------------------------------------+-----------------------------------------------------+|\r\n||  warning@example.com   |  987654321000 |  email    |  arn:aws:sns:ap-northeast-1:987654321000:warning:c988b83*-57c*-4b1*-abd*-bd6e3af9638*    |  arn:aws:sns:ap-northeast-1:987654321000:warning    ||\r\n||  info@example.com      |  987654321000 |  email    |  arn:aws:sns:ap-northeast-1:987654321000:info:cb8b1bd*-aab*-486*-a0b*-d6ae24ed31a*       |  arn:aws:sns:ap-northeast-1:987654321000:info       ||\r\n||  critical@example.com  |  987654321000 |  email    |  arn:aws:sns:ap-northeast-1:987654321000:critical:f3a2aee*-98a*-455*-9eb*-d9aca773717*   |  arn:aws:sns:ap-northeast-1:987654321000:critical   ||\r\n|+-----------------------+---------------+-----------+------------------------------------------------------------------------------------------+-----------------------------------------------------+|\r\n\r\n<\/code><\/pre>\n<\/div>\n<p><strong>JSON<\/strong><\/p>\n<div class=\"hcb_wrap\">\n<pre class=\"prism line-numbers lang-plain\" data-lang=\"Plain Text\"><code>{\r\n    \"Subscriptions\": [\r\n        {\r\n            \"Owner\": \"987654321000\",\r\n            \"Endpoint\": \"warning@example.com\",\r\n            \"Protocol\": \"email\",\r\n            \"TopicArn\": \"arn:aws:sns:ap-northeast-1:987654321000:warning\",\r\n            \"SubscriptionArn\": \"arn:aws:sns:ap-northeast-1:987654321000:warning:c988b83*-57c*-4b1*-abd*-bd6e3af9638*\"\r\n        },\r\n        {\r\n            \"Owner\": \"987654321000\",\r\n            \"Endpoint\": \"info@example.com\",\r\n            \"Protocol\": \"email\",\r\n            \"TopicArn\": \"arn:aws:sns:ap-northeast-1:987654321000:info\",\r\n            \"SubscriptionArn\": \"arn:aws:sns:ap-northeast-1:987654321000:info:cb8b1bd*-aab*-486*-a0b*-d6ae24ed31a*\"\r\n        },\r\n        {\r\n            \"Owner\": \"987654321000\",\r\n            \"Endpoint\": \"critical@example.com\",\r\n            \"Protocol\": \"email\",\r\n            \"TopicArn\": \"arn:aws:sns:ap-northeast-1:987654321000:critical\",\r\n            \"SubscriptionArn\": \"arn:aws:sns:ap-northeast-1:987654321000:critical:f3a2aee*-98a*-455*-9eb*-d9aca773717*\"\r\n        }\r\n    ]\r\n}\r\n<\/code><\/pre>\n<\/div>\n<p>&nbsp;<\/p>\n<p>\u51fa\u529b\u7d50\u679c\u304b\u3089\u4ee5\u4e0b\u306e\u9805\u76ee\u304c\u53d6\u5f97\u3067\u304d\u307e\u3059\u3002<\/p>\n<table style=\"border-collapse: collapse; width: 100%;\" border=\"1\">\n<tbody>\n<tr style=\"height: 24px;\">\n<th style=\"height: 24px;\">\u9805\u76ee<\/th>\n<th style=\"height: 24px;\">\u5f62\u5f0f<\/th>\n<th style=\"height: 24px;\">\u8aac\u660e<\/th>\n<th style=\"height: 24px;\">\u5bfe\u5fdc\u7b87\u6240<\/th>\n<\/tr>\n<tr style=\"height: 24px;\">\n<td style=\"height: 24px;\">Subscriptions<\/td>\n<td style=\"height: 24px;\">list<\/td>\n<td style=\"height: 24px;\">\u00a0<\/td>\n<td style=\"height: 24px;\">SNS &gt; \u30b5\u30d6\u30b9\u30af\u30ea\u30d7\u30b7\u30e7\u30f3<\/td>\n<\/tr>\n<tr style=\"height: 24px;\">\n<td style=\"height: 24px;\">\u3000SubscriptionArn<\/td>\n<td style=\"height: 24px;\">string<\/td>\n<td style=\"height: 24px;\">\u30b5\u30d6\u30b9\u30af\u30ea\u30d7\u30b7\u30e7\u30f3\u306eARN\u3002<\/td>\n<td style=\"height: 24px;\">\u30b5\u30d6\u30b9\u30af\u30ea\u30d7\u30b7\u30e7\u30f3ID<\/td>\n<\/tr>\n<tr style=\"height: 24px;\">\n<td style=\"height: 24px;\">\u3000Owner\u00a0<\/td>\n<td style=\"height: 24px;\">string<\/td>\n<td style=\"height: 24px;\">\u30b5\u30d6\u30b9\u30af\u30ea\u30d7\u30b7\u30e7\u30f3\u306e\u6240\u6709\u8005\u3002<\/td>\n<td style=\"height: 24px;\">\u53d7\u4fe1\u8005<\/td>\n<\/tr>\n<tr style=\"height: 24px;\">\n<td style=\"height: 24px;\">\u3000Protocol\u00a0<\/td>\n<td style=\"height: 24px;\">string<\/td>\n<td style=\"height: 24px;\">\u30b5\u30d6\u30b9\u30af\u30ea\u30d7\u30b7\u30e7\u30f3\u306e\u30d7\u30ed\u30c8\u30b3\u30eb\u3002<\/td>\n<td style=\"height: 24px;\">\u30d7\u30ed\u30c8\u30b3\u30eb<\/td>\n<\/tr>\n<tr style=\"height: 24px;\">\n<td style=\"height: 24px;\">\u3000Endpoint\u00a0<\/td>\n<td style=\"height: 24px;\">string<\/td>\n<td style=\"height: 24px;\">\u30b5\u30d6\u30b9\u30af\u30ea\u30d7\u30b7\u30e7\u30f3\u306e\u30a8\u30f3\u30c9\u30dd\u30a4\u30f3\u30c8\u3002<\/td>\n<td style=\"height: 24px;\">\u30a8\u30f3\u30c9\u30dd\u30a4\u30f3\u30c8<\/td>\n<\/tr>\n<tr style=\"height: 24px;\">\n<td style=\"height: 24px;\">\u3000TopicArn\u00a0<\/td>\n<td style=\"height: 24px;\">string<\/td>\n<td style=\"height: 24px;\">\u30b5\u30d6\u30b9\u30af\u30ea\u30d7\u30b7\u30e7\u30f3\u306e\u30c8\u30d4\u30c3\u30af\u306eARN\u3002<\/td>\n<td style=\"height: 24px;\">ARN<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n","protected":false},"excerpt":{"rendered":"<p>\u6982\u8981 SNS\u306e\u60c5\u5831\u3092\u53d6\u5f97\u3059\u308b\u65b9\u6cd5\u306b\u3064\u3044\u3066\u8a18\u8f09\u3057\u3066\u3044\u307e\u3059\u3002 Amazon Simple Notification Service (SNS) Amazon Simple Notification Service (SNS)&#8230;<\/p>\n","protected":false},"author":3,"featured_media":23,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"jetpack_post_was_ever_published":false,"_jetpack_newsletter_access":"","_jetpack_dont_email_post_to_subs":false,"_jetpack_newsletter_tier_id":0,"_jetpack_memberships_contains_paywalled_content":false,"_jetpack_memberships_contains_paid_content":false,"footnotes":"","jetpack_publicize_message":"","jetpack_publicize_feature_enabled":true,"jetpack_social_post_already_shared":false,"jetpack_social_options":{"image_generator_settings":{"template":"highway","default_image_id":0,"font":"","enabled":false},"version":2}},"categories":[2],"tags":[30,101,82],"class_list":["post-1278","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-aws","tag-aws-cli","tag-sns","tag-82"],"jetpack_publicize_connections":[],"jetpack_featured_media_url":"https:\/\/www.itc109.com\/knowledge\/wp-content\/uploads\/sites\/2\/logo\/logo-aws.png","jetpack_sharing_enabled":true,"jetpack_shortlink":"https:\/\/wp.me\/pacZwp-kC","_links":{"self":[{"href":"https:\/\/www.itc109.com\/knowledge\/wp-json\/wp\/v2\/posts\/1278","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.itc109.com\/knowledge\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.itc109.com\/knowledge\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.itc109.com\/knowledge\/wp-json\/wp\/v2\/users\/3"}],"replies":[{"embeddable":true,"href":"https:\/\/www.itc109.com\/knowledge\/wp-json\/wp\/v2\/comments?post=1278"}],"version-history":[{"count":14,"href":"https:\/\/www.itc109.com\/knowledge\/wp-json\/wp\/v2\/posts\/1278\/revisions"}],"predecessor-version":[{"id":2544,"href":"https:\/\/www.itc109.com\/knowledge\/wp-json\/wp\/v2\/posts\/1278\/revisions\/2544"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.itc109.com\/knowledge\/wp-json\/wp\/v2\/media\/23"}],"wp:attachment":[{"href":"https:\/\/www.itc109.com\/knowledge\/wp-json\/wp\/v2\/media?parent=1278"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.itc109.com\/knowledge\/wp-json\/wp\/v2\/categories?post=1278"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.itc109.com\/knowledge\/wp-json\/wp\/v2\/tags?post=1278"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}