hps / heartland-nodejs

Heartland's node.js SDK for connecting to our Portico Payment Gateway.
GNU General Public License v2.0
10 stars 12 forks source link

Add missing gateway exceptions #21

Open charlie-s opened 7 years ago

charlie-s commented 7 years ago

I'd like to issue a PR for a patch that fills out additional exception mappings. Specifically, there are gateway exceptions that are missing.

Before I can do so, I was wondering what defines mapping_type, mapping_code, and mapping_message?

Use case: I'd like to have better error handling on my end. For example, when a transaction is requested and the transaction cannot be found, no mapping is found and I get a very generic error return new Error(gatewayRspMsg);.