Discussions

Ask a Question
Back to all

Adding Stripe Customer Id to Zuper Customer profile

hello,

How can I add a Stripe Customer ID to a customer in Zuper.

The client would have given card details with intent on our Ecom store, but I need a way to charge the client for future payments in Zuper, using that same card that was saved via the Ecom store.

I know that I can use the below Zuper url to get the card details of a given Zuper customer_uid.

https://us-west-1c.zuperpro.com/api/payments/customers/${customer_uid}/cards

I check the Stripe logs, I can see Zuper is sending a get request with the below body to get the card details

{
  "customer": "cus_ToFfLcGgAXTAi1",
  "limit": "10",
  "type": "card",
}

Zuper must be only saving the Stripe customer number. When a payment screen opens up it GETs the cards for the saved customer number in Stripe, allowing a card to be selected to get the stripe payment method, and then makes an API call to stripe with the below body to make the actual payment.

{  
  "amount":  "100",  
  "currency":  "CAD",  
  "customer":  "cus_ToFf****" ,  
  "metadata": {  
    "action_module":  "INVOICE",  
    "company_id":  "10***",  
    "company_uid": "9876601a-7254-48b0-a42a-****",  
    "invoice_uid":  "f1d45ac1-ae99-4e4f-a9d8-****",  
},  
  "payment_method":"pm_1S*****" ,  
  "payment_method_types": {  "0":  "card",  },
}

I do have an open ticket with Zupper Support, 135156, but at the time of submitting the ticket I was not aware of the information that i've put into this post.

Any information to accomplish this integration would be appreciated.

-Mitchell