oraclecloud-webhooks-events

Wire up event-driven workflows with OCI Events, Notifications, and Functions. Use when building serverless event processing, subscribing to instance lifecycle changes, or routing audit events to alerting systems. Trigger with "oraclecloud webhooks events", "oci events rules", "oci notifications", "oci ons topics".

1,868 stars

Best use case

oraclecloud-webhooks-events is best used when you need a repeatable AI agent workflow instead of a one-off prompt.

Wire up event-driven workflows with OCI Events, Notifications, and Functions. Use when building serverless event processing, subscribing to instance lifecycle changes, or routing audit events to alerting systems. Trigger with "oraclecloud webhooks events", "oci events rules", "oci notifications", "oci ons topics".

Teams using oraclecloud-webhooks-events should expect a more consistent output, faster repeated execution, less prompt rewriting.

When to use this skill

  • You want a reusable workflow that can be run more than once with consistent structure.

When not to use this skill

  • You only need a quick one-off answer and do not need a reusable workflow.
  • You cannot install or maintain the underlying files, dependencies, or repository context.

Installation

Claude Code / Cursor / Codex

$curl -o ~/.claude/skills/oraclecloud-webhooks-events/SKILL.md --create-dirs "https://raw.githubusercontent.com/jeremylongshore/claude-code-plugins-plus-skills/main/plugins/saas-packs/oraclecloud-pack/skills/oraclecloud-webhooks-events/SKILL.md"

Manual Installation

  1. Download SKILL.md from GitHub
  2. Place it in .claude/skills/oraclecloud-webhooks-events/SKILL.md inside your project
  3. Restart your AI agent — it will auto-discover the skill

How oraclecloud-webhooks-events Compares

Feature / Agentoraclecloud-webhooks-eventsStandard Approach
Platform SupportNot specifiedLimited / Varies
Context Awareness High Baseline
Installation ComplexityUnknownN/A

Frequently Asked Questions

What does this skill do?

Wire up event-driven workflows with OCI Events, Notifications, and Functions. Use when building serverless event processing, subscribing to instance lifecycle changes, or routing audit events to alerting systems. Trigger with "oraclecloud webhooks events", "oci events rules", "oci notifications", "oci ons topics".

Where can I find the source code?

You can find the source code on GitHub using the link provided at the top of the page.

Related Guides

SKILL.md Source

# Oracle Cloud Webhooks & Events

## Overview

Build event-driven workflows using the OCI Events service, Oracle Notification Service (ONS), and OCI Functions. OCI Events monitors resource state changes across your tenancy and fires rules that route events to ONS topics, streaming, or Functions. This skill covers event rule creation, ONS topic/subscription setup, event pattern matching syntax, and Functions integration.

**Purpose:** Create reliable event-driven pipelines that react to OCI resource changes in real time.

## Prerequisites

- **OCI Python SDK** — `pip install oci`
- **OCI config file** at `~/.oci/config` with valid credentials (user, fingerprint, tenancy, region, key_file)
- **IAM policies** granting access to Events, ONS, and Functions:
  - `Allow group EventAdmins to manage cloudevents-rules in compartment <name>`
  - `Allow group EventAdmins to manage ons-topics in compartment <name>`
  - `Allow group EventAdmins to use fn-function in compartment <name>`
- **Compartment OCID** for the target compartment
- Python 3.8+

## Instructions

### Step 1: Create an ONS Topic and Subscription

Create a notification topic that will receive events, then subscribe an endpoint (email, HTTPS, PagerDuty, or Slack via HTTPS):

```python
import oci

config = oci.config.from_file("~/.oci/config")
ons_control = oci.ons.NotificationControlPlaneClient(config)
ons_data = oci.ons.NotificationDataPlaneClient(config)

# Create a topic
topic_response = ons_control.create_topic(
    oci.ons.models.CreateTopicDetails(
        name="infra-alerts",
        compartment_id="ocid1.compartment.oc1..example",
        description="Infrastructure lifecycle alerts"
    )
)
topic_id = topic_response.data.topic_id
print(f"Topic created: {topic_id}")

# Subscribe an HTTPS endpoint (e.g., Slack incoming webhook)
subscription = ons_data.create_subscription(
    oci.ons.models.CreateSubscriptionDetails(
        topic_id=topic_id,
        compartment_id="ocid1.compartment.oc1..example",
        protocol="HTTPS",
        endpoint="https://hooks.slack.com/services/YOUR/SLACK/WEBHOOK"
    )
)
print(f"Subscription: {subscription.data.id} ({subscription.data.lifecycle_state})")
```

### Step 2: Create an Events Rule

Events rules use a condition block that matches on `eventType`, `compartmentId`, and optional `attribute` filters. The condition syntax is JSON, not HCL:

