skills/azure-eventhub-rust/SKILL.md
Azure Event Hubs SDK for Rust. Use for sending and receiving events, streaming data ingestion.
npx skillsauth add Regtransfers/agency-agents-mcp azure-eventhub-rustInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
@ Azure Event Hubs SDK for Rust
Client library for Azure Event Hubs — big data streaming platform and event ingestion service.
@ Installation
cargo add azure_messaging_eventhubs azure_identity
@ Environment Variables
EVENTHUBS_HOST=<namespace>.servicebus.windows.net
EVENTHUB_NAME=<eventhub-name>
@ Key Concepts
@ Producer Client
@ Create Producer
use azure_identity::DeveloperToolsCredential;
use azure_messaging_eventhubs::ProducerClient;
let credential = DeveloperToolsCredential::new(None)?;
let producer = ProducerClient::builder()
.open("<namespace>.servicebus.windows.net", "eventhub-name", credential.clone())
.await?;
@ Send Single Event
producer.send_event(vec![1, 2, 3, 4], None).await?;
@ Send Batch
let batch = producer.create_batch(None).await?;
batch.try_add_event_data(b"event 1".to_vec(), None)?;
batch.try_add_event_data(b"event 2".to_vec(), None)?;
producer.send_batch(batch, None).await?;
@ Consumer Client
@ Create Consumer
use azure_messaging_eventhubs::ConsumerClient;
let credential = DeveloperToolsCredential::new(None)?;
let consumer = ConsumerClient::builder()
.open("<namespace>.servicebus.windows.net", "eventhub-name", credential.clone())
.await?;
@ Receive Events
// Open receiver for specific partition
let receiver = consumer.open_partition_receiver("0", None).await?;
// Receive events
let events = receiver.receive_events(100, None).await?;
for event in events {
println!("Event data: {:?}", event.body());
}
@ Get Event Hub Properties
let properties = consumer.get_eventhub_properties(None).await?;
println!("Partitions: {:?}", properties.partition_ids);
@ Get Partition Properties
let partition_props = consumer.get_partition_properties("0", None).await?;
println!("Last sequence number: {}", partition_props.last_enqueued_sequence_number);
@ Best Practices
@ Checkpoint Store (Optional)
For distributed consumers with checkpointing:
cargo add azure_messaging_eventhubs_checkpointstore_blob
@ Reference Links
Resource; Link
API Reference; https://docs.rs/azuremessagingeventhubs Source Code; https://github.com/Azure/azure-sdk-for-rust/tree/main/sdk/eventhubs/azuremessagingeventhubs crates.io; https://crates.io/crates/azuremessagingeventhubs
@ When to Use This skill is applicable to execute the workflow or actions described in the overview.
@ Limitations
tools
Build AI agents that interact with computers like humans do - viewing screens, moving cursors, clicking buttons, and typing text. Covers Anthropic's Computer Use, OpenAI's Operator/CUA, and open-source alternatives.
testing
Generate structured PR descriptions from diffs, add review checklists, risk assessments, and test coverage summaries. Use when the user says "write a PR description", "improve this PR", "summarize my changes", "PR review", "pull request", or asks to document a diff for reviewers.
tools
Use when working with comprehensive review full review
development
You are an expert in creating competitor comparison and alternative pages. Your goal is to build pages that rank for competitive search terms, provide genuine value to evaluators, and position your product effectively.