Ask a Question

Why my API requests have suddenly stopped working?

SOLVED
Jagruuti
Contributor

Why my API requests have suddenly stopped working?

Suddenly, my API requests are not producing any response. They are just getting executed for an infinite amount of time. But the same requests are working in Postman.

Please find the attached screenshot for reference.

 

 

9 REPLIES 9
richie
Community Hero

Hey @Jagruuti,

I've had this several times myself.

What i do when i get this scenario, is that i grab the RAW request from ReadyAPI! and grab the RAW request from Postman and compare the two against each other....payload, http headers, full url string (servername and URI) etc.....that'll enable you to identify what the issue is.

I like the Fiddler app for this sort of diagnostic analysis (it proxies the requests/responses), but it's not essential, but its a great tool that'll help with other issues where you need to compare between Postman and ReadyAPI!/SoapUI.

Oh, btw. Regarding the image you attached. You scribbled out a lot of stuff you dont actually need to. You dont need to scribble out stuff like teststep names to ensure youre covering off the security aspects. For future reference you need to blank out the 'servername' (NOT the URI....just the host/servername) and any authorisation/authentication details like usernames and passwords/token details, etc. If you consider the details a black hat would need to cause problems (i.e. the servername and auth details) that should guide you in determining what needs to be blanked/scribbled out. Without these details (host/servername and auth details) someone with nefarious intentions would have no place to start.

Ok, thats all i got for now!

Nice one,

Rich
if this helped answer the post, could you please mark it as 'solved'? Also if you consider whether the title of your post is relevant? Perhaps if the post is solved, it might make sense to update the Subject header field of the post to something more descriptive? This will help people when searching for problems. Ta

Hi @richie ,

 

Thanks for the info!

I have installed and trying to explore Fiddler 4. Can you help me to know how will I compare the ReadyAPI/SOAPUI and Postman requests in Fiddler 4?

 

Thanks and Regards,

  Jagruuti Wani

Hey @Jagruuti,

To use Fiddler to compare Postman vs ReadyAPI! traffic you need to setup both to use proxies (and Fiddler is the proxy).

1. Setup the Postman proxy first (if done correctly you update the Internet Options control panel applet) picking an appropriate port number. Once youve set this up, its enabled by default (you dont have to turn it on unlike ReadyAPI!).

2. Next launch ReadyAPI! proxy settings in the Preferences and pick the same port number that you specified as the proxy port for Postman. Enable the proxy in ReadyAPI!

3. In Fiddler ensure youve installed the certificate etc. that is needed and then via the Options, ensure Capture and Decrypt HTTP traffic tickboxes are checked.

4. Ensure Fiddler is set to listen on the same port number as the Postman and ReadyAPI! proxy settings.

4. Ensure Fiddler isnt maximised so that other apps when open can still be seen behind Fiddler (make the Fiddler window half the size of full screen).

5. Close all apps except Fiddler (half size, not maximised), Postman (maximised), and ReadyAPI! (minimised).

6. Restart Fiddler (half size, not maximised) to ensure any changes previously are persisted

7. Via the 'Any Process' button, click on it and drag it to Postman to identify Postman as the app from which traffic needs to be recorded.

8. Make submission via Postman, this should write >=1 row in the Session List frame in Fiddler.

9. Minimise Postman, maximise ReadyAPI!, then click back on Fiddler so that the window is sitting in front of a maximised ReadyAPI! window.

10. Click on the Fiddler button that was originally 'Any Process', but currently says something like 'postman:18404' and drag to ReadyAPI! to identify ReadyAPI! as the app from which traffic needs to be recorded.

11. Make submission via ReadyAPI!, this should write >=1 row in the Session List frame in Fiddler.

12. Click on the Postman submission in Fiddlers Session List and then via the Inspectors tab, grab the Raw content for the request (headers and payload) and copy into a notepad file.

13. Click on the ReadyAPI! submission in Fiddlers Session List and then via the Inspectors tab, grab the Raw content for the request (headers and payload) and copy into a notepad file.

