Setting Stripe's customer ID for members through FabMan's API

Hi,

we are using an external system for membership management which is using Stripe as payment processing backend. We would like to automatically add members to FabMan (through its API) when they sign-up with us and be able to set their Stripe customer ID in FabMan member object.

In the FabMan API: https://fabman.io/api/v1/members/{id}
(https://fabman.io/api/v1/documentation#!/members/getMembersId)
I can see “stripeCustomer” in the payload, but I cannot set it with PUT to https://fabman.io/api/v1/members/{id} (https://fabman.io/api/v1/documentation#!/members/putMembersId)

Is there any way (programmatically) that we could link a member in FabMan with an existing customer in Stripe ?

We would like to avoid asking members to provide their card information twice, especially that FabMan doesn’t allow them to set their own card info just yet.

Please let me know if that makes sense.

Update 1:
I can see the API for adding payment methods through Stripe tokens (POST /members/{id}/payment-methods), but we don’t handle the Stripe tokens, we only have Stripe customers’ IDs and their cards IDs.

Cheers,
Piotr

Hi Piotr,

we haven’t opened up the stripeCustomer field for modification because it seemed unlikely to be of any use – and would make it easier for people to shoot themselves in the foot.

But your use-case seems very reasonable. So I had a look at our implementation and I don’t see any immediate obstacles to trying your idea – it should work. :crossed_fingers:

I’d say we add stripeCustomer to POST/PUT for members with the next release and then you can give it a try. What do you think?

P.S.:

These tokens are a safe & secure way of transmitting credit card information to Stripe without having to route them though our servers (which would create lots of regulatory headaches). This API is only useful in conjunction with the Fabman Admin UI.

That will be very helpful. Looking forward to the next release!

Thanks
Piotr

Hi Piotr,

as promised, we’ve just deployed the API changes that let you submit the stripeCustomer field when creating or updating members.

Once you’ve set a member’s stripeCustomer, you should be able to see their stored credit card information when you go to the member’s detail page and click on “Charges & invoices”.

Please give it a try and let me know if it works for you.

There’s one caveat: Whenever you update a member in Fabman, Fabman will write the member’s name, email address and member number into the corresponding Stripe customer’s name, email and description fields. (To make sure you can find your members via the Stripe interface.) This may overwrite information if you manage your Stripe customers outside Fabman and give them a different name or email address.

Best regards,
Raphael

1 Like

Hi Raphael,

it works exactly as we expected - thank you.

Cheers,
Piotr

1 Like

We’ve got everything setup and it works like a charm!

Also, I’ve created some very basic Go-lang library for FabMan APIs (if anyone is looking for one): members-management/fabman at master · Marineholmen-Makerspace/members-management · GitHub

1 Like

Nice! Thank you. I’ll definitely have a look at it.