$30 off During Our Annual Pro Sale. View Details »

Customer Portal使う?使わない?フルスクラッチとのメリデメ比較

Customer Portal使う?使わない?フルスクラッチとのメリデメ比較

#JP_Stripes (Stripe ユーザーグループ)Online Meetup Vol.3 - Customer Portal、使ってますか?

https://eventregist.com/e/JP_Stripe_meetup_03

で登壇した際の資料です。

PDF化の際の影響で23ページ目の資料でCustomer Portalのデメリットが見切れてしまっていますが、
「・差額請求は日割り計算のみ
」
と記載してあります。

Yoshiteru Iwasaki

September 03, 2021
Tweet

More Decks by Yoshiteru Iwasaki

Other Decks in Technology

Transcript

  1. I 2021/9/ 3 #JP_Stripe s ؠ࡚ ળޫʢ@neeton_iwasakiʣ Customer Portal࢖͏ʁ ࢖Θͳ͍ʁ

    ϑϧεΫϥονͱͷ ϝϦσϝൺֱ
  2. TOWNגࣜձࣾ ϓϩμΫτϚωʔδϟʔ @neeton_iwasaki ؠ࡚ ળޫ ͍Θ͖͞ Αͯ͠Δ

  3. https://aipo.com toB޲͚ εέδϡʔϧ؅ཧSaaS Aipo

  4. • Stripeྺ 4೥൒ • ಋೖ࣌ʹ͕ͬͭΓ࣮૷ • ϏδωεͷมԽʹ߹Θͤͯ౎౓վम • Customer Portalະར༻

    ຊ೔ͷཱ৔ Customer Portal ਪ͠
  5. • APIˍॆ࣮ͨ͠SD K • Θ͔Γ΍͍͢APIϦϑΝϨϯε • μογϡϘʔυ೔ຊޠԽະରԠʢ౰࣌ʣ • ϑϧεΫϥον͔͠બ୒ࢶͳ͠ Stripeಋೖ౰࣌ͷҹ৅

    ΤϯδχΞϑϨϯυϦʔ
  6. αʔϏεಠࣗͷ ੥ٻϧʔϧͳͲ ࡉ͔ͳ࡞ΓࠐΈ͕Մೳ ϑϧεΫϥονͷϝϦοτ

  7. ྉۚମܥͷݟ௚࣌͠ͳͲ γεςϜվमʹ ΤϯδχΞͷ޻਺͕͔͔Δ ϑϧεΫϥονͷσϝϦοτ

  8. ڈ೥ Customer Porta l ϦϦʔε

  9. • ΤϯυϢʔβʔ޲͚ʹ੥ٻ؅ཧػೳΛఏڙ • Ұ࣌తͳURLΛൃߦ Customer Portalͱ͸

  10. Customer PortalͰͰ͖Δ͜ͱ • ఆظܾࡁͷϓϥϯมߋ • ࢧ෷͍ཤྺͷ֬ೝ • ࢧ෷͍ํ๏ͷมߋ • ੥ٻઌ৘ใͷมߋ

  11. • ৽نαϒεΫϦϓγϣϯͷ࡞੒͸Ͱ͖ͳ͍ • ୯ൃܾࡁͷཤྺ͸දࣔ͞Εͳ͍ • ༗ঈͷ Billing ϢʔβͷΈ͕ར༻Մೳ Customer Portalͷ஫ҙ఺

  12. αϒεΫͷ ܾࡁ·ΘΓͰඞཁ ͳػೳ

  13. 1. ৽نܖ໿ਃ͠ࠐΈɺΫϨΧొ࿥ 2. ܖ໿ϓϥϯͷมߋ 3. ࢧ෷ཤྺͷ֬ೝ 4. ΫϨΧ৘ใͷมߋ 5. ੥ٻઌ৘ใͷมߋ

    αϒεΫͷܾࡁ·ΘΓͰඞཁͳػೳ
  14. αϒεΫͷܾࡁ·ΘΓͰඞཁͳػೳͱͦͷ࣮૷ ػೳ ϑϧεΫϥον Customer Portal ৽نܖ໿ਃ͠ࠐΈ Checkout ඇରԠ ࢧ෷ཤྺͷ֬ೝ ཁ࣮૷

    ରԠࡁ ΫϨΧ৘ใͷมߋ Checkout ରԠࡁ ܖ໿಺༰ͷมߋ ཁ࣮૷ ରԠࡁ ੥ٻઌ৘ใͷมߋ ཁ࣮૷ ରԠࡁ
  15. 1. ৽نܖ໿ ਃ͠ࠐΈ ΫϨΧొ࿥

  16. ৽نܖ໿ਃ͠ࠐΈɺΫϨΧొ࿥ʢϑϧεΫϥονʣ σʔλΛߋ৽ ਃ͠ࠐΈ Custome r Subscriptio n ࡞੒ Stripe API

    Checkou t URLੜ੒ Stripe API ΫϨΧ৘ใΛొ࿥ Checkout
  17. ৽نܖ໿ਃ͠ࠐΈɺΫϨΧొ࿥ʢCustomer Portalʣ σʔλΛߋ৽ ਃ͠ࠐΈ Custome r Subscriptio n ࡞੒ Stripe

    API Customer Porta l URLੜ੒ Stripe API ΫϨΧ৘ใΛొ࿥ Customer Portal Χʔυ৘ใొ࿥͕Checkout͔Customer Portal͔ͷҧ͍
  18. ৽نܖ໿ਃ͠ࠐΈɺΫϨΧొ࿥ʢϝϦοτɾσϝϦοτʣ Customer Portal ϑϧεΫϥον ϑϧεΫϥον Customer Portal ϝϦοτ ɾCheckout/Elementsͷબ୒ࢶ σϝϦοτ

    ϝϦοτ ɾܾࡁ؅ཧΛCustomer Portalʹू໿ σϝϦοτ ɾSubscriptionͷ࡞੒͕ඞཁ େ͖ͳϝϦοτɾσϝϦοτͷࠩ͸ͳ͍
  19. 2. ܖ໿ϓϥϯ ͷมߋ

  20. ܖ໿ϓϥϯͷมߋʢϑϧεΫϥονʣ σʔλΛߋ৽ ਃ͠ࠐΈ Subscriptio n ߋ৽ Stripe API

  21. ܖ໿ϓϥϯͷมߋʢCustomer Portalʣ ϓϥϯมߋਃ͠ࠐΈ ਃ͠ࠐΈ Customer Porta l URLੜ੒ Stripe API

    ܖ໿ϓϥϯΛมߋ Customer Portal σʔλΛߋ৽ Webhook
  22. • ϑϧεΫϥονͷ৔߹ ࣗલσʔλˠStripeͷσʔλ • Customer Portalͷ৔߹ StripeͷσʔλˠWebhook→ࣗલσʔλ σʔλߋ৽ॲཧͷॱ൪͕ٯʹͳΔ ܖ໿ϓϥϯͷมߋ࣌ͷσʔλߋ৽ॱ

  23. ܖ໿ϓϥϯͷมߋʢϝϦοτɾσϝϦοτʣ Customer Portal ϑϧεΫϥον ϑϧεΫϥον Customer Portal ϝϦοτ ɾֹࠩ੥ٻͷࡉ͔ͳରԠ ɾܖ໿Մೳϓϥϯͷॊೈͳίϯτϩʔϧ

    σϝϦοτ ɾ੥ٻֹۚΛࣗલͰܭࢉͯ͠දࣔ ɾ࣮૷ͱςετ͕ෳࡶ ϝϦοτ ɾ੥ٻֹۚͷࣗಈදࣔ ɾϓϩϞʔγϣϯίʔυʹରԠ ɾ঎඼͝ͱʹ੍ݶΛ௥ՃՄೳ ɾAPIͰࡉ͔ͳௐ੔͕Մೳ σϝϦοτ ɾֹࠩ੥ٻ͸೔ׂΓܭࢉͷΈ ΠϨΪϡϥʔΛͲͷఔ౓ڐ༰͢Δ͔Ͱ൑அ
  24. 3. ࢧ෷ཤྺͷ ֬ೝ

  25. ࢧ෷ཤྺͷ֬ೝʢϑϧεΫϥονʣ ࢧ෷ཤྺ Ұཡϖʔδͷදࣔ Ұཡऔಘ Invoiceऔಘ Stripe API ࢧ෷ཤྺ ৄࡉϖʔδͷऔಘ ৄࡉऔಘ

    Invoiceऔಘ Stripe API ࣮૷ͷख͕ؒେ͖͍
  26. ࢧ෷ཤྺͷ֬ೝʢCustomer Portalʣ Ұཡऔಘ Customer Porta l URLੜ੒ Stripe API Customer

    Portal ࢧ෷ཤྺͷදࣔ ࢧ෷ཤྺ Ұཡϖʔδͷදࣔ
  27. ࢧ෷ཤྺͷ֬ೝʢϝϦοτɾσϝϦοτʣ Customer Portal ϑϧεΫϥον ϑϧεΫϥον Customer Portal ϝϦοτ ɾγʔϜϨεͳ૊ΈࠐΈ͕Մೳ σϝϦοτ

    ɾରԠ͕ඞཁͳը໘͕ଟ͍ ɾֹۚௐ੔ൃੜ࣌ͷ࣮૷͕ෳࡶ ϝϦοτ ɾ੥ٻॻɺྖऩॻͷμ΢ϯϩʔυ σϝϦοτ ɾ୯ൃܾࡁͷཤྺ͸දࣔ͞Εͳ͍ ࣮૷޻਺Λߟ͑ΔͱCustomer Portalʹ܉഑
  28. 4. ΫϨΧ৘ใ ͷมߋ

  29. ΫϨΧ৘ใͷมߋʢϑϧεΫϥονʣ ΫϨΧ৘ใมߋਃ͠ࠐΈ ਃ͠ࠐΈ Checkou t URLੜ੒ Stripe API ΫϨΧ৘ใΛొ࿥ Checkout

    σϑΥϧτΧʔυͷ੾ସ Webhook & Stripe API Checkout͚ͩͰ͸σϑΥϧτΧʔυͷ੾ସෆՄ
  30. ΫϨΧ৘ใͷมߋʢCustomer Portalʣ ਃ͠ࠐΈ Customer Porta l URLੜ੒ Stripe API Customer

    Portal ΫϨΧ৘ใͷొ࿥ ΫϨΧ৘ใมߋਃ͠ࠐΈ
  31. ΫϨΧ৘ใͷมߋʢϝϦοτɾσϝϦοτʣ Customer Portal ϑϧεΫϥον ϑϧεΫϥον Customer Portal ϝϦοτ ɾγʔϜϨεͳ૊ΈࠐΈ͕Մೳ σϝϦοτ

    ɾσϑΥϧτΧʔυͷ੾ସ͕ඞཁ ɾෳ਺ΧʔυରԠͷ࣮૷޻਺େ ϝϦοτ ɾෳ਺ΧʔυʹରԠ ɾσϑΥϧτΧʔυ੾Γସ͑ରԠ σϝϦοτ ࣮૷޻਺Λߟ͑ΔͱCustomer Portalʹ܉഑
  32. 5. ੥ٻઌ৘ใ ͷมߋ

  33. ੥ٻઌ৘ใͷมߋʢϑϧεΫϥονʣ ੥ٻઌ৘ใมߋਃ͠ࠐΈ ਃ͠ࠐΈ Custome r ߋ৽ Stripe API

  34. ੥ٻઌ৘ใͷมߋʢCustomer Portalʣ ਃ͠ࠐΈ Customer Porta l URLੜ੒ Stripe API Customer

    Portal ੥ٻઌ৘ใͷมߋ ੥ٻઌ৘ใมߋਃ͠ࠐΈ
  35. ੥ٻઌ৘ใͷมߋʢϝϦοτɾσϝϦοτʣ Customer Portal ϑϧεΫϥον ϑϧεΫϥον Customer Portal ϝϦοτ ɾϝλσʔλͷߋ৽΋͠΍͍͢ σϝϦοτ

    ϝϦοτ ɾϝʔϧɺॅॴͷมߋ͕Մೳ σϝϦοτ ɾ໊લͷมߋ͸ෆՄ ࣮૷޻਺Λߟ͑ΔͱCustomer Portalʹ܉഑
  36. શମతͳϝϦοτɾσϝϦοτ Customer Portal ϑϧεΫϥον ϑϧεΫϥον Customer Portal ϝϦοτ ɾࡉ͔ͳௐ੔͕Ͱ͖Δ σϝϦοτ

    ɾ࣮૷޻਺͕େ͖͘ͳΔ ɾܾࡁ·ΘΓͷมߋ࣌ͷख͕ؒେ͖͘ͳΔ ϝϦοτ ɾ࣮૷޻਺͕ݮΒͤΔ ɾܾࡁ·ΘΓͷมߋ͕͠΍͘͢ͳΔ σϝϦοτ ɾࡉ͔ͳίϯτϩʔϧ͸Ͱ͖ͳ͍ Ϗδωεͷಛੑʹ߹Θͤͯબ୒
  37. • toCͳͲͷηϧϑαʔϒ • ෳࡶͳྉۚମܥ • ྉۚମܥ͕ݻఆ • ϒϥϯσΟϯάΛॏࢹ ϑϧεΫϥον͕޲͍͍ͯΔέʔε ݸਓతݟղɿଟ͘ͷ৔߹

    Customer Portal Ͱे෼
  38. • Customer Portal Λ࢖͏ • Stripe Dashboard Λ׆༻͢Δ • Stripe

    APIΛۦ࢖͗͢͠ͳ͍ ʢԿͰ΋Ͱ͖Δ≠શ෦΍Δʣ มԽͷଟ͍SaaSͰͷΦεεϝ
  39. ҎԼͷૢ࡞ͷΈʹݶఆ • Webhook ͷड͚औΓ • Customer Portal ͷURLੜ੒ • Checkout

    ͷURLੜ੒ มԽͷଟ͍SaaSͰͷΦεεϝStripe APIར༻ํ਑ StripeͷΞοϓσʔτͷԸܙΛड͚΍͍͢
  40. $VTUPNFS1PSUBMΛ࢖ͬͯ ϏδωεͷมԽʹڧ͍ ܾࡁΛ