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
stripe.tokens.create( | |
{ customer: req.params.stripe_customer_cccount }, | |
{ stripe_account: req.params.seller_stripe_account }, // id of the connected account | |
function(error, token) { | |
if (error) { | |
console.log(error.message); | |
res.error(error.message); | |
} | |
else{ |
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
stripe.tokens.create( | |
{ customer: req.params.stripe_customer_cccount}, | |
{ stripe_account: req.params.seller_stripe_account }, // id of the connected account | |
function(err, token) { | |
// callback | |
if (err) { | |
console.log(error.message); | |
res.error(error.message); | |
} | |
else{ |
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
stripe.customers.create({ | |
description: ('Stripe Account For ' + req.params.customer_email), | |
email: req.params.customer_email, | |
source: req.params.token | |
}, function(error, customer){ | |
if (error) { | |
console.log(error); | |
res.error(error.message); | |
} |
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
stripe.charges.createRefund( | |
req.params.chargeId, | |
refund_application_fee: true, | |
{stripe_account: req.params.stripeConnectedAccount}, | |
function(err, refund) { | |
if (err) { | |
res.error(err); | |
console.log(err); | |
} |
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
stripe.charges.createRefund( | |
req.params.chargeId, | |
{refund_application_fee: true}, | |
{stripe_account: req.params.stripeConnectedAccount}, | |
function(err, refund) { | |
if (err) { | |
res.error(err); | |
console.log(err); | |
} |
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
target 'MyApp' do | |
pod 'Stripe' | |
end |
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
func someFunctionName () { | |
print("Hello World!") | |
} |
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
someFunctionName() |
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
func someFunc (name: String) { | |
print(name) | |
} |
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
someFunc(name: "Farhan Syed") |