- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Accept.js encryption failed
Can we generate the dataDescriptor & dataValue without providing the Credit card details.
Im trying to load the function using document.ready.
Below is the code.
<script type="text/javascript">
$(document).ready(function(){
loadAuthNetKey();
});
</script>
<script type="text/javascript">
function loadAuthNetKey(){
var secureData = {}, authData = {};
authData.clientKey = '$hostKey';
authData.apiLoginID = '$paymentGateWayHostID';
secureData.authData = authData;
Accept.dispatchData(secureData, 'responseHandlerSave');
}
function responseHandlerSave(response)
{
console.log(JSON.stringify(response));
if (response.messages.resultCode === 'Error') {
for (var i = 0; i < response.messages.message.length; i++) {
unBlock();
//console.log(response.messages.message[i].code + ':' + response.messages.message[i].text);
alert(response.messages.message[i].text)
return false;
}
}
else {
useOpaqueData(response.opaqueData)
}
}
</script>
In response i need the dataDescriptor and dataValue. But im getting the Accept.js encryption failed.
Kindly help me what is wrong in my code.
Thanks,
Ganesh
โ09-04-2017 04:42 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi @ganeshkunte,
No, there's no way to get the token representing the card number without providing the card number that you want the token to be for.
What exactly are you hoping to do by getting a token without card details?
โ09-05-2017 01:34 PM