```python
events_client = oci.events.EventsClient(config)

rule = events_client.create_rule(
    oci.events.models.CreateRuleDetails(
        display_name="instance-state-changes",
        compartment_id="ocid1.compartment.oc1..example",
        description="Fire on compute instance lifecycle changes",
        is_enabled=True,
        condition='{"eventType":["com.oraclecloud.computeapi.launchinstance.end","com.oraclecloud.computeapi.terminateinstance.end","com.oraclecloud.computeapi.instanceaction.end"]}',
        actions=oci.events.models.ActionDetailsList(
            actions=[
                oci.events.models.ActionDetails(
                    action_type="ONS",
                    topic_id=topic_id,
                    is_enabled=True,
                    description="Notify infra-alerts topic"
                )
            ]
        )
    )
)
print(f"Rule created: {rule.data.id}")
```

### Step 3: Common Event Types Reference

Use these exact `eventType` strings in your rule conditions:

| Category | Event Type | Fires When |
|----------|-----------|------------|
| Compute | `com.oraclecloud.computeapi.launchinstance.end` | Instance launch completes |
| Compute | `com.oraclecloud.computeapi.terminateinstance.end` | Instance terminated |
| Compute | `com.oraclecloud.computeapi.instanceaction.end` | Stop/start/reboot finishes |
| Storage | `com.oraclecloud.objectstorage.createbucket` | New bucket created |
| Storage | `com.oraclecloud.objectstorage.deleteobject` | Object deleted |
| Identity | `com.oraclecloud.identitycontrolplane.createuser` | New user created |
| Identity | `com.oraclecloud.identitycontrolplane.updatepolicy` | IAM policy modified |
| Audit | `com.oraclecloud.audit.event` | Any auditable action |

### Step 4: Route Events to a Function

For complex processing, route events to an OCI Function instead of (or in addition to) ONS:

```python
# Create a rule that invokes a Function
fn_rule = events_client.create_rule(
    oci.events.models.CreateRuleDetails(
        display_name="bucket-change-processor",
        compartment_id="ocid1.compartment.oc1..example",
        is_enabled=True,
        condition='{"eventType":["com.oraclecloud.objectstorage.createobject","com.oraclecloud.objectstorage.deleteobject"]}',
        actions=oci.events.models.ActionDetailsList(
            actions=[
                oci.events.models.ActionDetails(
                    action_type="FAAS",
                    function_id="ocid1.fnfunc.oc1.iad.example",
                    is_enabled=True,
                    description="Process bucket changes"
                )
            ]
        )
    )
)
```

### Step 5: Verify the Pipeline

List active rules and test by triggering an event:

```bash
# List event rules via CLI
oci events rule list --compartment-id ocid1.compartment.oc1..example --all

# Check ONS subscription confirmation status
oci ons subscription list --compartment-id ocid1.compartment.oc1..example --topic-id <topic-ocid>
```

## Output

Successful completion produces:
- An ONS topic with at least one confirmed subscription (email, HTTPS, or PagerDuty)
- One or more Events rules with condition filters matching target event types
- Verified event delivery — triggering a matched action (e.g., stopping an instance) delivers a notification to the subscribed endpoint

## Error Handling

| Error | Code | Cause | Solution |
|-------|------|-------|----------|
| NotAuthenticated | 401 | Bad config or API key | Verify `~/.oci/config` credentials and key_file path |
| NotAuthorizedOrNotFound | 404 | Missing IAM policy or wrong OCID | Add `manage cloudevents-rules` / `manage ons-topics` policies |
| TooManyRequests | 429 | Rate limited (no Retry-After header) | Back off exponentially; see `oraclecloud-rate-limits` |
| InvalidParameter | 400 | Malformed condition JSON in rule | Validate JSON syntax — condition must be valid JSON, not HCL |
| TopicLimitReached | 400 | ONS topic limit (max 100 per compartment) | Delete unused topics or request a limit increase |
| InternalError | 500 | OCI service error | Retry after 30 seconds; check https://ocistatus.oraclecloud.com |
| SubscriptionPending | — | HTTPS endpoint did not confirm | Check endpoint logs — OCI sends a confirmation POST that must return 200 |

## Examples

**Quick event rule via CLI:**

```bash
# Create a rule that fires on all audit events in a compartment
oci events rule create \
  --compartment-id ocid1.compartment.oc1..example \
  --display-name "audit-all" \
  --is-enabled true \
  --condition '{"eventType":["com.oraclecloud.audit.event"]}' \
  --actions '{"actions":[{"actionType":"ONS","topicId":"ocid1.onstopic.oc1.iad.example","isEnabled":true}]}'
```

**List all event types available:**

```python
import oci

config = oci.config.from_file("~/.oci/config")
events_client = oci.events.EventsClient(config)

# Event types are documented — no list API exists.
# Reference: https://docs.oracle.com/en-us/iaas/Content/Events/Reference/eventsproducers.htm
```

## Resources

