{"id":13732946,"url":"https://github.com/iot-for-all/iotc-go","last_synced_at":"2025-05-08T09:31:15.074Z","repository":{"id":54408104,"uuid":"332903217","full_name":"iot-for-all/iotc-go","owner":"iot-for-all","description":"IoT Central CLI built in GO lang using public API","archived":true,"fork":false,"pushed_at":"2021-04-16T18:43:11.000Z","size":193,"stargazers_count":5,"open_issues_count":0,"forks_count":4,"subscribers_count":6,"default_branch":"main","last_synced_at":"2024-11-15T01:33:10.583Z","etag":null,"topics":["golang","iot","iot-central"],"latest_commit_sha":null,"homepage":"","language":"Go","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/iot-for-all.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":"2021-01-25T22:34:32.000Z","updated_at":"2023-06-17T01:34:14.000Z","dependencies_parsed_at":"2022-08-13T14:50:16.940Z","dependency_job_id":null,"html_url":"https://github.com/iot-for-all/iotc-go","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/iot-for-all%2Fiotc-go","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/iot-for-all%2Fiotc-go/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/iot-for-all%2Fiotc-go/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/iot-for-all%2Fiotc-go/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/iot-for-all","download_url":"https://codeload.github.com/iot-for-all/iotc-go/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":253036415,"owners_count":21844211,"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":["golang","iot","iot-central"],"created_at":"2024-08-03T03:00:35.828Z","updated_at":"2025-05-08T09:31:14.655Z","avatar_url":"https://github.com/iot-for-all.png","language":"Go","funding_links":[],"categories":["companion experiences"],"sub_categories":[],"readme":"# IoT Central CLI\n\nIoT Central CLI can be used to manage apps and migrate assets between apps.\nIt uses IoT Central public API using APP Tokens.\n\nThe source code in this tool can be use modified to meet appropriate needs. \n\n## Build\n\nFollow the instructions to [install Go](https://golang.org/doc/install). Pick the appropriate package to install the latest 1.15.x release of Go. This will give you access to the Go toolchain and compiler.\n\n- If you installed via the tarball, you will need to add a GOROOT environment variable pointing to the folder where you installed Go (typically /usr/local/go on linux-based systems)\n- You should also check to make sure that you can access the Go compiler and tools. They are available at $GOROOT/bin (or $GOROOT\\bin) and should be added to your path if they are not already. You can verify this by running the following:\n  - Max/Linux: which go\n  - Windows (CMD): where go\n\nTo build this tool, follow the instructions below:\n\n```\nTo build your repo (__YOUR_REPO__):\n$ cd __YOUR_REPO__/src\n$ make\n```\nYou can find the executable (iotc for linux or iotc.exe for windows) under __YOUR_REPO__/bin folder\n\nTo do a clean build i.e. remove all compiled binaries and dependencies:\n```\n$ cd __YOUR_REPO__/src\n$ make clean\n$ make\n``` \n\n## Configuration\nThis CLI uses a configuration file `$HOME/.iotc.yml`.\nThe format of the file is as follows:\n```\n# iotc configuration file\napps:\n    # name that is used in the iotc commands \n  - name: myapp1\n    # subdomain of the app. For https://app1.azureiotcentral.com, just enter app1\n    subdomain: app1\n    # domain of the app. Default is azureiotcentral.com\n    domain: azureiotcentral.com\n    # apitoken can be obtained from your IoT Central application Administration/API tokens\n    apiToken: api1Token\n  - name: myapp2\n    subdomain: app2\n    apiToken: api2Token\n  - name: myapp3\n    subdomain: app3\n    apiToken: api3Token\n\n# Maximum number of rows to retrieve for 'list' commands\nmaxRows: 25\n\n# Default format of the tables\nformat: pretty\n```\n\n## Usage\nOnce you add the configuration file mentioned above, you can run the tool using `__YOUR_REPO__/bin/iotc` command.\n```\nD:\\dev\\iotcgo\\bin\u003eiotc\n\n    ____    ______   ______           __             __\n   /  _/___/_  __/  / ____/__  ____  / /__________  / /\n   / // __ \\/ /    / /   / _ \\/ __ \\/ __/ ___/ __ \\/ /\n _/ // /_/ / /    / /___/  __/ / / / /_/ /  / /_/ / /\n/___/\\____/_/     \\____/\\___/_/ /_/\\__/_/   \\__,_/_/\n\nThis tool helps you manage IoT Central applications through simple CLI\ncommands. You can explore (list, upload, download) several entities such\nas devicesTemplates, roles, users in an IoT Central applications.\nYou can copy these entities between different apps. You an operate against\neach of these entities below using sub-commands underneath each command.\n\nUsage:\niotc [command]\n\nAvailable Commands:\nactions         Get the actions used in rules\napiTokens       Create, read, delete access tokens used to interact with the IoT Central public APIs\napps            Create, update and delete  IoT Central applications\ncde             Manage data exports within your IoT Central application\ncompletion      Generate command line completion script\ndeviceGroups    Operate against IoT Central device groups\ndeviceTemplates Create, read, and delete device templates within an IoT Central application\ndevices         Get information about and manage devices and IoT Edge modules in your IoT Central application.\nhelp            Help about any command\njobs            Operate against IoT Central jobs\nroles           List roles within your application\nrules           List rules within your application\nusers           Add, update, and remove users within your application\n\nFlags:\n--config string   Command config file (default is $HOME/.iotc.yml)\n-h, --help            help for iotc\n\nUse \"iotc [command] --help\" for more information about a command.\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fiot-for-all%2Fiotc-go","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fiot-for-all%2Fiotc-go","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fiot-for-all%2Fiotc-go/lists"}