Skip to content

Instantly share code, notes, and snippets.

@krissnawat krissnawat/sendOtp.js
Last active Jul 16, 2019

Embed
What would you like to do?
sendOtp = phone_number => {
fetch("https://api.ringcaptcha.com/1igu6oxxxxxx2aza8eda/code/sms", {
method: "POST",
headers: {
Accept: "application/json",
"Content-Type": "application/json"
},
body: `phone=${phone_number}&api_key=d3fb6xxxxxd010893edfe02c01f3c`
}).then(res => {
alert("OTP will delivery soon checking in next screen");
this.props.navigation.navigate("OTPVerfication", {
phone_number: phone_number
});
});
};
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.