GeoJSON Parser
Overview
You can use this Snap to parse geospatial data from a GML file or from a ZIP file that contains shapefiles.

Parse-type Snap
Works in Ultra Tasks
Limitations
This Snap requires an upstream File Reader Snap or Multi File Reader Snap that reads the input files from a GML file or from a ZIP file that contains shapefiles (.shp). The File Reader Snap or Multi File Reader Snap must appear immediately before this Snap in the pipeline. Currently, only GML v3 is supported. Also, GeoJSON output is not supported as downstream output for any database Snaps.
Known issues
application/zip or application/gml+xml;
charset=utf-8 as a file input stream. However, the output content type from
the File Reader Snap is binary/octet when the input file is read from SLDB. binary/octet to one of the following: - ZIP file: Change the content type to
application/zip. - GML file: Change the content type to
.application/gml+xml; charset=utf-8
Snap views
| View | Description | Examples of upstream and downstream Snaps |
|---|---|---|
| Input | The Snap requires an upstream File Reader Snap or Multi File Reader Snap (immediately preceding it in the pipeline) that reads the input files from a ZIP file that contains shapefiles (.shp) or a single GML file. |
|
| Output | Output is GeoJSON, which can then be used for any geospatial analytics or map applications. The output can also be loaded to a database outside of the SnapLogic platform. |
|
| Error |
Error handling is a generic way to handle errors without losing data or failing the Snap execution. You can handle the errors that the Snap might encounter when running the pipeline by choosing one of the following options from the When errors occur list under the Views tab. The available options are:
Learn more about Error handling in Pipelines. |
|
Snap settings
- Expression icon (
): Allows using pipeline parameters to set field values dynamically (if enabled). SnapLogic Expressions are not supported. If disabled, you can provide a static value.
- SnapGPT (
): Generates SnapLogic Expressions based on natural language using SnapGPT. Learn more.
- Suggestion icon (
): Populates a list of values dynamically based on your Snap configuration. You can select only one attribute at a time using the icon. Type into the field if it supports a comma-separated list of values.
- Upload
: Uploads files. Learn more.
| Field / Field set | Type | Description |
|---|---|---|
| Label | String |
Required. Specify a unique name for the Snap. Modify this to be more appropriate, especially if more than one of the same Snaps is in the pipeline. Default value: GeoJSON Parser Example: myGeoJSON Parser |
| Input format | Dropdown list |
Select the format of the file used in the upstream file reader. Default value: Shapefiles Example: GML file |
| Read all files | Checkbox | Appears when you select Shapefiles as the Input format. Read all the files in the ZIP file. Read all the files in the zip file. |
| Shapefiles | List all the shapefiles to be parsed. Click the
|
|
| Shapefile path | String/Expression | Specify the path to the shapefile you want to parse. The path should include
all folders to the file from the root directory. This property is a URL path to the directory where files will be searched. The expected syntax is: Default value: None Example: limit |
| Snap execution | Dropdown list |
Choose one of the three modes in
which the Snap executes. Available options are:
Default value: Execute Only Example: Validate and Execute |
Troubleshooting
| Error | Reason | Resolution |
|---|---|---|
| Unsupported file format. | File format is not supported. | Check if the file provided is a ZIP file containing a .shp file. |
| Shapefile not found. | No shapefile found at the root of the ZIP file. | Check if the shapefile is at the root of the ZIP file. If not, provide the correct path to the shapefile inside the ZIP file. |