質問履歴34 / 質問した後に気が付いたこと

「決済」及び「開発」関連用語集

カテゴリー: QA  閲覧数:285 配信日:2019-04-16 11:06


質問履歴34


I could create a Stripe account with the code below, but where can I find the code for this create method?
・2019/4/16
I could create a Stripe account with the code below, but where can I find the code for this create method?
\Stripe\Stripe::setApiKey("sk_test_xxxx");

$result = \Stripe\Account::create([
 "type" => "custom",
 "country" => "US",
 "email" => "bob@example.com",
]);

Stripe API

I tried to check the code of the Account object's create method, but I did not find it.
・Where is it?
・There is a similarly named createExternalAccount method, but I have not called this method name.
GitHub stripe-php/lib/Account.php
私は下記コードでStripeアカウントを作成できたのですが、しかし、このcreateメソッドのコードはどこで確認できますか?
\Stripe\Stripe::setApiKey("sk_test_xxxx");

$result = \Stripe\Account::create([
 "type" => "custom",
 "country" => "US",
 "email" => "bob@example.com",
]);

Stripe API

Accountオブジェクトのcreateメソッドのコードを確認しようと思って探したのですが、見つかりません。
・どこにあるのですか?
・似た名前のcreateExternalAccountメソッドはありますが、このメソッド名を私は呼び出していません。
GitHub stripe-php/lib/Account.php

I could create a Stripe account with the code below, but where can I find the code for this create method?

質問した後に気が付いたこと


Accountクラスのcreateメソッド呼出
→ Createトレイトのcreateメソッドが実行されている

▼/lib/Account.php
class Account extends ApiResource
{
   const OBJECT_NAME = "account";
   use ApiOperations\All;
   use ApiOperations\Create;
   //中略
}


▼/lib/ApiOperations/Create.php
namespace Stripe\ApiOperations;
/**
* Trait for creatable resources. Adds a `create()` static method to the class.
*
* This trait should only be applied to classes that derive from StripeObject.
*/
trait Create
{
   /**
    * @param array|null $params
    * @param array|string|null $options
    *
    * @return \Stripe\ApiResource The created resource.
    */
   public static function create($params = null, $options = null)
   {
       self::_validateParams($params);
       $url = static::classUrl();
       list($response, $opts) = static::_staticRequest('post', $url, $params, $options);
       $obj = \Stripe\Util\Util::convertToStripeObject($response->json, $opts);
       $obj->setLastResponse($response);
       return $obj;
   }
}


Stripeにおけるトレイト使用例

週間人気ページランキング / 4-26 → 5-2
順位 ページタイトル抜粋 アクセス数
1 YouTube | 動画サービス(課金販売できるプラットフォーム) 8
2 EMVCo | クレジットカード仕様(仕様) 3
2 Twitch | ゲーム実況配信サービス(課金販売できるプラットフォーム) 3
2 Stripe webhook 配信の問題 / 実際に受け取った警告メールの受信例 3
3 pixivFANBOX | クリエイター支援プラットフォーム(課金販売できるプラットフォーム) 2
3 Stripe Q13。決済成功時に、「請求に紐づけられたメールアドレス」に対して、メール送信したいのですが、 | QA(Stripe) 2
3 EMVレベル1 / EMVレベル2 / EMVCo とは? 2
3 「支払」と「送金」の違い | 違い 2
3 Saving Payment Methods / 支払い方法を保存する 2
3 EPUB | ファイルフォーマット(電子書籍) 2
4 普通送金とは? / 処理の流れ 1
4 Stripe Q32。Webhook のエンドポイントから適切な値を返さなかったときの停止措置について | QA(Stripe) 1
4 銀行法には『為替取引』の具体的な説明や定義の規定がない / 為替取引とは? / 資金決済法上の「為替取引」は、銀行法上の「為替取引」と同義 1
4 支払い 1
4 ライブ配信サービス | 課金販売できるプラットフォーム 1
4 Stripe Q16。PaymentIntentの支払いで郵便番号入力を求められる。Radar rules の ZIP code を無効にしているのに | QA(Stripe) 1
4 具体例(詳細) 1
4 質問履歴29 / A抜粋 / 感想 1
4 IBAN | 海外送金(送金) 1
4 クレジットカード決済 | 課金 1
2024/5/3 1:01 更新
指定期間人気ページランキング / 2020-5-28 → 2024-5-2
順位 ページタイトル抜粋 アクセス数
1 Stripeアカウントへログインする際、モバイル端末で受信したコード入力を求められる理由は? | その他エントリー(Stripe) 2010
2 EMVCo | クレジットカード仕様(仕様) 1271
3 Stripe Q13。決済成功時に、「請求に紐づけられたメールアドレス」に対して、メール送信したいのですが、 | QA(Stripe) 945
4 Stripe Q16。PaymentIntentの支払いで郵便番号入力を求められる。Radar rules の ZIP code を無効にしているのに | QA(Stripe) 902
5 クレジットカード決済 | 課金 881
6 Twitch | ゲーム実況配信サービス(課金販売できるプラットフォーム) 879
7 決済用語 855
8 Stripe Q50。 Connect 「Standardアカウント」で、自身に連結された子アカウントを、ダッシュボードから削除するには? | QA(Stripe) 824
9 Omise | 「支払」機能を有する決済系サービス(決済サービス) 768
10 Stripe Q1。Stripeにおける個人事業主の定義 | QA(Stripe) 761
11 pixivFANBOX | クリエイター支援プラットフォーム(課金販売できるプラットフォーム) 743
12 Stripe Q31。ダッシュボードでの「支払い作成」の見方について | QA(Stripe) 738
13 EMVレベル1 / EMVレベル2 / EMVCo とは? 729
14 YouTube | 動画サービス(課金販売できるプラットフォーム) 678
15 プリペイドカード | カード 646
16 EPUB | ファイルフォーマット(電子書籍) 589
17 サブスクリプション | 課金 563
18 Stripeで"No such token: src"と表示されたら、最初にAPIキーを確認する | Stripe エラー(Stripe) 544
19 Stripe Q74.「お客様のビジネスの詳細」とは何ですか? | Stripe 543
20 ファンティア | クリエイター支援プラットフォーム(課金販売できるプラットフォーム) 482
2024/5/3 1:01 更新