Skip to content

Channel Commands

The doover channel command group provides tools for managing Doover channels, including creating channels, publishing messages, managing processors and tasks, and handling subscriptions.

Available Commands

CommandDescription
getGet channel information
createCreate a new channel
publishPublish a message to a channel
publish-filePublish a file to a processor channel
followFollow channel updates in real-time
create-processorCreate a processor channel
publish-processorPublish a processor package
create-taskCreate a task channel
invoke-local-taskInvoke a task locally
subscribeAdd a subscription to a task
unsubscribeRemove a subscription from a task

Getting Channel Information

The doover channel get command retrieves information about a channel.

Usage

doover channel get <CHANNEL_NAME> [OPTIONS]

Options

OptionDescriptionDefault
--profileConfiguration profile to usedefault
--agentAgent ID for the channel lookupFrom profile

Example

# Get channel by name
doover channel get my-sensor-data

# Get channel with specific agent
doover channel get my-sensor-data --agent abc123

# Get channel using different profile
doover channel get my-sensor-data --profile production

The command first tries to look up the channel by ID, then falls back to looking up by name within the specified agent.

Creating Channels

The doover channel create command creates a new channel.

Usage

doover channel create <CHANNEL_NAME> [OPTIONS]

Options

OptionDescriptionDefault
--profileConfiguration profile to usedefault
--agentAgent ID to own the channelFrom profile

Example

# Create a new channel
doover channel create temperature-readings

# Create channel for specific agent
doover channel create temperature-readings --agent abc123

Output:

Channel created successfully. ID: ch_xyz789
Channel Name: temperature-readings
Owner Agent: abc123
...

Publishing Messages

Publishing Data

The doover channel publish command publishes a message to a channel.

Usage

doover channel publish <CHANNEL_NAME> <MESSAGE> [OPTIONS]

Arguments

ArgumentDescription
CHANNEL_NAMEName of the channel to publish to
MESSAGEMessage content (string or JSON)

Example

# Publish a simple string message
doover channel publish my-channel "Hello, world!"

# Publish JSON data
doover channel publish sensor-data '{"temperature": 23.5, "humidity": 65}'

# Publish with specific profile
doover channel publish sensor-data '{"value": 42}' --profile production

If the message is valid JSON, it will be parsed and sent as a structured object.

Publishing Files

The doover channel publish-file command publishes a file to a processor channel.

Usage

doover channel publish-file <CHANNEL_NAME> <FILE_PATH> [OPTIONS]

Example

# Publish a configuration file
doover channel publish-file config-channel ./config.json

# Publish a data file
doover channel publish-file data-channel ./sensor-export.csv

Following Channels

The doover channel follow command subscribes to a channel and displays updates in real-time.

Usage

doover channel follow <CHANNEL_NAME> [POLL_RATE] [OPTIONS]

Arguments

ArgumentDescriptionDefault
CHANNEL_NAMEChannel to follow(required)
POLL_RATESeconds between checks5

Example

# Follow a channel with default poll rate
doover channel follow sensor-data

# Follow with faster updates
doover channel follow sensor-data 2

# Follow with 10-second intervals
doover channel follow sensor-data 10

The command displays channel information, then continuously polls for aggregate changes and prints updates.

Press Ctrl+C to stop following.

Processor Channels

Processors are special channels that contain executable code for data processing.

Creating a Processor

doover channel create-processor <PROCESSOR_NAME> [OPTIONS]

Example

# Create a processor channel
doover channel create-processor >data-aggregator

# The > prefix is automatically added if not present
doover channel create-processor data-aggregator

Output:

Processor created successfully. ID: proc_abc123
...

Publishing a Processor Package

The doover channel publish-processor command uploads a processor package to a processor channel.

Usage

doover channel publish-processor <PROCESSOR_NAME> <PACKAGE_PATH> [OPTIONS]

Example

# Publish a processor package
doover channel publish-processor >data-aggregator ./my-processor/

