Missing API-key method signature for create Customer
jonassvalin opened this issue · comments
Version
1.0.0-beta18
Behaviour
The customer "Create" function only has one method signature, which does not take an API-key.
(defn ^IPersistentMap create [^IPersistentMap m] (cnv/customer->map (Customer/create m)))
Expected behaviour
The customer "Create" function should have an additional method signature which takes the API-key. Something similar to the charge "Create" function:
(defn create ([m] (cnv/charge->map (Charge/create (wlk/stringify-keys m)))) ([^String api-key m] (cnv/charge->map (Charge/create (wlk/stringify-keys m) api-key))))
Additional info
It is my understanding that you would need to pass your API-key to actually create real customers tied to your Stripe account. Am I correct that this is currently a missing feature? If so, would you encourage a pull request to add this?
Thanks!
Your understanding is incorrect. API key is set globally in the Stripe client, see integration tests.