So now you can compare and contrast the request details that work in Postman against the failing request in ReadyAPI!

did you say the request was just hanging in ReadyAPI!? That leads me to believe theres something pretty essential wrong as youre not even getting an http response making me think your endpoint isnt even getting the request.

Anyway. Please confirm back progress as this will help others with similar issues.

Nice one,

Oh...sorry for the lengthy post!

Rich

if this helped answer the post, could you please mark it as 'solved'? Also if you consider whether the title of your post is relevant? Perhaps if the post is solved, it might make sense to update the Subject header field of the post to something more descriptive? This will help people when searching for problems. Ta

Hi @richie ,

 

My request is just hanging in ReadyAPI/SOAPUI. I have also raised a support request but till then trying out if I can find something.

 

Thanks and Regards,

Jagruuti

Hey @Jagruuti,

I seriously doubt this is an issue with ReadyAPI!.

You say the request is hanging so youre not getting a response in ReadyAPI!/SoapUI.
If youre not getting a response from your endpoint, then id have a good luck at the full URL you are posting to, cos your endpoint isnt responding cos (occams razor) its not even receiving the request. Quick guess have you got an extra forward slash in the path somewhere? Cos that would cause the behaviour your are reporting. Look for something like this.

If youve done the Fiddler comparison you should be able to identify the issue.

If you publish the RAW details (headers, payload and full url) from both the ReadyAPI! and Postman requests to the forum people will probably be able to identify what the problem is.

Nice one

Rich
if this helped answer the post, could you please mark it as 'solved'? Also if you consider whether the title of your post is relevant? Perhaps if the post is solved, it might make sense to update the Subject header field of the post to something more descriptive? This will help people when searching for problems. Ta

Hi @richie ,

 

Thank you for your good post. I tried using the system proxy settings but that is also blocked by our organization.

I tried comparing the headers, URL and payload but that did not help much. Maybe fiddler can help more. 

 

If Fiddler is the proxy, how I can set up that in the Postman? I tried doing the settings in the Postman but I didn't get what should I set up there. 

Jagruuti_0-1597160051381.png

Thanks and Regards,

Jagruuti 

Hey @Jagruuti,

Im sorry i obviously didnt explain properly. I dont mean a proxy server like the typical proxy that caches web pages or a reverse proxy to harden a system.

A proxy can be anything that you can imagine sits in between your client and your endpoint. (E.g. A proxy server, a reverse proxy, an api gateway, an ESB, an integration platform, whatever) . Some things proxying your request alter the content of the requests (like the adaptor in an ESB) and some don't like Fiddler in this case.
The reasons requests are proxied a large and varied.

In regards to what im talking about, Fiddler is proxying your requests....you are passing your requests via Fiddler (which doesnt change the requests at all) enabling you to do the analysis.

So! Ignore everything you think you know about proxy servers and just follow the instructions i gave you. This will setup Fiddler to read your requests and responses.

Ta

Rich
if this helped answer the post, could you please mark it as 'solved'? Also if you consider whether the title of your post is relevant? Perhaps if the post is solved, it might make sense to update the Subject header field of the post to something more descriptive? This will help people when searching for problems. Ta

Hi @richie,

 

I have edited my post above. You can understand I'm stuck at what step.

 

Thanks and Regards,

Jagruuti

Hi @richie ,

 

It is working now.

1) It was actually the proxy setting issue which was done by the support team and hence my normal requests were not working.

2) And the incorrect event handler script added to the test case which automatically gets added to all the test cases.

 

I found this when I enabled the proxy setting in Postman and my requests stopped working. And then I realised that the issue in ReadyAPI/SOAPUI which has to do something with the proxy. So I checked the proxy setting which was actually ON as shown below.

Jagruuti_0-1597214469930.png

And now I have made it OFF and it is absolutely working fine.

Thanks for your help too!

 

Regards,

Jagruuti

 

 

cancel
Showing results for 
Search instead for 
Did you mean: