If you download the Postman collection (from the downloads tab), install it and its associated environment, you can also run all the calls of this tutorial to see how Postman should react. I hope this helps, even if the programming language is not the same.įor more details, the entire workflow of a scheduled extraction is described in REST API Tutorial 12. We do not have C++ samples, but if you download the Java samples (from the downloads tab) and look at one of the three "DSS2ImmediateSchedule" samples you will easily understand the logic, and how we save the compressed data file to disk. It will automatically decompress the contents, and display them on screen (there are limits to the file size Postman can handle, so don't request too much data otherwise it will hang). Second, Postman will not save the file to disk. If you did use a GET, then could you post the error that was delivered with the 400 Bad Request ? It will help to debug. Is there any way to download file when I send the request but without click Send and download. Did you do a GET or a POST to this URL ? You need to do a GET. Hi guys, Now I have an interface which use to download file. I don't know why you got a 400 Bad request. Please correct me if my assumption is wrong.įirst of all, to retrieve the data, you do not need to provide a filename but an extracted file ID, so you are perfectly correct in making a call to (‘VjF8MHgwNWNjOWMxYWUwZmIyZjk2fA’)/$value, that is the correct way to retrieve the file contents. I'm guessing you are doing a scheduled extraction, using an instrument list, report template and schedule. Tick-history-rest-api Download Jerome Guiot-Dorel, In the response pane, select Save Response and then select Save as example. Saving a response as an example When saving a response in Postman, you have the option to save it as an example. I tried this with Postman : (‘VjF8MHgwNWNjOWMxYWUwZmIyZjk2fA’)/$valueand got 400 Bad request Obviously I am aware I do not provide a filename but as my previous request gave me the result below, I thought a _OnD_ file were going to appear somewhere on my disk. To ensure optimal Postman performance, example responses must be smaller than 5 MB. Once a request is completed, is there a simple HTTP request which allows to download a file on my own machine ? If you see a message like the following, the GET request was successful.It seems much more difficult to download the results in a file than with the TRTH SOAP version.
I have mine saved as a preset, which you can do by clicking “Manage Presets.”Īfter you’ve entered your API key, click Send. Make sure you enter your x-api-key in the header. Select a GET request to complete from your new collection via the sidebar on the left.
But just in case, here’s how you can verify them in Postman. Since you imported the endpoints directly from the PureStake API portal, they should work automagically. This will create a collection of API endpoints within Postman. When prompted, leave both Import as an API and Generate a Postman Collection checked. Select the JSON file from your downloads folder. You’ll end up on this dashboard.Ĭlick on the Import button at the top of your screen.
Open the Postman desktop application and log in, if you haven’t already. This will download the Swagger JSON file that you will import into Postman.
At the bottom of the Response body code editor, you will see a Download button. Scroll down to the Server response section. Click the Try it out button.Īlternativley, if you are already using the API, you can also request the JSON file with cURL or Postman.
Click the /swagger.json in the accordion menu to see more options. Once logged in, click over to the APIs section and choose the network (e.g., Algorand BetaNet, TestNet, or MainNet) in the left sidebar. If you don’t already have a PureStake API key, refer to this tutorial. To retrieve yours, log into your PureStake API account. In order to import the collection of endpoints, you’ll need the JSON file.