-
-
Save mtso/ec08de0eb7b31bf27b047c986be681d9 to your computer and use it in GitHub Desktop.
kyc tokenization example
This file contains 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
WePay.set_endpoint("stage"); // change to "production" when live | |
WePay.tags.insert(); | |
WePay.kyc.create({ | |
"client_id": "9876", | |
"account_id": "1234", | |
"individual": { | |
"account_owner": { | |
"name": { | |
"first": "Foo", | |
"last": "Bar" | |
}, | |
"address": { | |
"address1": "123 Fake Street", | |
"city": "Montreal", | |
"postal_code": "H32 2YZ", | |
"region": "QC", | |
"country": "CA" | |
}, | |
"phone": { | |
"country_code": "+1", | |
"phone_number": "5556667777" | |
}, | |
"date_of_birth": { | |
"year": 1900, | |
"month": 1, | |
"day": 1 | |
}, | |
"email": "example@example.com", | |
"ca_owner_compliance": { | |
"social_insurance_number": "046 454 286" | |
} | |
}, | |
"mcc": "7999" | |
} | |
}, function(data) { | |
if (data.error) { | |
//do something | |
} else { | |
//Success! | |
//data.account_kyc_id will be set with the corresponding id which | |
//needs to be authorized | |
} | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment