We can create payments and charge an application\_fee with Stripe connect in NodeJS as [follows](https://stripe.com/docs/connect/payments-fees):

```
// Get the credit card details submitted by the form
var token = request.body.stripeToken;

// Create the charge on Stripe's servers - this will charge the user's card
stripe.charges.create(
  {
    amount: 1000, // amount in cents
    currency: "eur",
    source: token,
    description: "Example charge",
    application_fee: 123 // amount in cents
  },
  {stripe_account: CONNECTED_STRIPE_ACCOUNT_ID},
  function(err, charge) {
    // check for `err`
    // do something with `charge`
  }
);

```

The source can be obtained using the Stripe native [checkout handler](https://stripe.com/checkout).

However, if I have a marketplace and I want to perform a checkout of multiple items that have different authors, how would I then proceed?

The problem is that I would need to create multiple charges from one source. But then the system will think that there is an error as the total amount (used when retrieving the stripeToken source) does not match the individual amounts (of the individual items).