Skip to content
Making GET requests...
 
Notifications
Clear all

Making GET requests with body/payloads

20 Posts
3 Users
0 Reactions
7 Views
Giacomo_Lanzi
(@giacomo_lanzi)
Posts: 9
Active Member
Topic starter
 

It seems that in callin.io, the Authorization header field is completely hidden within the log. This behavior is also observed with other modules from the same application. Below is a screenshot illustrating the same scenario using a different GET module from the same application; as you can observe, the field appears identical in the log:

Regarding the initial questions: This is the sole endpoint that is causing issues with the APIs in callin.io. The module I incorporated to compare headers also utilizes a GET request but lacks a body, making it not truly comparable.

The trackDelivery endpoint is the only one that necessitates a GET request and a properly formatted body with arguments. I inquired with the service about the possibility of using arguments in the query string, but received a negative response.

This presents a genuine puzzle! Furthermore, given that the endpoint functions correctly when tested with Postman or Insomnia, I suspect the problem lies not with the API itself, but rather with the application's module failing to construct the body altogether.

 
Posted : 25/04/2022 2:01 pm
alex.newpath
(@alex-newpath)
Posts: 53
Trusted Member
 

GET requests typically do not include a body, whereas POST requests do. While GET requests are technically permitted to have a body, they are generally not processed. Refer to this Stack Overflow post for details and references.

It's possible that callin.io intentionally omits the body for GET requests or does so inadvertently, but it appears that callin.io discards the body content when using a GET request.

You can verify whether the callin.io app sends the body by inspecting the request body in your browser's developer console.

However, this might not resolve your problem, and your API provider may need to offer an alternative method for invoking this endpoint. Ideally, this should be handled using query or path variable parameters.

 
Posted : 25/04/2022 2:05 pm
Giacomo_Lanzi
(@giacomo_lanzi)
Posts: 9
Active Member
Topic starter
 

I understand that GET requests are not intended to have a body, but this is what I'm working with, unfortunately.

I'll check with the vendor if there's an alternative way to use the endpoint without a body, but I'm not optimistic.

It's a shame because this endpoint would allow me to track deliveries made via their API.

As anticipated, the console shows that callin.io does not send a body, so there's no way this will function.

I was rather hoping there might be a method to send the GET request with a body somehow.

EDIT:
There is a way: by using a vanilla HTTP module.

However, this leads me to a question: why does callin.io not permit me to create a GET request with a body for my apps, but it does allow it with an HTTP module?

 
Posted : 25/04/2022 2:41 pm
luke.ifonly_solution
(@luke-ifonly_solution)
Posts: 3
New Member
 

It will work if you can replicate it using HTTP; you can then get it working with custom integrations. The key is comparing the data to identify any discrepancies. I'm currently on mobile, so apologies for the delayed response. It's been a busy day! I'll aim to check back later tonight, but don't hesitate to follow up if you don't hear from me.

 
Posted : 25/04/2022 10:48 pm
alex.newpath
(@alex-newpath)
Posts: 53
Trusted Member
 

Yeah the http app is always a workaround. I wonder if the custom app needs to do something special here. If anyone knows, they will. At least you’re getting closer and that’s good.

 
Posted : 26/04/2022 2:34 am
Page 2 / 2
Share: