diff options
author | Christian Grothoff <christian@grothoff.org> | 2024-07-31 23:39:55 +0200 |
---|---|---|
committer | Christian Grothoff <christian@grothoff.org> | 2024-07-31 23:39:55 +0200 |
commit | c10874a858745b4205feabb38ed8f5e8bd11acc1 (patch) | |
tree | 1aa235f8e543ec5e2055bd6ac8b521b44b3840c2 /src/include/taler_merchantdb_plugin.h | |
parent | 854bad7d7c220c9ea9f4d61eb8fd46548a160da2 (diff) |
fix account_kyc_set_status
Diffstat (limited to 'src/include/taler_merchantdb_plugin.h')
-rw-r--r-- | src/include/taler_merchantdb_plugin.h | 54 |
1 files changed, 45 insertions, 9 deletions
diff --git a/src/include/taler_merchantdb_plugin.h b/src/include/taler_merchantdb_plugin.h index 3f27a138..96a3d001 100644 --- a/src/include/taler_merchantdb_plugin.h +++ b/src/include/taler_merchantdb_plugin.h @@ -79,6 +79,28 @@ struct TALER_MerchantAuthenticationSaltP GNUNET_NETWORK_STRUCT_END +/** + * Current exposed deposit limits by an exchange + * for a merchant (until other rules may apply). + */ +struct TALER_MERCHANTDB_DepositLimits +{ + /** + * Maximum amount to be deposited within @a timeframe. + */ + struct TALER_Amount threshold; + + /** + * Timeframe over which the limit applies. + */ + struct GNUNET_TIME_Relative timeframe; + + /** + * True if this is a soft limit that could be + * raised (by AML staff or by passing KYC checks). + */ + bool soft_limit; +}; /** * Details about a wire account of the merchant. @@ -512,9 +534,10 @@ struct TALER_MERCHANTDB_CategoryDetails * @param event_type event of the webhook */ typedef void -(*TALER_MERCHANTDB_WebhooksCallback)(void *cls, - const char *webhook_id, - const char *event_type); +(*TALER_MERCHANTDB_WebhooksCallback)( + void *cls, + const char *webhook_id, + const char *event_type); /** @@ -1668,12 +1691,13 @@ struct TALER_MERCHANTDB_Plugin * @return database result code */ enum GNUNET_DB_QueryStatus - (*account_kyc_get_status)(void *cls, - const char *merchant_id, - const struct TALER_MerchantWireHashP *h_wire, - const char *exchange_url, - TALER_MERCHANTDB_KycCallback kyc_cb, - void *kyc_cb_cls); + (*account_kyc_get_status)( + void *cls, + const char *merchant_id, + const struct TALER_MerchantWireHashP *h_wire, + const char *exchange_url, + TALER_MERCHANTDB_KycCallback kyc_cb, + void *kyc_cb_cls); /** * Update an instance's account's KYC status. @@ -1684,6 +1708,12 @@ struct TALER_MERCHANTDB_Plugin * @param exchange_url base URL of the exchange to check * @param exchange_kyc_serial serial number for our account at the exchange (0 if unknown) * @param timestamp timestamp to store + * @param exchange_http_status HTTP status code returned last by the exchange + * @param exchange_ec_code Taler error code returned last by the exchange + * @param access_token access token for the KYC process, NULL for none + * @param num_limits length of the @a limits array + * @param limits array with deposit limits returned by the exchange + * @param in_aml_review true if the exchange says the account is under review * @param kyc_ok current KYC status (true for satisfied) * @return database result code */ @@ -1695,6 +1725,12 @@ struct TALER_MERCHANTDB_Plugin const char *exchange_url, uint64_t exchange_kyc_serial, struct GNUNET_TIME_Timestamp timestamp, + unsigned int exchage_http_status, + enum TALER_ErrorCode exchange_ec_code, + const struct TALER_AccountAccessTokenP *access_token, + unsigned int num_limits, + const struct TALER_MERCHANTDB_DepositLimits *limits, + bool in_aml_review, bool kyc_ok); |