diff options
author | Christian Grothoff <christian@grothoff.org> | 2021-07-20 19:33:59 +0200 |
---|---|---|
committer | Christian Grothoff <christian@grothoff.org> | 2021-07-20 19:33:59 +0200 |
commit | 362bf0c5bd2270ed6a54dfbdfd83702dca892797 (patch) | |
tree | 62dc70b9111810c1375fedfb75efff882bb5058d /src/backend/taler-merchant-httpd_helper.h | |
parent | 43dd7c8ae663fcb3db64fb7571c56144baa83a0e (diff) | |
download | merchant-362bf0c5bd2270ed6a54dfbdfd83702dca892797.tar.gz merchant-362bf0c5bd2270ed6a54dfbdfd83702dca892797.tar.bz2 merchant-362bf0c5bd2270ed6a54dfbdfd83702dca892797.zip |
-workshop refactoring
Diffstat (limited to 'src/backend/taler-merchant-httpd_helper.h')
-rw-r--r-- | src/backend/taler-merchant-httpd_helper.h | 50 |
1 files changed, 50 insertions, 0 deletions
diff --git a/src/backend/taler-merchant-httpd_helper.h b/src/backend/taler-merchant-httpd_helper.h new file mode 100644 index 00000000..5f478c18 --- /dev/null +++ b/src/backend/taler-merchant-httpd_helper.h @@ -0,0 +1,50 @@ +/* + This file is part of TALER + Copyright (C) 2021 Taler Systems SA + + TALER is free software; you can redistribute it and/or modify it under the + terms of the GNU Affero General Public License as published by the Free Software + Foundation; either version 3, or (at your option) any later version. + + TALER is distributed in the hope that it will be useful, but WITHOUT ANY + WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR + A PARTICULAR PURPOSE. See the GNU Affero General Public License for more details. + + You should have received a copy of the GNU Affero General Public License along with + TALER; see the file COPYING. If not, see <http://www.gnu.org/licenses/> +*/ + +/** + * @file taler-merchant-httpd_helper.h + * @brief helpers for shared logic + * @author Florian Dold + * @author Benedikt Mueller + * @author Christian Grothoff + */ +#ifndef TALER_EXCHANGE_HTTPD_HELPER_H +#define TALER_EXCHANGE_HTTPD_HELPER_H + + +#include "taler-merchant-httpd.h" + +/** + * check @a payto_uris for well-formedness + * + * @param payto_uris JSON array of payto URIs (presumably) + * @return true if they are all valid URIs (and this is an array of strings) + */ +bool +TMH_payto_uri_array_valid (const json_t *payto_uris); + + +/** + * Setup new wire method for the given @ payto_uri. + * + * @param payto_uri already validated payto URI + * @return new wire method object, never fails + */ +struct TMH_WireMethod * +TMH_setup_wire_account (const char *payto_uri); + + +#endif |