Install any skill in seconds. Free to start, no credit card required.
Get Started Free →Azure Event Grid SDK for Python. Use for publishing events, handling CloudEvents, and event-driven architectures.
.claude/skills/azure-eventgrid-py/SKILL.md| Test case | Without → With | Effect | Δ tokens | Δ turns |
|---|---|---|---|---|
| case-04 | ✗→✓ | ▲ Improved | — | — |
| case-01 | ✗→✓ | ▲ Improved | — | — |
| case-07 | ✓→✓ | = Same ✓ | — | — |
| case-02 | ✓→✓ | = Same ✓ | — | — |
| case-18 | ✗→✗ | = Same ✗ | — | — |
Event routing service for building event-driven applications with pub/sub semantics.
bashpip install azure-eventgrid azure-identity
bashEVENTGRID_TOPIC_ENDPOINT=https://<topic-name>.<region>.eventgrid.azure.net/api/events EVENTGRID_NAMESPACE_ENDPOINT=https://<namespace>.<region>.eventgrid.azure.net
pythonfrom azure.identity import DefaultAzureCredential from azure.eventgrid import EventGridPublisherClient credential = DefaultAzureCredential() endpoint = "https://<topic-name>.<region>.eventgrid.azure.net/api/events" client = EventGridPublisherClient(endpoint, credential)
| Format | Class | Use Case | |--------|-------|----------| | Cloud Events 1.0 | CloudEvent | Standard, interoperable (recommended) | | Event Grid Schema | EventGridEvent | Azure-native format |
pythonfrom azure.eventgrid import EventGridPublisherClient, CloudEvent from azure.identity import DefaultAzureCredential client = EventGridPublisherClient(endpoint, DefaultAzureCredential()) # Single event event = CloudEvent( type="MyApp.Events.OrderCreated", source="/myapp/orders", data={"order_id": "12345", "amount": 99.99} ) client.send(event) # Multiple events events = [ CloudEvent( type="MyApp.Events.OrderCreated", source="/myapp/orders", data={"order_id": f"order-{i}"} ) for i in range(10) ] client.send(events)
pythonfrom azure.eventgrid import EventGridEvent from datetime import datetime, timezone event = EventGridEvent( subject="/myapp/orders/12345", event_type="MyApp.Events.OrderCreated", data={"order_id": "12345", "amount": 99.99}, data_version="1.0" ) client.send(event)
pythonevent = CloudEvent( type="MyApp.Events.ItemCreated", # Required: event type source="/myapp/items", # Required: event source data={"key": "value"}, # Event payload subject="items/123", # Optional: subject/path datacontenttype="application/json", # Optional: content type dataschema="https://schema.example", # Optional: schema URL time=datetime.now(timezone.utc), # Optional: timestamp extensions={"custom": "value"} # Optional: custom attributes )
pythonevent = EventGridEvent( subject="/myapp/items/123", # Required: subject event_type="MyApp.ItemCreated", # Required: event type data={"key": "value"}, # Required: event payload data_version="1.0", # Required: schema version topic="/subscriptions/.../topics/...", # Optional: auto-set event_time=datetime.now(timezone.utc) # Optional: timestamp )
pythonfrom azure.eventgrid.aio import EventGridPublisherClient from azure.identity.aio import DefaultAzureCredential async def publish_events(): credential = DefaultAzureCredential() async with EventGridPublisherClient(endpoint, credential) as client: event = CloudEvent( type="MyApp.Events.Test", source="/myapp", data={"message": "hello"} ) await client.send(event) import asyncio asyncio.run(publish_events())
For Event Grid Namespaces (pull delivery):
pythonfrom azure.eventgrid.aio import EventGridPublisherClient # Namespace endpoint (different from custom topic) namespace_endpoint = "https://<namespace>.<region>.eventgrid.azure.net" topic_name = "my-topic" async with EventGridPublisherClient( endpoint=namespace_endpoint, credential=DefaultAzureCredential() ) as client: await client.send( event, namespace_topic=topic_name )
This skill is applicable to execute the workflow or actions described in the overview.
| Case | Status | Duration (ms) | Turns | Tokens | Tool calls | ||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| Without | With | Δ | Without | With | Δ | Without | With | Δ | Without | With | Δ | ||
case-18 | fail→fail | — | — | — | — | — | — | — | — | — | — | — | — |
case-08 | fail→fail | — | — | — | — | — | — | — | — | — | — | — | — |
case-11 | fail→fail | — | — | — | — | — | — | — | — | — | — | — | — |
case-10 | fail→fail | — | — | — | — | — | — | — | — | — | — | — | — |
case-16 | fail→fail | — | — | — | — | — | — | — | — | — | — | — | — |
case-06 | fail→fail | — | — | — | — | — | — | — | — | — | — | — | — |
case-13 | fail→fail | — | — | — | — | — | — | — | — | — | — | — | — |
case-04 | fail→pass | — | — | — | — | — | — | — | — | — | — | — | — |
case-07 | pass→pass | — | — | — | — | — | — | — | — | — | — | — | — |
case-03 | fail→fail | — | — | — | — | — | — | — | — | — | — | — | — |
case-09 | fail→fail | — | — | — | — | — | — | — | — | — | — | — | — |
case-21 | fail→fail | — | — | — | — | — | — | — | — | — | — | — | — |
case-20 | fail→fail | — | — | — | — | — | — | — | — | — | — | — | — |
case-17 | fail→fail | — | — | — | — | — | — | — | — | — | — | — | — |
case-19 | fail→fail | — | — | — | — | — | — | — | — | — | — | — | — |
case-15 | fail→fail | — | — | — | — | — | — | — | — | — | — | — | — |
case-12 | fail→fail | — | — | — | — | — | — | — | — | — | — | — | — |
case-22 | fail→fail | — | — | — | — | — | — | — | — | — | — | — | — |
case-01 | fail→pass | — | — | — | — | — | — | — | — | — | — | — | — |
case-02 | pass→pass | — | — | — | — | — | — | — | — | — | — | — | — |
case-05 | fail→fail | — | — | — | — | — | — | — | — | — | — | — | — |
case-14 | fail→fail | — | — | — | — | — | — | — | — | — | — | — | — |
DecimalAI ran this skill against gemini-3.6-flash twice over the same eval suite — once with the skill loaded and once without — and compared the two runs case by case. 22 cases were attempted. The headline lift of +9 percentage points is the difference between those two pass rates over the 22 comparable cases.
The per-case answers from this run were removed by the retention sweep, so the case table below shows the verdicts without the text either arm produced. The counts above were recorded at the time and are unaffected. Answers are now kept for 180 days.
Other measured skills in the registry, with their headline benchmark lift.