search - Searching for invoices with Paypal-PHP-SDK fails -
i'm unable search invoices based on invoice status. have tried following:
//$searchstring = '[{ // "status" : "sent", // "page" : 0, // "page_size" : 0, // "total_count_required" : true // }]';
this above search string returns http response 500.
$searchstring = '{ "status" : "sent", "page" : 0, "page_size" : 0, "total_count_required" : "true" }';
this above search string returns "{"name":"validation_error","message":"invalid request - see details.","debug_id":"e8b3b40ca05f4","details":[{"field":"status","issue":"can not deserialize instance of java.util.arraylist out of value_string token @ line:1, column:2"}]}".
//$searchstring = '{ // "page" : 0, // "page_size" : 0, // "total_count_required" : true // }';
the above search string returns invoices.
$search = new search($searchstring); $invoices = invoice::search($search, $apicontext);
has been able search based on invocie status?
thanks jim
just ran issue myself. little late @jim answer put stats in array. way can query multiple status.
"status" : ["sent"],
or mulitiple
"status" : ["sent", "paid"],
hope helps someone
Comments
Post a Comment