1

我是 Stripe 连接的新手。我正在尝试使用 Stripe connect 向源帐户收费并将其发送到目标帐户。以下代码中的源参数应根据https://stripe.com/docs/api/php#create_charge-source上的信息接受源帐户 ID 。但是我收到错误 com.stripe.exception.InvalidRequestException: No such token: cus_xxxxxx 其中 cus_xxxxxx 是我的主帐户中的一个客户帐户的客户 ID。

    Map<String, Object> chargeParams = new HashMap<String, Object>();
    chargeParams.put("amount", 1000);
    chargeParams.put("currency", "usd");
    chargeParams.put("source", ??);
    chargeParams.put("destination", DestinationAccountID);
    chargeParams.put("application_fee", 100);

    Charge.create(chargeParams);

请让我知道如何实现这一点,因为这一直在出错。我只想使用客户 ID 而不是令牌。

4

0 回答 0