I’m trying to use an endpoint REST API Call to customer to get customer profile by referenceId.
I’m using this post
curl https://connect.squareupsandbox.com/v2/customers/search \
-X POST \
-H 'Square-Version: 2023-03-15' \
-H 'Authorization: Bearer ****************\
-H 'Content-Type: application/json' \
-d '{
"query": {
"filter": {
"reference_id": {
"exact": "******"
}
}
}
}'
Which returns the correct customer profile as needed on PostMan and on the API Explorer …
but when I call the API from my application using
plsql_rest_sender_API.Call_Rest_EndPoint_Json_Sync(rest_service_ => ,
json_ => ,
url_params_ => ,
callback_func_ => ,
http_method_ => ,
http_req_headers_ => ,
query_parameters_ => ,
header_params_ => ,
incld_resp_info_ => ,
fnd_user_ => ,
key_ref_ => ,
sender_ => ,
receiver_ => ,
message_type_ => ,
subject_ => ,
in_order_ => ,
fail_notify_ => ,
failed_callback_fun_ => ,
accepted_res_codes_ => ,
auth_params_ => )
IT either gives error if passed the query in the query_parameters_ or returns the 1st customer always if passed it in the url_params_
Any advice?
please, I do really appreciate if someone used this apis in Oracle PL/SQL packages to give any examples.
Thank you