diff options
author | ꦌꦫꦶꦏ꧀ꦦꦿꦧꦮꦑꦩꦭ꧀ <erik@darapsa.co.id> | 2021-07-16 23:02:24 +0800 |
---|---|---|
committer | ꦌꦫꦶꦏ꧀ꦦꦿꦧꦮꦑꦩꦭ꧀ <erik@darapsa.co.id> | 2021-07-16 23:02:24 +0800 |
commit | 4482f46ee073110c7c52d73bc8a8006437eba6f2 (patch) | |
tree | 01dc7dcd827b96e873d7ee13eae22ab8fdd12eae /pikul.c | |
parent | 6960f565208af11828920f262d201e9db7a9aba4 (diff) |
use_insurance turns out to be required
This one follows the example given for the boolean JSON value,
which is written as true or false.
The response is error 500, internal server error.
Despite the example, it says max length is 1 in the middle part
of the doc, so maybe it should be written as 1 or 0.
Will be tried next.
Diffstat (limited to 'pikul.c')
-rw-r--r-- | pikul.c | 6 |
1 files changed, 3 insertions, 3 deletions
@@ -15,7 +15,7 @@ extern void anteraja_services(const char *, const char *, double, char **, char extern size_t anteraja_services_handle(const char *, size_t, size_t, struct pikul_services **); extern void anteraja_order(const char *, const char *, const char *, const char *, const char *, const char *, const char *, const char *, const char *, const char *, int, - char **[], double, char **, char **); + char **[], _Bool, double, char **, char **); extern size_t anteraja_order_handle(const char *, size_t size, size_t nmemb, char **); extern void anteraja_cleanup(); @@ -115,7 +115,7 @@ double pikul_cost(const char *origin, const char *destination, double weight, co char *pikul_order(const char *trx_id, const char *service, const char *sender_name, const char *sender_phone, const char *origin, const char *sender_address, const char *receiver_name, const char *receiver_phone, const char *destination, - const char *receiver_address, int nitems, char **items[], double subtotal) + const char *receiver_address, int nitems, char **items[], _Bool insurance, double subtotal) { curl_easy_setopt(curl, CURLOPT_WRITEDATA, &waybill); char *url; @@ -125,7 +125,7 @@ char *pikul_order(const char *trx_id, const char *service, const char *sender_na case PIKUL_ANTERAJA: anteraja_order(trx_id, service, sender_name, sender_phone, origin, sender_address, receiver_name, receiver_phone, destination, receiver_address, - nitems, items, subtotal, &url, &post); + nitems, items, insurance, subtotal, &url, &post); handler = anteraja_order_handle; break; default: |