Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Amazon Pinpointを用いてEmailやLINE通知を自動化した基盤 / Story...
Search
hayato miyoshi
October 03, 2019
Technology
2
1.7k
Amazon Pinpointを用いてEmailやLINE通知を自動化した基盤 / Story of CRM platform using LINE by Amazon Pinpoint
【スナックミー】
Real Food(リアルフード)のみからできたおやつのパーソナライズ型サブスクリプションBOX
https://snaq.me
hayato miyoshi
October 03, 2019
Tweet
Share
More Decks by hayato miyoshi
See All by hayato miyoshi
一歩踏み出す技術活用 日常業務を見直す試み / snaqme-chuo-tech-2024.08.20
miyoshihayato
0
73
ビジネスを加速する技術選定 / snaqme-chuo-tech-2024.04.12
miyoshihayato
1
120
ROSCAFE TECH NIGHT 2023.12.20
miyoshihayato
1
160
AWS Summit Tokyo 2023.04.21
miyoshihayato
1
1.1k
Amazon Pinpointを用いて、LINEとメール配信のCRM設計 / AWS Dev Day 2022 B-2
miyoshihayato
3
2.3k
おやつ体験とパーソナライズ ~苦悩と効果と今後~ / snaq.me 20210218D9
miyoshihayato
0
120
スナックミー会社紹介資料(エンジニア募集) / snaq.me engineer
miyoshihayato
0
24k
snaq.me / Startup Architecture of the year 2019
miyoshihayato
2
6.1k
素早くおやつ(間食)の 新ブランドを立ち上げるためのLambda活用法 / lambda utilizing method
miyoshihayato
0
200
Other Decks in Technology
See All in Technology
5分でわかるDuckDB
chanyou0311
10
3.2k
オプトインカメラ:UWB測位を応用したオプトイン型のカメラ計測
matthewlujp
0
170
Amazon Kendra GenAI Index 登場でどう変わる? 評価から学ぶ最適なRAG構成
naoki_0531
0
100
podman_update_2024-12
orimanabu
1
260
第3回Snowflake女子会_LT登壇資料(合成データ)_Taro_CCCMK
tarotaro0129
0
180
10分で学ぶKubernetesコンテナセキュリティ/10min-k8s-container-sec
mochizuki875
3
320
【re:Invent 2024 アプデ】 Prompt Routing の紹介
champ
0
140
2024年にチャレンジしたことを振り返るぞ
mitchan
0
130
alecthomas/kong はいいぞ / kamakura.go#7
fujiwara3
1
300
マイクロサービスにおける容易なトランザクション管理に向けて
scalar
0
110
KnowledgeBaseDocuments APIでベクトルインデックス管理を自動化する
iidaxs
1
250
マルチプロダクト開発の現場でAWS Security Hubを1年以上運用して得た教訓
muziyoshiz
2
2.1k
Featured
See All Featured
Designing for Performance
lara
604
68k
Templates, Plugins, & Blocks: Oh My! Creating the theme that thinks of everything
marktimemedia
28
2.1k
Building Flexible Design Systems
yeseniaperezcruz
327
38k
Imperfection Machines: The Place of Print at Facebook
scottboms
266
13k
BBQ
matthewcrist
85
9.4k
Making Projects Easy
brettharned
116
5.9k
Adopting Sorbet at Scale
ufuk
73
9.1k
Optimising Largest Contentful Paint
csswizardry
33
3k
The Cult of Friendly URLs
andyhume
78
6.1k
Fontdeck: Realign not Redesign
paulrobertlloyd
82
5.3k
Being A Developer After 40
akosma
87
590k
Fantastic passwords and where to find them - at NoRuKo
philnash
50
2.9k
Transcript
Amazon PinpointΛ༻͍ͯEmailLINE௨Λ ࣗಈԽͨ͠ج൫ 2019.10.03 AWS DevDay Tokyo 2019 C-4 גࣜձࣾεφοΫϛʔ
CTO & co-founder ࡾ ൏ਓ
• גࣜձࣾεφοΫϛʔ • ࡾ ൏ਓ co-founder & CTO • ౦ژੜ·Ε౦ژҭͪ
• ݐஙग़ΤϯδχΞ • τϥΠΞεϩϯϚϥιϯΛᅂΉ @miyoshihayato
1. snaq.me(εφοΫϛʔ) ʹ͍ͭͯ 1,980ԁ (੫ࠐ) 100छҎ্͔Β8छͷ͓ͭΛҰਓͻͱΓʹηϨΫτ͓ͯ͠ಧ͚ Real Food͔Β࡞ͬͨɺඒຯͯ͘͠Χϥμʹ༏͍͓ͭ͠Λ͓ҰਓͻͱΓʹ ΧελϚΠζ͓ͯ͠ಧ͚͢ΔαϒεΫϦϓγϣϯαʔϏε
Mission Vison ৽͍͓ͭ͠ମݧΛ͠ɺ ͓ͭͷ࣌ؒΛՁͷ͋Δͷʹ͢Δɻ ඦԯԁنͷ Real FoodεφοΫࢢΛΓɺ ͦͷࢢͷφϯόʔ1ϒϥϯυͱͳΔɻ ӫཆՁ͕ߴ͘ɺͦΕͰ͍ͯඒຯ͠͞ʹଥڠ͠ͳ͍εφοΫʹΑͬͯɺ͓ͭͦͷͷ࣭Λ্͛Δɻ ·ͨɺϞϊ͚ͩͰͳ͘ɺ৽͍͓ͭ͠ମݧΛσβΠϯ͠ɺ͓ͭͷ࣌ؒͷՁΛ্ͤ͞Δɻ
ͦΕʹΑͬͯɺ͓ͭͷ͕࣌ؒ࠼ΓͱͳΓɺ๛͔ͳੜ׆Λ࣮ݱ͢Δɻ Real FoodεφοΫͱɺܗ͋ΔReal FoodͷΈ͔Β࡞ΒΕͨεφοΫɻ ૉࡐຊདྷ͕࣋ͭӫཆͱඒຯ͠͞Λ࠷େݶʹ׆͔͠ɺਓతͳݪྉԽֶ࣭Θͳ͍ɻ ӫཆՁ͕ߴ݈͘߁తͰɺͦΕͰ͍ͯඒຯ͠͞ʹଥڠ͠ͳ͍ɻ
εφοΫϛʔͷ։ൃج४ Made From Real Food Խֶ࣭ʹཔΒͣɺࣗવͳૉࡐ͔Βඒຯ͠͞ͱӫཆΛҾ͖ग़͢ Create a New Culture
৽͍͠৯จԽ৯श׳Λ࡞Γग़͠͏Δ Without Compromise ඒຯ͠͞ʹଥڠ͠ͳ͍
υϥΠϑϧʔπɾφοπ τϨΠϧϛοΫε ম͖՛ࢠ νϣί νοϓε ถ՛ ͦͷଞ ϑϧʔπ՛ࢠ قઅʹ߹Θͤͨ100SKUҎ্Λৗ࣌ࡏݿɻຖ݄10ʙ20%ΛೖΕସ͑ɻ 1.
snaq.me(εφοΫϛʔ) ʹ͍ͭͯ
1. snaq.me(εφοΫϛʔ) ʹ͍ͭͯ ࢦࣔॻ ࡞ ࡏݿొ ΞαΠϯ ϐοΩϯά ൃૹ
͔Βൃૹ४උ·ͰҰ؏
1. snaq.me(εφοΫϛʔ) ʹ͍ͭͯ ੳ TOBDLCPY ͓ͭͷධՁ/ ϦΫΤετ ৽։ൃ ͓ͭͷA/Bςετ ͓ಧ͚͢Δ͓ͭΛܾఆ
։ൃͷओͳπʔϧ - αʔόʔαΠυ : Ruby on Rails (PHP) - ϑϩϯτΤϯυݴޠ
: BabelɺҰ෦TypeScript - ϑϩϯτΤϯυ : React, Redux, webpack - UIίϯϙʔωϯτΧλϩά : Storybook - σʔλੳ : python - σʔλϕʔε : Aurora, DynamoDB - Πϯϑϥ : AWS - ։ൃڥ : Vagrant, Docker - ϦϙδτϦཧ : GitHub / codecommit - CI / CDͳͲ : CodePipeLine / jest / RSpec - ίϛϡχέʔγϣϯ : Qiita:Team, Slack
Amazon PinpointΛ༻͍ͯEmailLINE௨ΛࣗಈԽͨ͠ج൫ͷ ͔͜͜Βຊ
ͦͦɺͳͥLINE(νϟοτUI)Λ༻͍ͨͷ͔ʁ
2015ͷۀલ͔ΒҎԼͷΑ͏ʹߟ͍͑ͯ·ͨ͠ • UX͕໌֬ • νϟοτUIएஉঁ͑Δ • ͜Ε͔ΒνϟοτUI͕ϕʔεʹͳΔՄೳੑ͕͋Δ • LINE͔ΒpushͰ͖Δ •
LINE্ͩͱϑϨΩγϒϧʹUIΛૢΕͳ͍ͷͰwebʹҊ͢ΔΑ͏ʹͨ͠
εφοΫϛʔॳʁ
ॳ
ΓͱΓશͯνϟοτܗࣜ ධՁϦΫΤετ
νϟοτUI͍͍ͱ͜Ζ͚ͩ͡Όͳ͍ త͕͔ͬ͠Γ͍ͯ͠Δ߹ճΓ͘Ͳ͍ ॳճɺॳݟϢʔβʔʹνϟοτͰҊ͢Δͱ͍উख্ ⭕ ❌ 2प(ֶशࡁΈͷUIUX) ❌
CSͱͯ͠ͷίϛϡχέʔγϣϯ1ຊʹ ͦͷͨΊ
LINE Messaging API ༻͍͍ͯΔͷ͕
• اۀͱϢʔβʔͷํίϛϡχέʔγϣϯ͕Մೳ • ϓογϡϝοηʔδͱԠϝοηʔδ • 1ର1ɺάϧʔϓͰτʔΫՄೳ • ͞·͟·ͳঢ়گʹ߹ΘͤͨϝοηʔδλΠϓ • ςΩετ
• ελϯϓ • Ի • ը૾ͳͲ LINE Messaging APIͰͰ͖Δ͜ͱ
ߏਤ Ϣʔβʔૹ৴ ελοϑૹ৴ ελοϑ௨ Amazon Route 53 Elastic Load Balancing
Elastic Load Balancing EC2 EC2 Amazon Aurora
ߏਤ Ϣʔβʔૹ৴ ελοϑૹ৴ ελοϑ௨ Amazon Route 53 Elastic Load Balancing
Elastic Load Balancing EC2 EC2 Amazon Aurora
ߏਤ Ϣʔβʔૹ৴ ελοϑૹ৴ ελοϑ௨ Amazon Route 53 Elastic Load Balancing
Elastic Load Balancing EC2 EC2 Amazon Aurora
ૹड৴Λ͚͍ͯΔཧ༝ Ϣʔβʔ͔Βͷϝοηʔδड৴ઈରʂམͱͤͳ͍
• αʔϏε͕άϩʔε͢ΕɺCS૿͢ඞཁ͕͋Δ • Ͳ͜·ͰΞτόϯυ(ελοϑൃ৴)Λߦ͏͔ • ͕ͩɺϢʔβʔͱͷଟ͍࣋ͪͨ͘ • ৽͍͠ࢪࡦΛࢼ͍ͨ͠ ͳͲ ՝
• αʔϏε͕άϩʔε͢ΕɺCS૿͢ඞཁ͕͋Δ • Ͳ͜·ͰΞτόϯυ(ελοϑൃ৴)Λߦ͏͔ • ͕ͩɺϢʔβʔͱͷଟ͍࣋ͪͨ͘ • ৽͍͠ࢪࡦΛࢼ͍ͨ͠ ͳͲ ՝
1ର1ͷରԠ͠ɺ1ରଟΛͰ͖ΔΈͷߏங Ϣʔβʔͱ͢Δʹ1า(௨)͕େࣄͳͷͰ
ηάϝϯτରͷ1௨ awsΛ༻͍ͨγεςϜ ͦͷޙ1ର1Ͱ ϝοηʔδͷΓऔΓ ͜͏͍͏͜ͱ
ηάϝϯτͨ͠Ϣʔβʔ৴ΛࣗಈԽͰ͖Δج൫͕ཉ͍͠
Amazon Pinpoint
Amazon Pinpoint ͱ Τϯήʔδϝϯτνϟωϧ ϝοηʔδΛͻͱͭͷνϟωϧ͔ɺଟ͘ͷνϟωϧܦ༝ͰૹΔ͔ʹ͔͔ΘΒͣɺੈքதͷԿඦສͷސ٬ʹ؆୯ Ͱ৴པੑߴ͘ϝοηʔδΛಧ͚Δ͜ͱ͕Ͱ͖·͢ɻ Τϯήʔδϝϯτཧ దͳސ٬ʹɺదͳϝοηʔδΛɺదͳλΠϛϯάͰɺదͳνϟωϧΛ௨ͯ͠ૹ͍ͬͯͩ͘͞ɻ ੳ ސ٬ͱوࣾͷΤϯήʔδϝϯτʹؔ࿈ͨ͠σʔλΛूɺՄࢹԽɺΧελϚΠζɻ
ࢀর : https://aws.amazon.com/jp/pinpoint/
Amazon Pinpoint ͱ Τϯήʔδϝϯτνϟωϧ EϝʔϧɺԻɺSMSɺϓογϡ௨ɺ֦ுػೳ(LINEͳͲ) Τϯήʔδϝϯτཧ ΩϟϯϖʔϯͷΑ͏ʹಛఆͷରऀηάϝϯτʹૹ৴͢ΔͷͰͳ͘ɺಛఆͷड৴ऀʹૹ৴͢ΔΦϯσϚϯυϝο ηʔδΛૹΔ͜ͱՄೳ ੳ ސ٬σʔλͷऩूͱཧղɺ͓Αͼσʔλʹج͍ͮͨߦಈɺΤϯήʔδϝϯτͷऔΓΈͷύϑΥʔϚϯεʹର͠
ͯɺ͞·͟·ͳੳ͕Մೳ ࢀর : https://aws.amazon.com/jp/pinpoint/
Amazon Pinpoint ͱ ࢀর : https://docs.aws.amazon.com/ja_jp/aws-mobile/latest/developerguide/mobile-hub-add-aws-mobile-analytics.html
Amazon Pinpoint Ͱemail/push௨ ͷϢʔεέʔε AWS Batch Amazon Simple Storage Service
(S3) Amazon Pinpoint લॲཧ ηάϝϯτͷϢʔβʔΛ S3ʹΞοϓϩʔυ ࣌ؒࢦఆ or ଈ࣌৴
• jsoncsvϑΝΠϧ͕͋ΕGUI͔Βૢ࡞͢Δ͜ͱՄೳ • ࣌ؒࢦఆ or ଈ࣌৴͕Մೳ • 1ඵؒʹ0 ~ 25,000௨·Ͱ৴Λม͑Β͑Δ
• ։෧ClickҎ֎ͷੳΛҎͰੳͯ͘͠ΕΔ • ϑΝωϧੳͰ͖Δ & Amazon Personalize Amazon Pinpointͷخ͍͠ϙΠϯτ ײͰ৮ΕΔ ༧৴(batchॲཧ)ۓٸੑͷߴ͍৴(ใχϡʔεͳͲ) ΞΫηεΛίϯτϩʔϩͰ͖Δ ͨͩૹΔ͚ͩ͡Όͳ͘ɺͦͷޙͷΞΫγϣϯʹͭͳ͛ΒΕΔ ͞·͟·ͳCVRௐ͕ࠪՄೳ ϑΝωϧੳ
Ͳ͏͍͏ߏਤʹ͠Α͏͔ʁʁ
Email or LINE Ͱ௨͍ͨ͠
LINE௨Λ͢ΔʹAWS LambdaΛ༻ͨ͠ΧελϜνϟωϧͰͰ͖ΔΒ͍͠ ※ ࠓ(201910݄ݱࡏ)ύϒϦοΫϕʔλ൛ͳͷͰ༷มߋͷՄೳੑ͋Γ
Amazon Pinpoint౦ژϦʔδϣϯͰར༻Ͱ͖ͳ͍ ※ ࠓ(201910݄ݱࡏ)
Amazon PinpointΛىಈͤ͞ΔʹͲ͏͠Α͏ σʔλ౦ژϦʔδϣϯʹ͋Δ
AWS Step FunctionsͰཧͰ͖Δʁ AWS Lambdaʁ
AWS Step FunctionsAWS LambdaϦʔδϣϯؒΛͭͳ͛ΒΕͳ͍
ҟͳΔϦʔδϣϯͷAWS LambdaΛར༻͢Δํ๏͕͋Δ ࢀর : https://dev.classmethod.jp/cloud/trigger-lambda-on-other-regions/
• ϢʔβʔΞϓϦέʔγϣϯͷݺͼग़͠ɺPC/αʔόʔ্ͷAWS SDK·ͨεϚʔτ ্ͷAWS Mobile SDKͰՄೳ • AWSͷ௨αʔϏεͰ͋ΔSNSͷ௨ઌͱͯ͠AWS LambdaΛࢦఆ͢Δ •
S3 Cross-Region ReplicationͰAWS Lambdaؔͱಉ͡ϦʔδϣϯʹόέοτΛෳ ͠ɺෳόέοτʹAWS LambdaͷΠϕϯτ௨Λઃఆ͢Δ ҟͳΔϦʔδϣϯͷAWS LambdaΛར༻͢Δํ๏ ࢀর : https://dev.classmethod.jp/cloud/trigger-lambda-on-other-regions/
• ϢʔβʔΞϓϦέʔγϣϯͷݺͼग़͠ɺPC/αʔόʔ্ͷAWS SDK·ͨεϚʔτ ্ͷAWS Mobile SDKͰՄೳ • AWSͷ௨αʔϏεͰ͋ΔSNSͷ௨ઌͱͯ͠AWS LambdaΛࢦఆ͢Δ •
S3 Cross-Region ReplicationͰAWS Lambdaؔͱಉ͡ϦʔδϣϯʹόέοτΛෳ ͠ɺෳόέοτʹAWS LambdaͷΠϕϯτ௨Λઃఆ͢Δ ҟͳΔϦʔδϣϯͷAWS LambdaΛར༻͢Δํ๏͕͋Δ ࢀর : https://dev.classmethod.jp/cloud/trigger-lambda-on-other-regions/
ηάϝϯτใ͔Β৴·ͰͷϑϩʔAWS Step FunctionsͰ͍ͨ͠
Amazon Pinpoint ηάϝϯτΛΠϯϙʔτ͢Δʹ࣌ؒΛཁ͢Δ(࣌ؒͰͳ͍)
ΧελϜνϟωϧͰىಈ͞ΕͨAWS Lambda50໊Ͱ1Lambdaىಈ͢Δ
• σʔλϕʔε͕౦ژϦʔδϣϯͷͨΊLambdaܦ༝ͰPinpointΛىಈͰ͖ͳ͍ • ৴ͷϫʔΫϑϩʔΛStep FunctionsΛ༻͍Δ༧ఆ͕ϦʔδϣϯؒsetͰ͖ͳ͍ • ηάϝϯτͨ͠δϣϒΛΠϯϙʔτྃʹ͕͔͔࣌ؒΔ • ࠷ޙͷLINE৴࣌Ͱ৴ਓ /
50໊ͷLambda্ཱ͕͕ͪΔ • ଐੑͷίϯτϩʔϧ AWS LambdaͱࣗಈԽʹ͏՝ ΦϨΰϯͳͲಉϦʔδϣϯͰ͋ΕىಈՄೳ Pinpointͷϑϩʔ͚ͩStep FunctionsΛ༻͍ΔͳͲ ΠϯϙʔτྃΛϙʔϦϯά͢Δඞཁ͕͋Δ ্ݶ؇·ͨಉ࣌ʹ50,000ਓʹૹΒͳ͚Εجຊͳ͍ ଐੑ40ݸ·ͰͳͷͰɺܭըతͳઃܭ͕ඞཁ
AWS Step Functions Amazon S3 AWS Lambda AWS Lambda Amazon
DynamoDB AWS Lambda AWS Lambda AWS Lambda DONE import? ৴ ϑϩʔ Amazon Simple Notification Service Tokyo Region (ap-northeast-1) Oregon Region (us-west-2) AWS Batch
AWS Step Functions Amazon S3 AWS Lambda AWS Lambda Amazon
DynamoDB AWS Lambda AWS Lambda AWS Lambda DONE import? ৴ ϑϩʔ Amazon Simple Notification Service Tokyo Region (ap-northeast-1) Oregon Region (us-west-2) AWS Batch ౦ژϦʔδϣϯ
AWS Step Functions Amazon S3 AWS Lambda AWS Lambda Amazon
DynamoDB AWS Lambda AWS Lambda AWS Lambda DONE import? ৴ ϑϩʔ Amazon Simple Notification Service Tokyo Region (ap-northeast-1) Oregon Region (us-west-2) AWS Batch ΦϨΰϯϦʔδϣϯ
AWS Step Functions Amazon S3 AWS Lambda AWS Lambda Amazon
DynamoDB AWS Lambda AWS Lambda AWS Lambda DONE import? ৴ ϑϩʔ Amazon Simple Notification Service Tokyo Region (ap-northeast-1) Oregon Region (us-west-2) AWS Batch Ϣʔβʔηάϝϯτͨ͠σʔλΛ S3ʹputͰSNSΛணՐ SNSϦʔδϣϯؒؔͳ͍ͷͰɺ Step Functions Λىಈͤ͞Δ Amazon PinpointΛ༻͍ͯ৴
AWS Step Functions Amazon DynamoDB AWS Lambda AWS Lambda AWS
Lambda DONE import? ৴ AWS Step Functions Step Functionsͷελʔτ DynamoDB͔Β৴͢Δ pinpointͷΞϓϦέʔγϣϯΛ औಘ͢Δ import͞ΕͨJSONσʔλΛ ݩʹηάϝϯτΛ࡞ ৴͢ΔνϟωϧλΠϓ͔Β ΧελϜνϟωϧ ඪ४Λऔಘ͢Δ importޙ͕݅ଟ͘ͳΔͱ importʹ͕͔͔࣌ؒΔ(࣌ؒ Ͱͳ͍ͳ͍) ͦͷͨΊɺimport͕͔ྃͨ͠ ఆظνΣοΫ͢Δඞཁ͋Γ ྃޙΩϟϯϖʔϯͷੜ ΧελϜͷ߹ ΧελϜνϟωϧͰ৴͢Δ LambdaΛىಈͤ͞Δ
AWS Step Functions Amazon DynamoDB AWS Lambda AWS Lambda AWS
Lambda DONE import? ৴ AWS Step Functions Step Functionsͷελʔτ DynamoDB͔Β৴͢Δ pinpointͷΞϓϦέʔγϣϯΛ औಘ͢Δ import͞ΕͨJSONσʔλΛ ݩʹηάϝϯτΛ࡞ ৴͢ΔνϟωϧλΠϓ͔Β ΧελϜνϟωϧ ඪ४Λऔಘ͢Δ importޙ͕݅ଟ͘ͳΔͱ importʹ͕͔͔࣌ؒΔ(࣌ؒ Ͱͳ͍ͳ͍) ͦͷͨΊɺimport͕͔ྃͨ͠ ఆظνΣοΫ͢Δඞཁ͋Γ ྃޙΩϟϯϖʔϯͷੜ ΧελϜͷ߹ ΧελϜνϟωϧͰ৴͢Δ LambdaΛىಈͤ͞Δ
AWS Lambda ৴ AWS Step Functions ྃޙΩϟϯϖʔϯͷੜ ΧελϜͷ߹ ΧελϜνϟωϧͰ৴͢Δ LambdaΛىಈͤ͞Δ
import os import json import boto3 def lambda_handler(event, context): s3 = boto3.client(‘s3') # ϝοηʔδ༰ msg = event["Message"]["smsmessage"]["body"] arr = json.loads(msg) # ΤϯυϙΠϯτҰཡ endpoints = event["Endpoints"] for item in endpoints: # ΤϯυϙΠϯτ line_id = endpoints[item][‘Address'] # ৴
S3ͷߏߏ json : ৴σʔλҰཡ email_format : ৴༰ ৴͢Δ্Ͱཧ͍͢͠ Α͏ʹઃఆ ͳͷͰɺձࣾํͰ͓ͤ
email: ϝʔϧ৴ line: LINE৴ email_line: ϝʔϧ & LINE৴ xxxxʹ line: LINE৴ͷϑΥʔϚοτ html: ϝʔϧͷHTMLܕ txt: ϝʔϧςΩετܕ title: ϝʔϧλΠτϧ Amazon S3 s3:// BUCKET_NAME / format / ΧςΰϦ / ϒϥϯυ໊ / ৴λΠϓ / ࢠΧςΰϦ_xxxx.txt s3:// BUCKET_NAME / json / ΧςΰϦ / ϒϥϯυ໊ /৴λΠϓ / ࢠΧςΰϦ / yyyy-mm-dd.json json / format ɾࢠΧςΰϦ ϒϥϯυ໊ ৴λΠϓ ࢠΧςΰϦʔ_xxxx.txt ηάϝϯτϑΝΠϧ໊ ৴ϑΝΠϧ໊
AWS Lambda LINE ৴ AWS Lambda { "text": { "text":
"xxxxxx" } } ςΩετ ver. ը૾ ver. ΠϝʔδϚοϓ ver. { "image": { "original_content_url": "xxx", "preview_image_url": "yyy" } } { "imagemap":{ "alt_text": "ccccccccccccccccccccc", “base_url": "https://snaq.me", "h": xxx, "w": yyyy, "actions": [ { "uri_text": "https://snaq.me", "type": "uri", "x": 0, "y": 0, "w": aaaaa, "h": bbbbb }…….. ] } }
AWS Step Functions AWS Lambda AWS Lambda ΞϓϦέʔγϣϯ࡞ AWS Step
Functions pinpointͷΞϓϦʔγϣϯ࡞ ࡞ΒΕͨΞϓϦέʔγϣϯΛ DynamoDBʹೖΕࠐΉ & ঢ়گnotificationͤ͞Δ ༗ޮޙͷঢ়گΛ Dynamoʹput & ঢ়گΛnotificationͤ͞Δ Amazon DynamoDB AWS Lambda AWS Lambda Amazon DynamoDB ΞϓϦέγϣʔϯͰ EMAILΛ༗ޮʹͤ͞Δ
௨ AWS Step Functions AWS Lambda AWS Lambda ΞϓϦέʔγϣϯ࡞ AWS
Step Functions Amazon DynamoDB AWS Lambda AWS Lambda Amazon DynamoDB { “app_email": "
[email protected]
", "app_name": "xxxxxxxxxxx" }
͜ΕͰ࠷ॳͷϢʔβʔηάϝϯτͷ෦ΛೖΕସ͑Δ͚ͩͰࣗಈ৴͕Մೳʹ
Amazon PinpointͰቕͬͯ͠·ͬͨ͜ͱ
• ଐੑͷ্ݶΛ͑ͯΤϥʔ͕ฦΒͳ͍ • ߏจϛεΤϥʔ͕ͩɺର߲ͷ্ݶจࣈΛ͑ͯΤϥʔฦΒͳ͍ • ଐੑ͕ରϢʔβʔʹΑۭͬͯͷ߹ɺCSVͩͱ[]ͱͯ͠Δ͕jsonฏؾ Amazon PinpointΛቕͬͯ͠·ͬͨ͜ͱ ্ه2ͭΤϯυϙΠϯτʹରऀ͕͍Δ͔֬ೝ͕ඞཁɻ1ͭͰoutͩͱશͯૹΕͳ͍ CSVཧޙʑϚʔέ͕ѻ͍͍͕͢ɺjsonΈࠐΈ͍͢
Amazon Pinpointͷ੍ݶ (ओʹҙ͕ඞཁͳpoint) Ϧιʔε σϑΥϧτͷ੍ݶ ૿Ճͷର AttributesɺMetricsɺUserAttributes ύϥϝʔ λʹ·ͱΊׂͯΓͯΒΕͨଐੑ ΞϓϦ͝ͱʹ
40 ͍͍͑ ଐੑͷ͞ 100 จࣈ ͍͍͑ ಉ͡Ϣʔβʔ ID Λ࣋ͭΤϯυϙΠϯτ Ϣʔβʔ ID ͝ͱʹ 10 ݸͷҰҙ ͷΤϯυϙΠϯτ ͍͍͑ ηάϝϯτͷ࡞ʹ༻Ͱ͖ΔσΟϝϯγϣ ϯͷ࠷େ ηάϝϯτ͝ͱʹ 100 ͍͍͑ ηάϝϯτʹಉҰͷΤϯυϙΠϯτ ॏෳআ͞ΕΔ ͍͍͑
·ͱΊ • Amazon PinpointͰ͞·͟·ͳνϟωϧ௨͕Մೳ • ΧελϜνϟωϧΛ༻͍ΕLINE৴Մೳ(β൛ͳͷͰมΘΔ͜ͱ) • ଐੑͷ্ݶ͔ΒΞϓϦέʔγϣϯͷཧํ๏Λߟ͑Δඞཁ͕͋Δ • Τϥʔ͡Όͳ͍͕ૹΕͯͳ͍͜ͱ͕͋ΔͷͰɺ֬ೝͷϑϩʔඞਢ
• AWS Step Functionsʹ·ͱΊΔ͜ͱͰҰݩཧ • ϦʔδϣϯؒSNSαϒεΫϥΠϒΛ༻͍Δ͜ͱͰεϜʔζʹ
ࠓޙ͍ͨ͜͠ͱ • Amazon PersonalizeΛ༻͍ͯΑΓ֬ͷߴ͍௨Λ • ͓՛ࢠͷબఆͷڧԽ • OEMઌͷγεςϜ • ύςΟγΤ͚ͷ৽։ൃγεςϜ
• ࣗಈൃૹ • ධՁΛ͠ͳͯࣗ͘ಈͰ͖ݏ͍ΛஅͰ͖ΔΈ ͳͲ
৽͍͓ͭ͠ମݧΛ͠ɺ ͓ͭͷ࣌ؒΛՁͷ͋Δͷʹ ͝੩ௌ͋Γ͕ͱ͏͍͟͝·ͨ͠ ͝ڵຯ͋Δํ snaq.me (εφοΫϛʔ)