コンテンツにスキップ
アカウントを作成
または
サインイン
Stripe ドキュメントのロゴ
/
AI に質問する
アカウントを作成
サインイン
始める
支払い
売上
プラットフォームおよびマーケットプレイス
資金管理
開発者向けのツール
概要
Stripe Payments について
構築済みのシステムをアップグレード
支払いの分析
オンライン決済
概要ユースケースを見つけるManaged Payments
Payment Links を使用する
決済ページを構築
    概要
    クイックスタート
    デザインをカスタマイズする
    追加情報を収集する
    税金を徴収する
    決済フローを動的に更新
    商品カタログを管理する
    サブスクリプション
    決済手段を管理
    顧客が現地通貨で支払いできるようにする
    割引、アップセル、オプション品目を追加する
    将来の支払いを設定する
    支払い中に支払い詳細を保存する
    サーバーで支払いを手動で承認する
    支払い後
      注文のフルフィルメント
      領収書と支払い済みの請求書を送信する
      リダイレクトの動作をカスタマイズ
      放棄されたカートを回復する
      コンバージョンファネルを分析
    Elements with Checkout Sessions API ベータ版の変更ログ
    従来の Checkout からの移行
    Checkout を移行して Prices を使用
高度なシステムを構築
アプリ内実装を構築
決済手段
決済手段を追加
決済手段を管理
Link による購入の迅速化
支払いインターフェイス
Payment Links
Checkout
Web Elements
アプリ内 Elements
決済シナリオ
カスタムの決済フロー
柔軟なアクワイアリング
オーケストレーション
店頭支払い
端末
他の Stripe プロダクト
Financial Connections
仮想通貨
Climate
ホーム支払いBuild a checkout pageAfter the payment

注

このページはまだ日本語ではご利用いただけません。より多くの言語で文書が閲覧できるように現在取り組んでいます。準備が整い次第、翻訳版を提供いたしますので、もう少しお待ちください。

放棄されたカートを回復する

Checkout でのカート離脱を回復して、収益を向上させる方法をご紹介します。

ページをコピー

E コマースでは、カゴ落ちとは、顧客が購入の完了前に決済フローを離れる場合のことです。顧客を Checkout に戻すには、リカバリーフローを作成して、購入を完了するようメールで顧客に連絡をします。

カゴ落ちのメールは、広義では顧客に新製品について知らせたり、クーポンや割引を提供したりするための「プロモーションメール」カテゴリーに分類されます。顧客にメールを送信するには、顧客がプロモーションメールの受信に同意している必要があります。Checkout は以下に役立ちます。

  1. プロモーションメールを送信できるように顧客からの同意を収集します。
  2. 顧客が Checkout を破棄したときに通知を受け取り、カートの破棄に関するメールを送信できるようにします。

プロモーションへの同意を収集する

プロモーション用コンテンツへの同意を収集するように Checkout を設定します。顧客のメールアドレスを収集して、Checkout にリダイレクトされる前にプロモーション用コンテンツへの同意をリクエストする場合、consent_collection[promotions] をスキップできます。

Command Line
cURL
curl https://api.stripe.com/v1/checkout/sessions \ -u "
sk_test_BQokikJOvBiI2HlWgH4olfQ2
:"
\ -d "line_items[0][price]"=
{{PRICE_ID}}
\ -d "line_items[0][quantity]"=1 \ -d customer=
{{CUSTOMER_ID}}
\ -d mode=payment \ --data-urlencode success_url="https://example.com/success" \ -d "consent_collection[promotions]"=auto

リカバリーを設定する

Checkout セッションは、その expires_at タイムスタンプに達すると、顧客が購入していなくても破棄されます。この場合、セッションにアクセスできなくなり、Stripe が checkout.session.expired Webhook を起動します。この Webhook をリッスンすることで、顧客を新しい Checkout セッションに戻して購入を完了してもらう機会を作ることができます。この機能を使用するには、セッションの作成時に after_expiration.recovery を有効にします。

