Open podviaznikov opened 10 years ago
Thanks for the report. I've confirmed that it's a bug with extracting multi-word resource names (it was looking for the underscored_version, but the keywords had already been converted-to-dashes).
I've got a work-in-progress fix (#3) that you can try out right now. I'll try to get it into a patch release soon.
Some more clarification:
nil
because the library was returning the value of the key :recurring_application_charge
in the response, but by that point other code had transformed the key to :recurring-application-charge
. I need to make all the code for converting between dashes and underscores less brittle.Thank you for looking into it!
Hi, I can confirm that call for creating charge is working.
Can you please tell me how to activate charge?
I'm not quite sure with what parameters to call save!
for such resource /admin/recurring_application_charges/455696195/activate.json
.
Good question. I don't think there's a very good way of doing this right now that is integrated into the documented API of this library. However, you can build up the request manually and send it like so:
(defn activate-recurring-charge!
"Sends a request to activate the charge with the given id"
[id auth]
(-> auth
(assoc
:method :post
:uri (str "/admin/recurring_application_charges/" id "/activate"))
(shopify.resources/request)))
(shopify.resources/request
is the function that actually performs the request)
Thanks! That worked
Hi,
thanks for the great library. I think it is really well designed.
I'm having some trouble with billing API.
Do you think this code should work? Should it return something? I have proper
auth
object.Another question: can I see some debug information? For me this method returns just
nil
.