Stripe
現象 表題の通り。Stripeのテスト中に、 You cannot set the quantity for metered plans. というよくわからないエラーが出る。 解法 バージョンによっておそらく解法が異なる。両方試すと良い。 解法1 数量を0に指定する。 newSubscription("default", "pri…
現象 表題の通り。Stripeのテスト中に、 Attempt to read property "default_payment_method" on null というよくわからないエラーが出る。 解法 下記を確認 Billableモデル(\App\Models\Userなど)に対応するユーザがStripe上に存在しているか。 Billable…
タイトルの通り、使用量をStripeに登録しようとすると下記のようなエラーが発生。 Cannot create the usage record with this timestamp because timestamps must be after the subscription's last invoice period (or current period start time). 原因は…
現象 サブスクリプションプラン購入の下記コードで表題のエラー $_user->newSubscription("main", $_planId) ->create($_paymentMethod); 環境 Laravel 5.8 Laravel Cashier 10.0 解法 数量を0とする $_user->newSubscription("main", $_planId) ->quantity(…
表題の通りです。 環境 PHP 7.2.1 Laravel 5.8 コード 最小のソースコードを示しますので、ご自分の環境にあった形に修正を行ってください。 getCon…