Command Line
cURL
curl https://api.stripe.com/v1/checkout/sessions \ -u "
sk_test_BQokikJOvBiI2HlWgH4olfQ2
:"
\ -d "line_items[0][price]"=
{{PRICE_ID}}
\ -d "line_items[0][quantity]"=1 \ -d mode=payment \ --data-urlencode success_url="https://example.com/success" \ -d customer=
{{CUSTOMER_ID}}
\ -d "consent_collection[promotions]"=auto \ -d "after_expiration[recovery][enabled]"=true \ -d "after_expiration[recovery][allow_promotion_codes]"=true

カート放棄についての通知を受ける

Listen to the checkout.session.expired webhook to be notified when customers abandon Checkout and sessions expire. When the session expires with recovery enabled, the webhook payload contains after_expiration, which includes a URL denoted by after_expiration.recovery.url that you can embed in cart abandonment emails. When the customer opens this URL, it creates a new Checkout Session that’s a copy of the original expired session. The customer uses this copied session to complete the purchase.

注

For security purposes, the recovery URL for a session is usable for 30 days, denoted by the after_expiration.recovery.expires_at timestamp.

{ "id": "evt_123456789", "object": "event", "type": "checkout.session.expired", // ...other webhook attributes "data": { "object": { "id": "cs_12356789", "object": "checkout.session", // ...other Checkout Session attributes "consent_collection": { "promotions": "auto", }, "consent": { "promotions": "opt_in" }, "after_expiration": { "recovery": { "enabled": true, "url": "https://buy.stripe.com/r/live_asAb1724", "allow_promotion_code": true, "expires_at": 1622908282, } } } } }

リカバリーメールを送信する

To send recovery emails, create a webhook handler for expired sessions and send an email that embeds the session’s recovery URL. A customer might abandon multiple Checkout Sessions, each triggering its own checkout.session.expired event so make sure to record when you send recovery emails to customers and avoid spamming them.

Node
// Find your endpoint's secret in your Dashboard's webhook settings const endpointSecret = 'whsec_...'; // Using Express const app = require('express')(); // Use body-parser to retrieve the raw body as a buffer const bodyParser = require('body-parser'); const sendRecoveryEmail = (email, recoveryUrl) => { // TODO: fill me in console.log("Sending recovery email", email, recoveryUrl); } app.post('/webhook', bodyParser.raw({type: 'application/json'}), (request, response) => { const payload = request.body; const sig = request.headers['stripe-signature']; let event; try { event = stripe.webhooks.constructEvent(payload, sig, endpointSecret); } catch (err) { return response.status(400).send(`Webhook Error: ${err.message}`); } // Handle the checkout.session.expired event if (event.type === 'checkout.session.expired') { const session = event.data.object; // When a Checkout Session expires, the customer's email isn't returned in // the webhook payload unless they give consent for promotional content const email = session.customer_details?.email const recoveryUrl = session.after_expiration?.recovery?.url // Do nothing if the Checkout Session has no email or recovery URL if (!email || !recoveryUrl) { return response.status(200).end(); } // Check if the customer has consented to promotional emails and // avoid spamming people who abandon Checkout multiple times if ( session.consent?.promotions === 'opt_in' && !hasSentRecoveryEmailToCustomer(email) ) { sendRecoveryEmail(email, recoveryUrl) } } response.status(200).end(); });

オプションセッションの有効期限を調整する

オプションコンバージョン率を追跡する

オプションリカバリーメールでプロモーションコードを提供する

このページはお役に立ちましたか。
はいいいえ
お困りのことがございましたら 、サポートにお問い合わせください。
早期アクセスプログラムにご参加ください。
変更ログをご覧ください。
ご不明な点がございましたら、お問い合わせください。
LLM ですか?llms.txt を読んでください。
Powered by Markdoc