# The package path should be a directory containing the processor code
doover channel publish-processor >my-processor ./processors/my-processor/

Task Channels

Tasks are channels that trigger processor execution based on subscriptions.

Creating a Task

doover channel create-task <TASK_NAME> <PROCESSOR_NAME> [OPTIONS]

Arguments

ArgumentDescription
TASK_NAMEName for the task channel (automatically prefixed with @)
PROCESSOR_NAMEProcessor channel to trigger (automatically prefixed with >)

Example

# Create a task that triggers a processor
doover channel create-task daily-aggregation data-aggregator

# With explicit prefixes
doover channel create-task @daily-aggregation >data-aggregator

Output:

Task created successfully. ID: task_def456
...

Invoking a Task Locally

The doover channel invoke-local-task command runs a task on your local machine for testing.

Usage

doover channel invoke-local-task <TASK_NAME> --package-path <PATH> [OPTIONS]

Options

OptionDescriptionDefault
--package-pathPath to the processor package(required)
CHANNEL_NAMEChannel to get the last message fromNone
--csv-fileCSV export of messages to processNone
--parallel-processesNumber of parallel workersNone
--dry-runRun without invoking the taskFalse

Examples

# Invoke task with a single message from a channel
doover channel invoke-local-task @my-task --package-path ./processor/ sensor-data

# Invoke task without a message
doover channel invoke-local-task @my-task --package-path ./processor/

# Process messages from a CSV export
doover channel invoke-local-task @my-task --package-path ./processor/ --csv-file ./messages.csv

# Dry run to test setup
doover channel invoke-local-task @my-task --package-path ./processor/ --dry-run

# Process CSV with parallel workers
doover channel invoke-local-task @my-task --package-path ./processor/ --csv-file ./messages.csv --parallel-processes 4

Subscriptions

Tasks can subscribe to channels, triggering the task's processor when the channel receives a message.

Adding a Subscription

doover channel subscribe <TASK_NAME> <CHANNEL_NAME> [OPTIONS]

Example

# Subscribe a task to a channel
doover channel subscribe @daily-aggregation sensor-data

Output:

Successfully added sensor-data to @daily-aggregation's subscriptions.

Removing a Subscription

doover channel unsubscribe <TASK_NAME> <CHANNEL_NAME> [OPTIONS]

Example

# Remove a subscription
doover channel unsubscribe @daily-aggregation sensor-data

Output:

Successfully removed sensor-data from @daily-aggregation's subscriptions.

Channel Naming Conventions

Doover uses prefixes to distinguish channel types:

PrefixTypeExample
(none)Regular channelsensor-data
>Processor channel>data-aggregator
@Task channel@daily-aggregation

The CLI automatically adds the appropriate prefix when needed, so you can use either:

# These are equivalent
doover channel create-task daily-aggregation data-aggregator
doover channel create-task @daily-aggregation >data-aggregator

Error Handling

Common errors and their meanings:

ErrorCauseSolution
"Channel not found"Channel does not exist or wrong agentVerify channel name and agent ID
"Is it owned by this agent?"Channel belongs to different agentUse --agent to specify correct agent
"That wasn't a task channel"Used task command on non-task channelVerify channel type and name prefix
"Channel name is not a processor"Used processor command on non-processorVerify channel type and name prefix

Workflow Example

A typical workflow for setting up data processing:

# 1. Create a processor channel
doover channel create-processor >my-processor

# 2. Publish processor code
doover channel publish-processor >my-processor ./my-processor-package/

# 3. Create a task that uses the processor
doover channel create-task @process-data >my-processor

# 4. Create a data channel
doover channel create sensor-readings

# 5. Subscribe the task to the data channel
doover channel subscribe @process-data sensor-readings

# 6. Test locally before deployment
doover channel invoke-local-task @process-data --package-path ./my-processor-package/ sensor-readings --dry-run

# 7. Publish some data
doover channel publish sensor-readings '{"value": 42}'

# 8. Follow the channel for updates
doover channel follow sensor-readings