c8y-cli Documentation

website·Indexed 30 days ago

https://goc8ycli.netlify.app/

Technical documentation and command reference for the c8y-cli, featuring a comprehensive set of PowerShell-style cmdlets for managing Cumulocity IoT resources. Includes detailed syntax and parameters for commands such as Get-ManagedObjectCollection, Find-DeviceServiceCollection, Get-ApplicationCollection, and Update-AlarmCollection to manage devices, measurements, applications, and managed objects.

Tokens
541.1K
Snippets
2.4K
Records
4.2K
Agent score
73%

What's inside c8y-cli

  1. Overview of Cumulocity CLI capabilities

    The Cumulocity CLI provides a set of tools for automating device management and alarm handling. Key features include:

    • Automation: Ability to write shell scripts for repetitive tasks.
    • Pipeline Support: Native support for chaining commands and piping data into third-party tools to create complex workflows.
    • Activity Logging: Automatic recording of API interactions for auditing and replaying requests to Cumulocity.
    • Concurrency Control: Support for concurrent workers to process large lists of devices or operations in parallel.
    • Configuration: Support for managing multiple sessions and customizing output views.
  2. Overview of the Cumulocity CLI (c8y)

    The Cumulocity command line interface (c8y) is a tool designed to interact with the Cumulocity REST API. It is primarily used for quick prototyping, exploring the REST API, and by platform maintainers or power users.
    # List devices
    $ c8y devices list
    
    # Filter devices by type and update a value
    $ c8y devices list --type "myDevice" | c8y devices update --data "myValue=1"
    
    # List operations for a specific device
    $ c8y operations list --device myDeviceName
  3. Overview of go-c8y-cli extensions

    Extensions allow users to customize go-c8y-cli to optimize workflows by providing custom commands and modifying how data is displayed. An extension is a git repository containing specific files and folders. By convention, public extensions start with the c8y- prefix, which is ignored during actual usage to simplify typing.

    Extension components include:

    • Aliases: Convenience commands defined in extension.yaml.
    • API Commands: Commands generated via YAML specifications in the api/ directory.
    • Script Commands: Complex logic written in languages like bash or python in the commands/ directory.
    • Templates: Custom templates stored in templates/ for use with the --template flag.
    • Views: View definitions in views/ that control which data fragments are displayed in the console.
    c8y-myext/
    │
    ├── extension.yaml
    │
    ├── api/
    │   ├── devices.yaml
    │   └── datapoints.yaml
    │
    ├── commands/
    │   ├── do-something
    │   └── mysubcmd/
    │       ├── list
    │       └── get
    │
    ├── templates/
    │   ├── devices.json
    │   └── applications.json
    │
    └── views/
        ├── devices.json
        └── applications.json
  4. Overview of Cloud Remote Access PASSTHROUGH

    The Cloud Remote Access feature allows secure ad-hoc TCP connections to devices (e.g., SSH, VNC, Telnet, or local webpages like Node-RED) without requiring local network access. The PASSTHROUGH mode routes bytes bi-directionally between a local client (using go-c8y-cli) and a device agent (such as thin-edge.io). It is intended for troubleshooting and root-cause analysis, not for 'always-on' connections or large-scale deployments like Ansible.
  5. Overview of the Cumulocity CLI (c8y)

    The Cumulocity command line interface (c8y) is a tool used to interact with the Cumulocity REST API. It is designed for quick prototyping, exploring the REST API, and for use by platform maintainers and power users.
    # List devices
    $ c8y devices list
    
    # Filter devices by type and update a value via piping
    $ c8y devices list --type "myDevice" | c8y devices update --data "myValue=1"
    
    # List operations for a specific device
    $ c8y operations list --device myDeviceName
  6. Overview of go-c8y-cli

    go-c8y-cli is a command-line interface (CLI) tool designed for interacting with the Cumulocity API. It is intended to increase developer productivity when managing an IoT Platform by simplifying API interactions and providing safeguards against common configuration or operational errors.
  7. Introduction to go-c8y-cli Extensions

    Extensions in go-c8y-cli allow users to customize workflows by providing custom commands to simplify repetitive tasks and modifying how data is displayed (e.g., adding custom columns to the device view to display specific managed object fragments). Extensions are supported from version 2.30.0 onwards. By default, extensions are accessible across all sessions, but they can be scoped to specific sessions or groups by changing the storage folder.
  8. Overview of Cumulocity CLI (c8y) capabilities

    The c8y CLI brings the Cumulocity API to the command line, allowing developers to manage devices (including alarms, events, measurements, and operations), manage users, deploy applications and microservices, create items from templates, and build workflows between commands.
  9. Overview of go-c8y-cli

    go-c8y-cli is a command-line interface (CLI) tool designed to interact with the Cumulocity API. It is intended to increase developer productivity when managing and interacting with the Cumulocity IoT Platform.
  10. Overview of go-c8y-cli Views

    Views are used to filter JSON responses, returning only the properties defined in the activated view. This behaves similarly to the select parameter by automatically applying a set of selected fields to the output. Views are not built into the go-c8y-cli binary but are provided via the go-c8y-cli-addons repository, allowing users to modify or add custom views without updating the CLI tool.
  11. Overview of go-c8y-cli

    go-c8y-cli is an open-source command-line tool developed in Golang used to interact with the Cumulocity API. It is designed to increase productivity for IoT platform management, allowing users to explore, fix, and create items in Cumulocity and automate processes via scripting. It is distributed as a single compiled binary across multiple platforms.
  12. Overview of go-c8y-cli

    go-c8y-cli is a command-line interface (CLI) tool designed for interacting with the Cumulocity API. It is intended to increase developer productivity when working with the Cumulocity IoT Platform by simplifying API interactions and providing safeguards against common configuration or operational errors.