{"id":43575027,"url":"https://github.com/libremfg/rhize-data-collection-import","last_synced_at":"2026-02-03T23:00:47.156Z","repository":{"id":317397423,"uuid":"1064244607","full_name":"libremfg/rhize-data-collection-import","owner":"libremfg","description":null,"archived":false,"fork":false,"pushed_at":"2025-11-07T19:14:46.000Z","size":131,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2025-11-07T21:13:34.530Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/libremfg.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2025-09-25T18:46:08.000Z","updated_at":"2025-11-07T19:13:56.000Z","dependencies_parsed_at":"2025-09-30T17:38:17.769Z","dependency_job_id":"69513288-512e-4f8c-b0ff-b0d8612b1f08","html_url":"https://github.com/libremfg/rhize-data-collection-import","commit_stats":null,"previous_names":["libremfg/rhize-data-collection-import"],"tags_count":13,"template":false,"template_full_name":null,"purl":"pkg:github/libremfg/rhize-data-collection-import","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/libremfg%2Frhize-data-collection-import","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/libremfg%2Frhize-data-collection-import/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/libremfg%2Frhize-data-collection-import/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/libremfg%2Frhize-data-collection-import/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/libremfg","download_url":"https://codeload.github.com/libremfg/rhize-data-collection-import/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/libremfg%2Frhize-data-collection-import/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":29060624,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-02-03T22:28:58.191Z","status":"ssl_error","status_checked_at":"2026-02-03T22:28:56.515Z","response_time":96,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"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":[],"created_at":"2026-02-03T23:00:33.733Z","updated_at":"2026-02-03T23:00:47.146Z","avatar_url":"https://github.com/libremfg.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Rhize Data Collection Import Tool\n\nA command-line tool for importing data from Excel/CSV files into Rhize systems via the Libre backend.\n\n## Overview\n\nThis tool facilitates the import of equipment data and related information from spreadsheet files (Excel/CSV) into Rhize systems. It supports authentication with the Libre backend and can import data based on equipment class descriptions. Assumptions and considerations for the imported sheet and importer behavior can be viewed in the [documentation for drivers](adapters/drivers/README.md).\n\n## Features\n\n- Import data from Excel/CSV files\n- Authenticate with Libre backend\n- Support for equipment class descriptions\n- Configurable sheet selection\n- Flexible authentication options\n\n#### Usage\n\nFlags for the importer can be seen by using the `--help` flag. Default values show examples values.\n```shell\n$ ./rhize-import.exe --help\n2025/10/23 11:34:01 rhize-data-collection-import v1.6.1\nRhize Data Collection Import\n\nSimple utility to import data from a CSV or XLSX.\n\nUsage:\n   [flags]\n   [command]\n\nAvailable Commands:\n  completion     Generate the autocompletion script for the specified shell\n  equipment      Import equipment\n  equipmentClass Import Equipment Class from file\n  help           Help about any command\n  unitOfMeasure  Import UoMs from file\n\nFlags:\n  -A, --apiUrl string         URL for Rhize API (default \"http://localhost:8080/graphql\")\n  -a, --authUrl string        URL for Keycloak authentication (default \"http://localhost:8090\")\n  -b, --bypass                Bypass Keycloak authentication\n  -c, --clientId string       Client ID (default \"libreBaas\")\n  -s, --clientSecret string   Client Secret\n  -D, --datasource string     The DataSource to bind topics with\n  -f, --file string           Excel/CSV file to import data from\n  -h, --help                  help for this command\n  -p, --password string       Password for user/pass authentication\n  -r, --realm string          Keycloak Realm (default \"libre\")\n  -S, --sheet string          The Excel Sheet to search for data in\n  -u, --username string       Username for user/pass authentication\n\nUse \" [command] --help\" for more information about a command.\n```\n\n#### Example\nBelow is a command for importing Units of Measure from an Excel (XLSX) file \"data.xlsx\", a Sheet titled \"Oven_A\", and an otherwise default Rhize configuration. Configuration for authentication is read in from a `.env` file.\n\n```shell\n$ ./rhize-importer.exe unitOfMeasure \\\n  --file=\"./data.xlsx\" \\\n  --sheet=\"Oven_A\" \n2025/10/23 11:56:23 rhize-data-collection-import v1.6.1\n2025/10/23 11:56:23 Loading values from environment for unset flags\n2025/10/23 11:56:23 Log in Successfully\n2025/10/23 11:56:23 Reading data from provided file\n2025/10/23 11:56:23 Starting import for Units of Measure\n2025/10/23 11:56:24     Adding UoM for °C\n2025/10/23 11:56:24     Adding UoM for Amps\n2025/10/23 11:56:24     Adding UoM for psi\n2025/10/23 11:56:24 Finished import for Units of Measure\n```\n\nFor import Equipment a DataSource must also be defined. The example assumes a DataSource \"OPCUA\" is configured in Rhize.\n\n```shell\n$ ./rhize-importer.exe equipment \\\n  --file=\"./data.xlsx\" \\\n  --sheet=\"Oven_A\" \\\n  --datasource=\"OPCUA\"\n```\n\n### Command Line Arguments\n\n| Flag | Description | Default |\n|:------|:-------------|:---------|\n| `--apiUrl` | URL for Rhize API | `http://localhost:8080/graphql` |\n| `--authUrl` | URL for Keycloak Auth | `http://localhost:8090` |\n| `--bypass` | Enable/disable authentication | `false` |\n| `--clientId` | Client ID for authentication | `libreBaas` |\n| `--clientSecret` | Client secret for authentication | (optional) |\n| `--datasource` | The DataSource to bind topics with | (optional, required for Equipment) |\n| `--file` | Path to Excel/CSV file to import | (required) |\n| `--help` | help for this command | (optional) |\n| `--password` | Authentication password | (optional) |\n| `--realm` | Keycloak Realm | `libre` |\n| `--sheet` | Name of sheet to import data from | (optional, required for Excel) |\n| `--username` | Authentication username | (optional) |\n\n## Prerequisites\n\n- Go 1.24 or higher\n- Access to a Rhize backend system\n- Authentication credentials for the Rhize backend\n\n## Contributing\n\n1. Fork the repository\n2. Create a feature branch\n3. Commit your changes\n4. Push to the branch\n5. Create a Pull Request\n\n## License\n\nThis project is licensed under the MIT License - see the LICENSE file for details.\n\n## Change log\n- v1.9.0 J.W.\n  - Add support for Equipment Class Property descriptions.\n- v1.8.3 J.W.\n  - Change to remove all bindings on an Equipment before adding bindings from file\n- v1.8.2 J.W.\n  - Fix panic when no config file exists\n  - Fix repeated checks for skipped Units of Measure\n- v1.8.1 J.W.\n  - Change Units of Measure to upsert instead of failing if same Unit of Measure already exists\n- v1.8.0 J.W.\n  - Add support for including expressions with tag bindings, pulling from a dedicated column\n- v1.7.0 J.W.\n  - Add support for a configuration file to define how data types should be mapped to Rhize data types\n  - Change default data types to include \"Number\" as a Float\n  - Change to not add in Units of Measures with unknown data types\n  - Fix issue where an Equipment without a version would cause a nil pointer exception\n- v1.6.1 J.W.\n  - Change Equipment Class import to setup Properties as Default Type instead of Instance Type\n- v1.6.0 J.W.\n  - Change to allow user/pass authentication if both flags are set\n- v1.5.0 J.W.\n  - Change to use sub-commands for specifying target instead of `target` flag\n  - Change to authenticate with a client rather than client and user\n  - Remove `target` flag\n- v1.4.2 J.W.\n  - Add checks for Equipment Class and Datasource to Equipment model checks\n- v1.4.1 J.W.\n  - Change to require adding Datasources to Equipment manually\n  - Fix duplicate Datasources appearing on Equipment after binding\n- v1.4.0 J.W.\n  - Add flag `target` for specifying which resource to import data for\n  - Fix issue where bindings were not being added\n  - Fix issue where topic and binding checks were swapped\n- v1.3.0 J.W.\n  - Add Equipment binding setups from a given Datasource\n  - Add support for loading auth information from environment or .env\n- v1.2.1 T.H.\n  - Change error messages to pin-point where to check the import spreadsheet\n- v1.2.0 T.H.\n  - Change behaviour to create new draft version (or update current draft), Otherwise create a completely new Equipment Class\n- v1.1.0 T.H.\n  - Change properties to Class type from Instance\n  - Change properties without a datatype to Static from Bound\n- v1.0.0 J.W.\n  - Initial Release\n\n## Support\n\nFor support, please open an issue on the GitHub repository.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flibremfg%2Frhize-data-collection-import","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Flibremfg%2Frhize-data-collection-import","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flibremfg%2Frhize-data-collection-import/lists"}