@arc-publishing/sdk-identity
Version:
JS Identity SDK for working with Identity API
20 lines • 624 B
JavaScript
import JSONResponseHandler from '../serviceHelpers/JSONResponseHandler';
import Identity from './identity';
import { headers } from './constants';
export default function requestVerifyEmail(email) {
return fetch("".concat(Identity.apiOrigin, "/identity/public/v1/email/verify"), {
method: 'POST',
headers: headers,
body: JSON.stringify({ email: email })
})
.then(JSONResponseHandler)
.then(function (json) {
if (json.success) {
return true;
}
else {
throw json;
}
});
}
//# sourceMappingURL=requestVerifyEmail.js.map