{"id":1355,"date":"2017-10-12T17:17:34","date_gmt":"2017-10-12T17:47:34","guid":{"rendered":"https:\/\/mind4y.com\/itstuff\/?p=1355"},"modified":"2020-03-19T23:24:23","modified_gmt":"2020-03-19T23:54:23","slug":"aws-lambda-sns-pushing","status":"publish","type":"post","link":"https:\/\/ultering.com\/it4us\/?p=1355","title":{"rendered":"AWS: LAMBDA: SNS PUSHING"},"content":{"rendered":"<pre>    const aws = require('aws-sdk');\r\n    const sns = new aws.SNS();\r\n    sns.publish(\r\n        {\r\n            Message: message,\r\n            TopicArn: 'TOPIC_ARN'\r\n        }, function(err, data) {\r\n            if (err) {\r\n                console.log(err.stack);\r\n                return;\r\n            }\r\n            console.log('push sent');\r\n            console.log(data);\r\n        }\r\n    );\r\n<\/pre>\n<!--CusAds0-->\n<div style=\"font-size: 0px; height: 0px; line-height: 0px; margin: 0; padding: 0; clear: both;\"><\/div>","protected":false},"excerpt":{"rendered":"<p>const aws = require(&#8216;aws-sdk&#8217;); const sns = new aws.SNS(); sns.publish( { Message: message, TopicArn: &#8216;TOPIC_ARN&#8217; }, function(err, data) { if (err) { console.log(err.stack); return; } console.log(&#8216;push sent&#8217;); console.log(data); } );<\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_bbp_topic_count":0,"_bbp_reply_count":0,"_bbp_total_topic_count":0,"_bbp_total_reply_count":0,"_bbp_voice_count":0,"_bbp_anonymous_reply_count":0,"_bbp_topic_count_hidden":0,"_bbp_reply_count_hidden":0,"_bbp_forum_subforum_count":0,"footnotes":""},"categories":[26],"tags":[25,27],"class_list":["post-1355","post","type-post","status-publish","format-standard","hentry","category-javascript","tag-aws","tag-nodejs"],"_links":{"self":[{"href":"https:\/\/ultering.com\/it4us\/index.php?rest_route=\/wp\/v2\/posts\/1355","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/ultering.com\/it4us\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/ultering.com\/it4us\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/ultering.com\/it4us\/index.php?rest_route=\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/ultering.com\/it4us\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=1355"}],"version-history":[{"count":1,"href":"https:\/\/ultering.com\/it4us\/index.php?rest_route=\/wp\/v2\/posts\/1355\/revisions"}],"predecessor-version":[{"id":2641,"href":"https:\/\/ultering.com\/it4us\/index.php?rest_route=\/wp\/v2\/posts\/1355\/revisions\/2641"}],"wp:attachment":[{"href":"https:\/\/ultering.com\/it4us\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=1355"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/ultering.com\/it4us\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=1355"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/ultering.com\/it4us\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=1355"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}