diff options
Diffstat (limited to 'src/exchange-lib/exchange_api_common.h')
-rw-r--r-- | src/exchange-lib/exchange_api_common.h | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/src/exchange-lib/exchange_api_common.h b/src/exchange-lib/exchange_api_common.h index 5655f5d3b..bea36258e 100644 --- a/src/exchange-lib/exchange_api_common.h +++ b/src/exchange-lib/exchange_api_common.h @@ -23,6 +23,18 @@ #include <gnunet/gnunet_util_lib.h> #include "taler_exchange_service.h" + +/** + * Extract the Taler error code from the given @a json object. + * Note that #TALER_EC_NONE is returned if no "code" is present. + * + * @param json response to extract the error code from + * @return the "code" value from @a json + */ +enum TALER_ErrorCode +TALER_EXCHANGE_json_get_error_code (const json_t *json); + + /** * Verify a coins transaction history as returned by the exchange. * |