According to the Stripe API documentation (Found here), to create a new charge, “a dictionary containing a user’s credit card details” needs to be submitted with the general charge information. How would I go about including a “dictionary” within the dictionary that defines the charge details?
[code] Dim form As new Dictionary
Dim card As new Dictionary
card.Value("number") = "4242424242424242"
card.Value("exp_month") = "01"
card.Value("exp_year") = "2015"
card.Value("cvc") = "123"
card.Value("address_zip") = "12345"
form.Value("amount") = "400"
form.Value("currency") = "usd"
form.Value("card") = card
HTTPS1.SetFormData(form)
HTTPS1.Secure = True
HTTPS1.ConnectionType = SSLSocket.SSLv3
HTTPS1.SetRequestHeader("Authorization", "Bearer " + App.StripeTestKey)
HTTPS1.Post(App.StripeAPI + "customers")
[/code]
The Create a new card API (Found here) also requires “a dictionary containing a user’s credit card details” so simply assigning the value to each variable produces an error.
Thanx for the help.