Skip to main content
Question

Use HTTPCaller to download file, to use in my workflow


I want to create a workflow that downloads a file from the internet (SHP file compressed as ZIP file). That file should then be used in my workflow for further analysis and processing.

 

How should I set that up? I now have a "Creator", followed by a 'HTTPCaller'. This HTTPCaller downloads my ZIP file (contains a SHP file). How can I now use this data for further processing? When I use a ESRI SHP File Reader, I can't seem to send this file as an input to that Reader?

 

 

9 replies

tomfriedl
Contributor
Forum|alt.badge.img+13
  • Contributor
  • May 10, 2023

You can use the transformer FeatureReader to read your SHP-File after download.


hkingsbury
Celebrity
Forum|alt.badge.img+53
  • Celebrity
  • May 10, 2023
tomfriedl wrote:

You can use the transformer FeatureReader to read your SHP-File after download.

Also make sure your are saving your response body to a file/folder. The path you pass to the FeatureReader will be the "_reponse_file_path" attributeimage 


geomancer
Evangelist
Forum|alt.badge.img+47
  • Evangelist
  • May 11, 2023
tomfriedl wrote:

You can use the transformer FeatureReader to read your SHP-File after download.

If you don't want to save the response body permanently, insert a TempPathnameCreator before the HTTPCaller. Store the downloaded zip file in the path created by this transformer. That way, the downloaded data will automatically be removed at the end of the workspace.

TempPathnameCreator_HTTPCaller_FeatureReader


  • Author
  • May 11, 2023
tomfriedl wrote:

You can use the transformer FeatureReader to read your SHP-File after download.

FeatureReader does the trick! That's an awesome transformer. Thanks.


  • Author
  • May 11, 2023
hkingsbury wrote:

Also make sure your are saving your response body to a file/folder. The path you pass to the FeatureReader will be the "_reponse_file_path" attributeimage 

Good tip, thanks, just what I needed.


  • Author
  • May 11, 2023
geomancer wrote:

If you don't want to save the response body permanently, insert a TempPathnameCreator before the HTTPCaller. Store the downloaded zip file in the path created by this transformer. That way, the downloaded data will automatically be removed at the end of the workspace.

TempPathnameCreator_HTTPCaller_FeatureReader

Great suggestion too. Learning so much today!


virtualcitymatt
Celebrity
Forum|alt.badge.img+35

Depending on how you are getting the URL you can also just read directly from a URL in either the feature reader of normal reader.

 

image


  • Author
  • May 11, 2023
virtualcitymatt wrote:

Depending on how you are getting the URL you can also just read directly from a URL in either the feature reader of normal reader.

 

image

thanks, will keep that in mind, i might need that


hodsen96
Contributor
Forum|alt.badge.img+4
  • Contributor
  • March 13, 2025
geomancer wrote:
tomfriedl wrote:

You can use the transformer FeatureReader to read your SHP-File after download.

If you don't want to save the response body permanently, insert a TempPathnameCreator before the HTTPCaller. Store the downloaded zip file in the path created by this transformer. That way, the downloaded data will automatically be removed at the end of the workspace.

TempPathnameCreator_HTTPCaller_FeatureReader

When I do the same, I end up having to expose the attributes after the feature reader using an AttributeExposer, is that intended? Is there a setting in the feature reader i should be utilizing to avoid this?


Reply


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings