Output Formats
The Xweather Data API supports multiple output formats to suit your data processing needs. By using the format=
parameter in your request, you can specify the desired format. If omitted, the API defaults to returning data in JSON format.
Format | Description |
---|---|
JSON | The default output format. Returns data as structured JavaScript Object Notation, ideal for web applications and programmatic parsing. |
GeoJSON | A geographic variant of JSON that encodes spatial data (e.g., points, polygons) alongside attributes. Suitable for mapping and GIS tools. |
TSV | Tab-Separated Values. A plain text format where each field is separated by a tab character. Useful for spreadsheet tools and data pipelines. |
CSV | Comma-Separated Values. A common flat-file format compatible with spreadsheets and databases. Widely used for analytics and reporting. |
Note: CSV and TSV formats support header customization through the
fields=
parameter, allowing you to select only the attributes relevant to your use case.