Api for adding payment details

Hi gents,
we’re evaluating invoiceninja for us. In fact we don’t need the gui of invoice ninja as we have a marketplace where we’re selling different products.

Means we would like to use invoiceninja fully via api.
We checked the api docs and understand the most important important api requests, like create customer accounts, create invoices etc.

We want to use a payment gateway like stripe or other ones to request the payment of the customers.
Is it possible with the invoice ninja api to save the payment details?

we would like to ask the customer to add his credit card or direct debit details in our plattform and store those details in invoice ninja.

Hi,

The app only supports saving the card details if the client pays for the invoice in the client portal.

ok, thx @hillel
Thats a show stopper for us.

That’s too bad, we need to design the app this way to be PCI compliant. The card details are stored by the payment gateway, we can’t have them go through our API.

@fok_ste

If you are only passing the payment token, and not payment details such as credit card numbers. this is supported. We have exposed in the API the token route so this is a supported use case.

The other way to stay compliant would be to use our endpoint which pulls in your customer and their payment methods from Stripe.

Would this flow work?

1st: create the customer in ninja
2nd IF customers selects creditcard: create the customer in stripe and add credit card details
IF customer select SEPA add the details to ninja.

But how can the customer in ninja and stripe linked?

Invoice Ninja uses email address to link stripe customers to invoice ninja customers.

So as long as the email addresses match, Invoice Ninja can stay in sync with Stripe.

1 Like

and how does it work for new invoices if the customer added his credit card details? (via api into stripe).
i.g.

Customer exists in ninja and stripe
stripe: credit card details added
ninja payment method: stripe is selected + 10 days payment terms

We’ll create invoices via api each month. How does it work with stripe? We’ll pay autom. based on the invoice data incl due date?

When you create the invoice via API, you can configure whether you want to also auto_bill the invoice. We will use the terms (10days net say) and bill on the 10th day if there is a valid payment method on file.

1 Like

sounds good.
Does ninja support sepa without a payment gateway?

@fok_ste

We don’t provide any gateway services ourselves, only through our gateway integrations.