Created
May 15, 2016 17:26
-
-
Save thorwebdev/65b258f0fa5805f8bd30feaa8338127f to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
get '/customer/:cid' do | |
# Output params hash in bash | |
puts params.inspect | |
# Retrieve customer ID from params hash | |
cid = params[:cid] | |
# Retrieve customer object from Stripe API | |
# Store customer object in an instance variable | |
@customer = Stripe::Customer.retrieve(cid) | |
# Show customer.erb template to user | |
erb :customer | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment