{"id":21558131,"url":"https://github.com/koopjs/koop-provider-csv","last_synced_at":"2025-04-10T10:41:57.971Z","repository":{"id":40294249,"uuid":"156312096","full_name":"koopjs/koop-provider-csv","owner":"koopjs","description":"Koop provider for CSV","archived":false,"fork":false,"pushed_at":"2023-04-24T18:38:10.000Z","size":607,"stargazers_count":5,"open_issues_count":1,"forks_count":3,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-03-24T09:38:17.645Z","etag":null,"topics":["csv","koopjs","plugin","provider"],"latest_commit_sha":null,"homepage":null,"language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/koopjs.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2018-11-06T02:10:25.000Z","updated_at":"2023-03-27T18:24:49.000Z","dependencies_parsed_at":"2023-02-05T02:00:50.182Z","dependency_job_id":null,"html_url":"https://github.com/koopjs/koop-provider-csv","commit_stats":null,"previous_names":[],"tags_count":6,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/koopjs%2Fkoop-provider-csv","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/koopjs%2Fkoop-provider-csv/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/koopjs%2Fkoop-provider-csv/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/koopjs%2Fkoop-provider-csv/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/koopjs","download_url":"https://codeload.github.com/koopjs/koop-provider-csv/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248199394,"owners_count":21063669,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["csv","koopjs","plugin","provider"],"created_at":"2024-11-24T08:14:04.704Z","updated_at":"2025-04-10T10:41:57.951Z","avatar_url":"https://github.com/koopjs.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# koop-provider-csv\n\nA configurable and reusable [CSV](https://en.wikipedia.org/wiki/Comma-separated_values) provider for [Koop](http://koopjs.github.io/), created with [Koop CLI](https://github.com/koopjs/koop-cli)\n\nThis provider can load a CSV file from a local path or a remote endpoint. The provided CSV file must include columns of latitude and longitude coordinates.\n\n## Features\n\n- fully configurable\n- support multiple CSV sources\n- support local file path or remote endpoint\n- support multiple CSV files for a single source\n- parse boolean and numeric values automatically\n- stream processing\n\n## Installation\n\nwith npm\n\n```bash\nnpm install koop-provider-csv\n```\n\nwith [Koop CLI](https://github.com/koopjs/koop-cli) for your Koop app\n\n```bash\nkoop add provider koop-provider-csv\n```\n\n## Usage\n\nOnce installed, this provider enables routes like\n\n```\n/koop-provider-csv/:id/FeatureServer/*\n```\n\nwhere `id` is the unique ID for a source CSV defined in the configuration file.\n\nFor example, this route allows to query a CSV file with ID `my-csv`:\n\n```\n/koop-provider-csv/my-csv/FeatureServer/0/query\n```\n\n## Configuration\n\nThis provider is configured with [config](https://github.com/lorenwest/node-config) and all configuration files are in the `config` directory.\n\nA configuration looks like this:\n\n```javascript\n{\n  // configuration namespace for this provider plugin\n  \"koop-provider-csv\": {\n    // define one or multiple CSV sources\n    \"sources\": {\n      // a unique ID for each source, which is used in the query route\n      \"my-csv\": {\n        // [optional] a URL for the source CSV\n        \"url\": \"url_to_csv\",\n        // [optional] a file path or a glob pattern to local CSV file(s)\n        \"path\": \"path_to_csv\",\n        // [required] point coordinate columns\n        \"geometryColumns\": {\n          \"longitude\": \"longitude_column_name\",\n          \"latitude\": \"latitude_column_name\"\n        },\n        // [optional] ArcGIS service metadata\n        // See https://koopjs.github.io/docs/development/provider/model#adding-provider-metadata-to-the-geojson\n        \"metadata\": {\n          \"idField\": \"id_column_name\"\n        }\n      }\n    }\n  }\n}\n\n```\n\nSee `config/example-with-path.json` or `config/example-with-url.json` for full example configurations.\n\n## Development\n\n### Run dev server\n\n```bash\n$ npm start\n```\n\nA dev server will be running at `http://localhost:8080`. By default, it will use with `NODE_ENV=dev` and the dev configuration `config/dev.json` should be created beforehand.\n\n### Run tests\n\n```bash\n$ npm test\n```\n\n## License\n\nMIT\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkoopjs%2Fkoop-provider-csv","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fkoopjs%2Fkoop-provider-csv","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkoopjs%2Fkoop-provider-csv/lists"}