- [OCI Events Service](https://docs.oracle.com/en-us/iaas/Content/Events/Concepts/eventsoverview.htm) — event rules and conditions
- [OCI Notification Service (ONS)](https://docs.oracle.com/en-us/iaas/Content/Notification/Concepts/notificationoverview.htm) — topics and subscriptions
- [Event Types Reference](https://docs.oracle.com/en-us/iaas/Content/Events/Reference/eventsproducers.htm) — all available event types
- [Python SDK Reference](https://docs.oracle.com/en-us/iaas/tools/python/latest/) — EventsClient, NotificationDataPlaneClient
- [OCI Status](https://ocistatus.oraclecloud.com) — service health dashboard

## Next Steps

After event pipelines are running, see `oraclecloud-observability` for monitoring event delivery metrics, or `oraclecloud-rate-limits` for handling 429 errors in high-volume event processing.

Related Skills

workhuman-webhooks-events

1868
from jeremylongshore/claude-code-plugins-plus-skills

Workhuman webhooks events for employee recognition and rewards API. Use when integrating Workhuman Social Recognition, or building recognition workflows with HRIS systems. Trigger: "workhuman webhooks events".

wispr-webhooks-events

1868
from jeremylongshore/claude-code-plugins-plus-skills

Wispr Flow webhooks events for voice-to-text API integration. Use when integrating Wispr Flow dictation, WebSocket streaming, or building voice-powered applications. Trigger: "wispr webhooks events".

windsurf-webhooks-events

1868
from jeremylongshore/claude-code-plugins-plus-skills

Build Windsurf extensions and integrate with VS Code extension API events. Use when building custom Windsurf extensions, tracking editor events, or integrating Windsurf with external tools via extension development. Trigger with phrases like "windsurf extension", "windsurf events", "windsurf plugin", "build windsurf extension", "windsurf API".

webflow-webhooks-events

1868
from jeremylongshore/claude-code-plugins-plus-skills

Implement Webflow webhook registration, signature verification, and event handling for form_submission, site_publish, ecomm_new_order, page_created, and more. Use when setting up webhook endpoints, implementing event-driven workflows, or handling Webflow notifications. Trigger with phrases like "webflow webhook", "webflow events", "webflow webhook signature", "handle webflow events", "webflow notifications".

vercel-webhooks-events

1868
from jeremylongshore/claude-code-plugins-plus-skills

Implement Vercel webhook handling with signature verification and event processing. Use when setting up webhook endpoints, processing deployment events, or building integrations that react to Vercel deployment lifecycle. Trigger with phrases like "vercel webhook", "vercel events", "vercel deployment.ready", "handle vercel events", "vercel webhook signature".

veeva-webhooks-events

1868
from jeremylongshore/claude-code-plugins-plus-skills

Veeva Vault webhooks events for REST API and clinical operations. Use when working with Veeva Vault document management and CRM. Trigger: "veeva webhooks events".

vastai-webhooks-events

1868
from jeremylongshore/claude-code-plugins-plus-skills

Build event-driven workflows around Vast.ai instance lifecycle events. Use when monitoring instance status changes, implementing auto-recovery, or building event-driven GPU orchestration. Trigger with phrases like "vastai events", "vastai instance monitoring", "vastai status changes", "vastai lifecycle events".

twinmind-webhooks-events

1868
from jeremylongshore/claude-code-plugins-plus-skills

Handle TwinMind meeting events including transcription completion, action item extraction, and calendar sync notifications. Use when implementing webhooks events, or managing TwinMind meeting AI operations. Trigger with phrases like "twinmind webhooks events", "twinmind webhooks events".

together-webhooks-events

1868
from jeremylongshore/claude-code-plugins-plus-skills

Together AI webhooks events for inference, fine-tuning, and model deployment. Use when working with Together AI's OpenAI-compatible API. Trigger: "together webhooks events".

techsmith-webhooks-events

1868
from jeremylongshore/claude-code-plugins-plus-skills

TechSmith webhooks events for Snagit COM API and Camtasia automation. Use when working with TechSmith screen capture and video editing automation. Trigger: "techsmith webhooks events".

supabase-webhooks-events

1868
from jeremylongshore/claude-code-plugins-plus-skills

Implement Supabase database webhooks, pg_net async HTTP, LISTEN/NOTIFY, and Edge Function event handlers with signature verification. Use when setting up database webhooks for INSERT/UPDATE/DELETE events, sending HTTP requests from PostgreSQL triggers, handling Realtime postgres_changes as an event source, or building event-driven architectures. Trigger with phrases like "supabase webhook", "database events", "pg_net trigger", "supabase LISTEN NOTIFY", "webhook signature verify", "supabase event-driven", "supabase_functions.http_request".

stackblitz-webhooks-events

1868
from jeremylongshore/claude-code-plugins-plus-skills

WebContainer lifecycle events: server-ready, port changes, error handling. Use when working with WebContainers or StackBlitz SDK. Trigger: "webcontainer events".