Connect platforms using the Sources API
Considerations for Stripe Connect platforms adding support for new payment methods using the Sources API If you need help after reading this, search our documentation or check out answers to common questions. You can even chat live with other developers in #stripe on freenode.
Stripe Connect platform owners can make use of additional payment methods supported with Sources. To learn more about creating payments for connected users, and which approach is best for you, refer to our Connect payments and fees documentation.
Creating destination charges
If you opt for destination charges, you should create Sources on your platform directly and create Charges using the appropriate destination parameter. Customers are charged by your platform, which then transfers the necessary amount to the destination account.
With destination charges, your platform is the merchant of record on the transaction and your platform name will appear on statement descriptors.
Creating direct charges
If you opt for direct charges, you will need to make sure that the connected account is onboarded on the payment method you intend to use (see below). Direct charges require creating sources on connected accounts. You can do so by passing source.stripeAccount with a value of a connected account’s ID when using Stripe.js.
// Set the connected Stripe Account on which the source should be created
var stripe = Stripe(
'pk_test_6pRNASCoBOKtIshFeQd4XMUh',
{stripeAccount: "acct_24BFMpJ1svR5A89k"},
);
stripe.createSource({
type: 'ideal',
amount: 1099,
currency: 'eur',
owner: {
name: 'Jenny Rosen',
},
redirect: {
return_url: 'https://shop.example.com/crtA6B28E1',
},
}).then(function(result) {
// handle result.error or result.source
});
If you’re creating sources server-side, you can make use of authentication using the Stripe-Account header with any of our supported libraries.
Onboarding of connected accounts
We are currently working on enabling Connect platforms to activate payment methods for their users programmatically. If you are interested in this functionality, please get in touch.
As a fallback, if you are relying on Standard accounts you can direct your users to their payment settings so that they can enable payment methods from the Stripe dashboard. Alternatively you can rely on destination charges with the caveat that your platform will be the merchant of record on these payments, not the connected account.