diff --git a/src/content/docs/kv/platform/event-subscriptions.mdx b/src/content/docs/kv/platform/event-subscriptions.mdx new file mode 100644 index 00000000000000..28ae607e86d273 --- /dev/null +++ b/src/content/docs/kv/platform/event-subscriptions.mdx @@ -0,0 +1,17 @@ +--- +title: Event subscriptions +pcx_content_type: reference +sidebar: + order: 10 +head: + - tag: title + content: Event subscriptions +--- + +import { Render } from "~/components"; + + + +## Available KV events + + diff --git a/src/content/docs/queues/event-subscriptions/events-schemas.mdx b/src/content/docs/queues/event-subscriptions/events-schemas.mdx index bd932b413f3469..65913e8bdb155f 100644 --- a/src/content/docs/queues/event-subscriptions/events-schemas.mdx +++ b/src/content/docs/queues/event-subscriptions/events-schemas.mdx @@ -8,751 +8,39 @@ head: content: Events & schemas --- +import { Render } from "~/components"; + This page provides a comprehensive reference of available event sources and their corresponding events with schemas for [event subscriptions](/queues/event-subscriptions/). All events include common metadata fields and follow a consistent structure. ## Sources ### R2 -#### `bucket.created` - -Triggered when a bucket is created. - -**Example:** - -```json -{ - "type": "cf.r2.bucket.created", - "source": { - "type": "r2" - }, - "payload": { - "name": "my-bucket", - "jurisdiction": "default", - "location": "WNAM", - "storageClass": "Standard" - }, - "metadata": { - "accountId": "f9f79265f388666de8122cfb508d7776", - "eventSubscriptionId": "1830c4bb612e43c3af7f4cada31fbf3f", - "eventSchemaVersion": 1, - "eventTimestamp": "2025-05-01T02:48:57.132Z" - } -} -``` - -#### `bucket.deleted` - -Triggered when a bucket is deleted. - -**Example:** - -```json -{ - "type": "cf.r2.bucket.deleted", - "source": { - "type": "r2" - }, - "payload": { - "name": "my-bucket", - "jurisdiction": "default" - }, - "metadata": { - "accountId": "f9f79265f388666de8122cfb508d7776", - "eventSubscriptionId": "1830c4bb612e43c3af7f4cada31fbf3f", - "eventSchemaVersion": 1, - "eventTimestamp": "2025-05-01T02:48:57.132Z" - } -} -``` + ### Super Slurper -#### `job.started` - -Triggered when a migration job starts. - -**Example:** - -```json -{ - "type": "cf.superSlurper.job.started", - "source": { - "type": "superSlurper" - }, - "payload": { - "id": "job-12345678-90ab-cdef-1234-567890abcdef", - "createdAt": "2025-05-01T02:48:57.132Z", - "overwrite": true, - "pathPrefix": "migrations/", - "source": { - "provider": "s3", - "bucket": "source-bucket", - "region": "us-east-1", - "endpoint": "s3.amazonaws.com" - }, - "destination": { - "provider": "r2", - "bucket": "destination-bucket", - "jurisdiction": "default" - } - }, - "metadata": { - "accountId": "f9f79265f388666de8122cfb508d7776", - "eventSubscriptionId": "1830c4bb612e43c3af7f4cada31fbf3f", - "eventSchemaVersion": 1, - "eventTimestamp": "2025-05-01T02:48:57.132Z" - } -} -``` - -#### `job.paused` - -Triggered when a migration job pauses. - -**Example:** - -```json -{ - "type": "cf.superSlurper.job.paused", - "source": { - "type": "superSlurper" - }, - "payload": { - "id": "job-12345678-90ab-cdef-1234-567890abcdef" - }, - "metadata": { - "accountId": "f9f79265f388666de8122cfb508d7776", - "eventSubscriptionId": "1830c4bb612e43c3af7f4cada31fbf3f", - "eventSchemaVersion": 1, - "eventTimestamp": "2025-05-01T02:48:57.132Z" - } -} -``` - -#### `job.resumed` - -Triggered when a migration job resumes. - -**Example:** - -```json -{ - "type": "cf.superSlurper.job.resumed", - "source": { - "type": "superSlurper" - }, - "payload": { - "id": "job-12345678-90ab-cdef-1234-567890abcdef" - }, - "metadata": { - "accountId": "f9f79265f388666de8122cfb508d7776", - "eventSubscriptionId": "1830c4bb612e43c3af7f4cada31fbf3f", - "eventSchemaVersion": 1, - "eventTimestamp": "2025-05-01T02:48:57.132Z" - } -} -``` - -#### `job.completed` - -Triggered when a migration job finishes. - -**Example:** - -```json -{ - "type": "cf.superSlurper.job.completed", - "source": { - "type": "superSlurper" - }, - "payload": { - "id": "job-12345678-90ab-cdef-1234-567890abcdef", - "totalObjectsCount": 1000, - "skippedObjectsCount": 10, - "migratedObjectsCount": 980, - "failedObjectsCount": 10 - }, - "metadata": { - "accountId": "f9f79265f388666de8122cfb508d7776", - "eventSubscriptionId": "1830c4bb612e43c3af7f4cada31fbf3f", - "eventSchemaVersion": 1, - "eventTimestamp": "2025-05-01T02:48:57.132Z" - } -} -``` - -#### `job.aborted` - -Triggered when a migration job is manually aborted. - -**Example:** - -```json -{ - "type": "cf.superSlurper.job.aborted", - "source": { - "type": "superSlurper" - }, - "payload": { - "id": "job-12345678-90ab-cdef-1234-567890abcdef", - "totalObjectsCount": 1000, - "skippedObjectsCount": 100, - "migratedObjectsCount": 500, - "failedObjectsCount": 50 - }, - "metadata": { - "accountId": "f9f79265f388666de8122cfb508d7776", - "eventSubscriptionId": "1830c4bb612e43c3af7f4cada31fbf3f", - "eventSchemaVersion": 1, - "eventTimestamp": "2025-05-01T02:48:57.132Z" - } -} -``` - -**Example:** - -```json -{ - "type": "cf.superSlurper.job.object.migrated", - "source": { - "type": "superSlurper.job", - "jobId": "job-12345678-90ab-cdef-1234-567890abcdef" - }, - "payload": { - "key": "migrations/file.txt" - }, - "metadata": { - "accountId": "f9f79265f388666de8122cfb508d7776", - "eventSubscriptionId": "1830c4bb612e43c3af7f4cada31fbf3f", - "eventSchemaVersion": 1, - "eventTimestamp": "2025-05-01T02:48:57.132Z" - } -} -``` + ### Vectorize -#### `index.created` - -Triggered when an index is created. - -**Example:** - -```json -{ - "type": "cf.vectorize.index.created", - "source": { - "type": "vectorize" - }, - "payload": { - "name": "my-vector-index", - "description": "Index for embeddings", - "createdAt": "2025-05-01T02:48:57.132Z", - "modifiedAt": "2025-05-01T02:48:57.132Z", - "dimensions": 1536, - "metric": "cosine" - }, - "metadata": { - "accountId": "f9f79265f388666de8122cfb508d7776", - "eventSubscriptionId": "1830c4bb612e43c3af7f4cada31fbf3f", - "eventSchemaVersion": 1, - "eventTimestamp": "2025-05-01T02:48:57.132Z" - } -} -``` - -#### `index.deleted` - -Triggered when an index is deleted. - -**Example:** - -```json -{ - "type": "cf.vectorize.index.deleted", - "source": { - "type": "vectorize" - }, - "payload": { - "name": "my-vector-index" - }, - "metadata": { - "accountId": "f9f79265f388666de8122cfb508d7776", - "eventSubscriptionId": "1830c4bb612e43c3af7f4cada31fbf3f", - "eventSchemaVersion": 1, - "eventTimestamp": "2025-05-01T02:48:57.132Z" - } -} -``` + ### Workers AI -#### `batch.queued` - -Triggered when a batch request is queued. - -**Example:** - -```json -{ - "type": "cf.workersAi.model.batch.queued", - "source": { - "type": "workersAi.model", - "modelName": "@cf/baai/bge-base-en-v1.5" - }, - "payload": { - "requestId": "req-12345678-90ab-cdef-1234-567890abcdef" - }, - "metadata": { - "accountId": "f9f79265f388666de8122cfb508d7776", - "eventSubscriptionId": "1830c4bb612e43c3af7f4cada31fbf3f", - "eventSchemaVersion": 1, - "eventTimestamp": "2025-05-01T02:48:57.132Z" - } -} -``` - -#### `batch.succeeded` - -Triggered when a batch request has completed. - -**Example:** - -```json -{ - "type": "cf.workersAi.model.batch.succeeded", - "source": { - "type": "workersAi.model", - "modelName": "@cf/baai/bge-base-en-v1.5" - }, - "payload": { - "requestId": "req-12345678-90ab-cdef-1234-567890abcdef" - }, - "metadata": { - "accountId": "f9f79265f388666de8122cfb508d7776", - "eventSubscriptionId": "1830c4bb612e43c3af7f4cada31fbf3f", - "eventSchemaVersion": 1, - "eventTimestamp": "2025-05-01T02:48:57.132Z" - } -} -``` - -#### `batch.failed` - -Triggered when a batch request has failed. - -**Example:** - -```json -{ - "type": "cf.workersAi.model.batch.failed", - "source": { - "type": "workersAi.model", - "modelName": "@cf/baai/bge-base-en-v1.5" - }, - "payload": { - "requestId": "req-12345678-90ab-cdef-1234-567890abcdef", - "message": "Model execution failed", - "internalCode": 5001, - "httpCode": 500 - }, - "metadata": { - "accountId": "f9f79265f388666de8122cfb508d7776", - "eventSubscriptionId": "1830c4bb612e43c3af7f4cada31fbf3f", - "eventSchemaVersion": 1, - "eventTimestamp": "2025-05-01T02:48:57.132Z" - } -} -``` + ### Workers Builds -#### `build.started` - -Triggered when a build starts. - -**Example:** - -```json -{ - "type": "cf.workersBuilds.worker.build.started", - "source": { - "type": "workersBuilds.worker", - "workerName": "my-worker" - }, - "payload": { - "buildUuid": "build-12345678-90ab-cdef-1234-567890abcdef", - "status": "running", - "buildOutcome": null, - "createdAt": "2025-05-01T02:48:57.132Z", - "initializingAt": "2025-05-01T02:48:58.132Z", - "runningAt": "2025-05-01T02:48:59.132Z", - "stoppedAt": null, - "buildTriggerMetadata": { - "buildTriggerSource": "push_event", - "branch": "main", - "commitHash": "abc123def456", - "commitMessage": "Fix bug in authentication", - "author": "developer@example.com", - "buildCommand": "npm run build", - "deployCommand": "wrangler deploy", - "rootDirectory": "/", - "repoName": "my-worker-repo", - "providerAccountName": "github-user", - "providerType": "github" - } - }, - "metadata": { - "accountId": "f9f79265f388666de8122cfb508d7776", - "eventSubscriptionId": "1830c4bb612e43c3af7f4cada31fbf3f", - "eventSchemaVersion": 1, - "eventTimestamp": "2025-05-01T02:48:57.132Z" - } -} -``` - -#### `build.failed` - -Triggered when a build fails. - -**Example:** - -```json -{ - "type": "cf.workersBuilds.worker.build.failed", - "source": { - "type": "workersBuilds.worker", - "workerName": "my-worker" - }, - "payload": { - "buildUuid": "build-12345678-90ab-cdef-1234-567890abcdef", - "status": "failed", - "buildOutcome": "failure", - "createdAt": "2025-05-01T02:48:57.132Z", - "initializingAt": "2025-05-01T02:48:58.132Z", - "runningAt": "2025-05-01T02:48:59.132Z", - "stoppedAt": "2025-05-01T02:50:00.132Z", - "buildTriggerMetadata": { - "buildTriggerSource": "push_event", - "branch": "main", - "commitHash": "abc123def456", - "commitMessage": "Fix bug in authentication", - "author": "developer@example.com", - "buildCommand": "npm run build", - "deployCommand": "wrangler deploy", - "rootDirectory": "/", - "repoName": "my-worker-repo", - "providerAccountName": "github-user", - "providerType": "github" - } - }, - "metadata": { - "accountId": "f9f79265f388666de8122cfb508d7776", - "eventSubscriptionId": "1830c4bb612e43c3af7f4cada31fbf3f", - "eventSchemaVersion": 1, - "eventTimestamp": "2025-05-01T02:48:57.132Z" - } -} -``` - -#### `build.canceled` - -Triggered when a build is canceled. - -**Example:** - -```json -{ - "type": "cf.workersBuilds.worker.build.canceled", - "source": { - "type": "workersBuilds.worker", - "workerName": "my-worker" - }, - "payload": { - "buildUuid": "build-12345678-90ab-cdef-1234-567890abcdef", - "status": "canceled", - "buildOutcome": "canceled", - "createdAt": "2025-05-01T02:48:57.132Z", - "initializingAt": "2025-05-01T02:48:58.132Z", - "runningAt": "2025-05-01T02:48:59.132Z", - "stoppedAt": "2025-05-01T02:49:30.132Z", - "buildTriggerMetadata": { - "buildTriggerSource": "push_event", - "branch": "main", - "commitHash": "abc123def456", - "commitMessage": "Fix bug in authentication", - "author": "developer@example.com", - "buildCommand": "npm run build", - "deployCommand": "wrangler deploy", - "rootDirectory": "/", - "repoName": "my-worker-repo", - "providerAccountName": "github-user", - "providerType": "github" - } - }, - "metadata": { - "accountId": "f9f79265f388666de8122cfb508d7776", - "eventSubscriptionId": "1830c4bb612e43c3af7f4cada31fbf3f", - "eventSchemaVersion": 1, - "eventTimestamp": "2025-05-01T02:48:57.132Z" - } -} -``` - -#### `build.succeeded` - -Triggered when a build succeeds. - -**Example:** - -```json -{ - "type": "cf.workersBuilds.worker.build.succeeded", - "source": { - "type": "workersBuilds.worker", - "workerName": "my-worker" - }, - "payload": { - "buildUuid": "build-12345678-90ab-cdef-1234-567890abcdef", - "status": "success", - "buildOutcome": "success", - "createdAt": "2025-05-01T02:48:57.132Z", - "initializingAt": "2025-05-01T02:48:58.132Z", - "runningAt": "2025-05-01T02:48:59.132Z", - "stoppedAt": "2025-05-01T02:50:15.132Z", - "buildTriggerMetadata": { - "buildTriggerSource": "push_event", - "branch": "main", - "commitHash": "abc123def456", - "commitMessage": "Fix bug in authentication", - "author": "developer@example.com", - "buildCommand": "npm run build", - "deployCommand": "wrangler deploy", - "rootDirectory": "/", - "repoName": "my-worker-repo", - "providerAccountName": "github-user", - "providerType": "github" - } - }, - "metadata": { - "accountId": "f9f79265f388666de8122cfb508d7776", - "eventSubscriptionId": "1830c4bb612e43c3af7f4cada31fbf3f", - "eventSchemaVersion": 1, - "eventTimestamp": "2025-05-01T02:48:57.132Z" - } -} -``` + ### Workers KV -#### `namespace.created` - -Triggered when a namespace is created. - -**Example:** - -```json -{ - "type": "cf.kv.namespace.created", - "source": { - "type": "kv" - }, - "payload": { - "id": "ns-12345678-90ab-cdef-1234-567890abcdef", - "name": "my-kv-namespace" - }, - "metadata": { - "accountId": "f9f79265f388666de8122cfb508d7776", - "eventSubscriptionId": "1830c4bb612e43c3af7f4cada31fbf3f", - "eventSchemaVersion": 1, - "eventTimestamp": "2025-05-01T02:48:57.132Z" - } -} -``` - -#### `namespace.deleted` - -Triggered when a namespace is deleted. - -**Example:** - -```json -{ - "type": "cf.kv.namespace.deleted", - "source": { - "type": "kv" - }, - "payload": { - "id": "ns-12345678-90ab-cdef-1234-567890abcdef", - "name": "my-kv-namespace" - }, - "metadata": { - "accountId": "f9f79265f388666de8122cfb508d7776", - "eventSubscriptionId": "1830c4bb612e43c3af7f4cada31fbf3f", - "eventSchemaVersion": 1, - "eventTimestamp": "2025-05-01T02:48:57.132Z" - } -} -``` + ### Workflows -#### `instance.queued` - -Triggered when an instance was created and is awaiting execution. - -**Example:** - -```json -{ - "type": "cf.workflows.workflow.instance.queued", - "source": { - "type": "workflows.workflow", - "workflowName": "my-workflow" - }, - "payload": { - "versionId": "v1", - "instanceId": "inst-12345678-90ab-cdef-1234-567890abcdef" - }, - "metadata": { - "accountId": "f9f79265f388666de8122cfb508d7776", - "eventSubscriptionId": "1830c4bb612e43c3af7f4cada31fbf3f", - "eventSchemaVersion": 1, - "eventTimestamp": "2025-05-01T02:48:57.132Z" - } -} -``` - -#### `instance.started` - -Triggered when an instance starts or resumes execution. - -**Example:** - -```json -{ - "type": "cf.workflows.workflow.instance.started", - "source": { - "type": "workflows.workflow", - "workflowName": "my-workflow" - }, - "payload": { - "versionId": "v1", - "instanceId": "inst-12345678-90ab-cdef-1234-567890abcdef" - }, - "metadata": { - "accountId": "f9f79265f388666de8122cfb508d7776", - "eventSubscriptionId": "1830c4bb612e43c3af7f4cada31fbf3f", - "eventSchemaVersion": 1, - "eventTimestamp": "2025-05-01T02:48:57.132Z" - } -} -``` - -#### `instance.paused` - -Triggered when an instance pauses execution. - -**Example:** - -```json -{ - "type": "cf.workflows.workflow.instance.paused", - "source": { - "type": "workflows.workflow", - "workflowName": "my-workflow" - }, - "payload": { - "versionId": "v1", - "instanceId": "inst-12345678-90ab-cdef-1234-567890abcdef" - }, - "metadata": { - "accountId": "f9f79265f388666de8122cfb508d7776", - "eventSubscriptionId": "1830c4bb612e43c3af7f4cada31fbf3f", - "eventSchemaVersion": 1, - "eventTimestamp": "2025-05-01T02:48:57.132Z" - } -} -``` - -#### `instance.errored` - -Triggered when an instance step throws an error. - -**Example:** - -```json -{ - "type": "cf.workflows.workflow.instance.errored", - "source": { - "type": "workflows.workflow", - "workflowName": "my-workflow" - }, - "payload": { - "versionId": "v1", - "instanceId": "inst-12345678-90ab-cdef-1234-567890abcdef" - }, - "metadata": { - "accountId": "f9f79265f388666de8122cfb508d7776", - "eventSubscriptionId": "1830c4bb612e43c3af7f4cada31fbf3f", - "eventSchemaVersion": 1, - "eventTimestamp": "2025-05-01T02:48:57.132Z" - } -} -``` - -#### `instance.terminated` - -Triggered when an instance is manually terminated. - -**Example:** - -```json -{ - "type": "cf.workflows.workflow.instance.terminated", - "source": { - "type": "workflows.workflow", - "workflowName": "my-workflow" - }, - "payload": { - "versionId": "v1", - "instanceId": "inst-12345678-90ab-cdef-1234-567890abcdef" - }, - "metadata": { - "accountId": "f9f79265f388666de8122cfb508d7776", - "eventSubscriptionId": "1830c4bb612e43c3af7f4cada31fbf3f", - "eventSchemaVersion": 1, - "eventTimestamp": "2025-05-01T02:48:57.132Z" - } -} -``` - -#### `instance.completed` - -Triggered when an instance finishes execution successfully. - -**Example:** - -```json -{ - "type": "cf.workflows.workflow.instance.completed", - "source": { - "type": "workflows.workflow", - "workflowName": "my-workflow" - }, - "payload": { - "versionId": "v1", - "instanceId": "inst-12345678-90ab-cdef-1234-567890abcdef" - }, - "metadata": { - "accountId": "f9f79265f388666de8122cfb508d7776", - "eventSubscriptionId": "1830c4bb612e43c3af7f4cada31fbf3f", - "eventSchemaVersion": 1, - "eventTimestamp": "2025-05-01T02:48:57.132Z" - } -} -``` + ## Common schema fields @@ -766,4 +54,4 @@ All events include these common fields: | `metadata.eventSubscriptionId` | string | The subscription that triggered this event | | `metadata.eventSchemaVersion` | number | The version of the event schema | | `metadata.eventTimestamp` | string | The ISO 8601 timestamp when the event occurred | -| `payload` | object | The event-specific data containing details about what happened | \ No newline at end of file +| `payload` | object | The event-specific data containing details about what happened | diff --git a/src/content/docs/r2/platform/event-subscriptions.mdx b/src/content/docs/r2/platform/event-subscriptions.mdx new file mode 100644 index 00000000000000..a87d2ad627e391 --- /dev/null +++ b/src/content/docs/r2/platform/event-subscriptions.mdx @@ -0,0 +1,21 @@ +--- +title: Event subscriptions +pcx_content_type: reference +sidebar: + order: 10 +head: + - tag: title + content: Event subscriptions +--- + +import { Render } from "~/components"; + + + +## Available R2 events + + + +## Available Super Slurper events + + diff --git a/src/content/docs/vectorize/platform/event-subscriptions.mdx b/src/content/docs/vectorize/platform/event-subscriptions.mdx new file mode 100644 index 00000000000000..13a67b4620769e --- /dev/null +++ b/src/content/docs/vectorize/platform/event-subscriptions.mdx @@ -0,0 +1,17 @@ +--- +title: Event subscriptions +pcx_content_type: reference +sidebar: + order: 10 +head: + - tag: title + content: Event subscriptions +--- + +import { Render } from "~/components"; + + + +## Available Vectorize events + + diff --git a/src/content/docs/workers-ai/platform/event-subscriptions.mdx b/src/content/docs/workers-ai/platform/event-subscriptions.mdx new file mode 100644 index 00000000000000..8503bc9bcebf0b --- /dev/null +++ b/src/content/docs/workers-ai/platform/event-subscriptions.mdx @@ -0,0 +1,17 @@ +--- +title: Event subscriptions +pcx_content_type: reference +sidebar: + order: 10 +head: + - tag: title + content: Event subscriptions +--- + +import { Render } from "~/components"; + + + +## Available Workers AI events + + diff --git a/src/content/docs/workers/ci-cd/builds/event-subscriptions.mdx b/src/content/docs/workers/ci-cd/builds/event-subscriptions.mdx new file mode 100644 index 00000000000000..2c5ef017a840e6 --- /dev/null +++ b/src/content/docs/workers/ci-cd/builds/event-subscriptions.mdx @@ -0,0 +1,17 @@ +--- +title: Event subscriptions +pcx_content_type: reference +sidebar: + order: 10 +head: + - tag: title + content: Event subscriptions +--- + +import { Render } from "~/components"; + + + +## Available Workers Builds events + + diff --git a/src/content/docs/workflows/reference/event-subscriptions.mdx b/src/content/docs/workflows/reference/event-subscriptions.mdx new file mode 100644 index 00000000000000..b0749031aaac09 --- /dev/null +++ b/src/content/docs/workflows/reference/event-subscriptions.mdx @@ -0,0 +1,17 @@ +--- +title: Event subscriptions +pcx_content_type: reference +sidebar: + order: 10 +head: + - tag: title + content: Event subscriptions +--- + +import { Render } from "~/components"; + + + +## Available Workflows events + + diff --git a/src/content/partials/queues/event-subscriptions/intro.mdx b/src/content/partials/queues/event-subscriptions/intro.mdx new file mode 100644 index 00000000000000..b55dcc4f7e0476 --- /dev/null +++ b/src/content/partials/queues/event-subscriptions/intro.mdx @@ -0,0 +1,3 @@ +[Event subscriptions](/queues/event-subscriptions/) allow you to receive messages when events occur across your Cloudflare account. Cloudflare products (e.g., [KV](/kv/), [Workers AI](/workers-ai/), [Workers](/workers/)) can publish structured events to a [queue](/queues/), which you can then consume with Workers or [HTTP pull consumers](/queues/configuration/pull-consumers/) to build custom workflows, integrations, or logic. + +For more information on [Event Subscriptions](/queues/event-subscriptions/), refer to the [management guide](/queues/event-subscriptions/manage-event-subscriptions/). diff --git a/src/content/partials/queues/event-subscriptions/kv-events.mdx b/src/content/partials/queues/event-subscriptions/kv-events.mdx new file mode 100644 index 00000000000000..41f5c1399c2dda --- /dev/null +++ b/src/content/partials/queues/event-subscriptions/kv-events.mdx @@ -0,0 +1,49 @@ +#### `namespace.created` + +Triggered when a namespace is created. + +**Example:** + +```json +{ + "type": "cf.kv.namespace.created", + "source": { + "type": "kv" + }, + "payload": { + "id": "ns-12345678-90ab-cdef-1234-567890abcdef", + "name": "my-kv-namespace" + }, + "metadata": { + "accountId": "f9f79265f388666de8122cfb508d7776", + "eventSubscriptionId": "1830c4bb612e43c3af7f4cada31fbf3f", + "eventSchemaVersion": 1, + "eventTimestamp": "2025-05-01T02:48:57.132Z" + } +} +``` + +#### `namespace.deleted` + +Triggered when a namespace is deleted. + +**Example:** + +```json +{ + "type": "cf.kv.namespace.deleted", + "source": { + "type": "kv" + }, + "payload": { + "id": "ns-12345678-90ab-cdef-1234-567890abcdef", + "name": "my-kv-namespace" + }, + "metadata": { + "accountId": "f9f79265f388666de8122cfb508d7776", + "eventSubscriptionId": "1830c4bb612e43c3af7f4cada31fbf3f", + "eventSchemaVersion": 1, + "eventTimestamp": "2025-05-01T02:48:57.132Z" + } +} +``` diff --git a/src/content/partials/queues/event-subscriptions/r2-events.mdx b/src/content/partials/queues/event-subscriptions/r2-events.mdx new file mode 100644 index 00000000000000..b50d8c3a1c19d4 --- /dev/null +++ b/src/content/partials/queues/event-subscriptions/r2-events.mdx @@ -0,0 +1,51 @@ +#### `bucket.created` + +Triggered when a bucket is created. + +**Example:** + +```json +{ + "type": "cf.r2.bucket.created", + "source": { + "type": "r2" + }, + "payload": { + "name": "my-bucket", + "jurisdiction": "default", + "location": "WNAM", + "storageClass": "Standard" + }, + "metadata": { + "accountId": "f9f79265f388666de8122cfb508d7776", + "eventSubscriptionId": "1830c4bb612e43c3af7f4cada31fbf3f", + "eventSchemaVersion": 1, + "eventTimestamp": "2025-05-01T02:48:57.132Z" + } +} +``` + +#### `bucket.deleted` + +Triggered when a bucket is deleted. + +**Example:** + +```json +{ + "type": "cf.r2.bucket.deleted", + "source": { + "type": "r2" + }, + "payload": { + "name": "my-bucket", + "jurisdiction": "default" + }, + "metadata": { + "accountId": "f9f79265f388666de8122cfb508d7776", + "eventSubscriptionId": "1830c4bb612e43c3af7f4cada31fbf3f", + "eventSchemaVersion": 1, + "eventTimestamp": "2025-05-01T02:48:57.132Z" + } +} +``` diff --git a/src/content/partials/queues/event-subscriptions/super-slurper-events.mdx b/src/content/partials/queues/event-subscriptions/super-slurper-events.mdx new file mode 100644 index 00000000000000..4cae246e7055fa --- /dev/null +++ b/src/content/partials/queues/event-subscriptions/super-slurper-events.mdx @@ -0,0 +1,166 @@ +#### `job.started` + +Triggered when a migration job starts. + +**Example:** + +```json +{ + "type": "cf.superSlurper.job.started", + "source": { + "type": "superSlurper" + }, + "payload": { + "id": "job-12345678-90ab-cdef-1234-567890abcdef", + "createdAt": "2025-05-01T02:48:57.132Z", + "overwrite": true, + "pathPrefix": "migrations/", + "source": { + "provider": "s3", + "bucket": "source-bucket", + "region": "us-east-1", + "endpoint": "s3.amazonaws.com" + }, + "destination": { + "provider": "r2", + "bucket": "destination-bucket", + "jurisdiction": "default" + } + }, + "metadata": { + "accountId": "f9f79265f388666de8122cfb508d7776", + "eventSubscriptionId": "1830c4bb612e43c3af7f4cada31fbf3f", + "eventSchemaVersion": 1, + "eventTimestamp": "2025-05-01T02:48:57.132Z" + } +} +``` + +#### `job.paused` + +Triggered when a migration job pauses. + +**Example:** + +```json +{ + "type": "cf.superSlurper.job.paused", + "source": { + "type": "superSlurper" + }, + "payload": { + "id": "job-12345678-90ab-cdef-1234-567890abcdef" + }, + "metadata": { + "accountId": "f9f79265f388666de8122cfb508d7776", + "eventSubscriptionId": "1830c4bb612e43c3af7f4cada31fbf3f", + "eventSchemaVersion": 1, + "eventTimestamp": "2025-05-01T02:48:57.132Z" + } +} +``` + +#### `job.resumed` + +Triggered when a migration job resumes. + +**Example:** + +```json +{ + "type": "cf.superSlurper.job.resumed", + "source": { + "type": "superSlurper" + }, + "payload": { + "id": "job-12345678-90ab-cdef-1234-567890abcdef" + }, + "metadata": { + "accountId": "f9f79265f388666de8122cfb508d7776", + "eventSubscriptionId": "1830c4bb612e43c3af7f4cada31fbf3f", + "eventSchemaVersion": 1, + "eventTimestamp": "2025-05-01T02:48:57.132Z" + } +} +``` + +#### `job.completed` + +Triggered when a migration job finishes. + +**Example:** + +```json +{ + "type": "cf.superSlurper.job.completed", + "source": { + "type": "superSlurper" + }, + "payload": { + "id": "job-12345678-90ab-cdef-1234-567890abcdef", + "totalObjectsCount": 1000, + "skippedObjectsCount": 10, + "migratedObjectsCount": 980, + "failedObjectsCount": 10 + }, + "metadata": { + "accountId": "f9f79265f388666de8122cfb508d7776", + "eventSubscriptionId": "1830c4bb612e43c3af7f4cada31fbf3f", + "eventSchemaVersion": 1, + "eventTimestamp": "2025-05-01T02:48:57.132Z" + } +} +``` + +#### `job.aborted` + +Triggered when a migration job is manually aborted. + +**Example:** + +```json +{ + "type": "cf.superSlurper.job.aborted", + "source": { + "type": "superSlurper" + }, + "payload": { + "id": "job-12345678-90ab-cdef-1234-567890abcdef", + "totalObjectsCount": 1000, + "skippedObjectsCount": 100, + "migratedObjectsCount": 500, + "failedObjectsCount": 50 + }, + "metadata": { + "accountId": "f9f79265f388666de8122cfb508d7776", + "eventSubscriptionId": "1830c4bb612e43c3af7f4cada31fbf3f", + "eventSchemaVersion": 1, + "eventTimestamp": "2025-05-01T02:48:57.132Z" + } +} +``` + +#### `job.object.migrated` + +Triggered when an object is migrated. + +**Example:** + +```json +{ + "type": "cf.superSlurper.job.object.migrated", + "source": { + "type": "superSlurper.job", + "jobId": "job-12345678-90ab-cdef-1234-567890abcdef" + }, + "payload": { + "key": "migrations/file.txt" + }, + "metadata": { + "accountId": "f9f79265f388666de8122cfb508d7776", + "eventSubscriptionId": "1830c4bb612e43c3af7f4cada31fbf3f", + "eventSchemaVersion": 1, + "eventTimestamp": "2025-05-01T02:48:57.132Z" + } +} +``` diff --git a/src/content/partials/queues/event-subscriptions/vectorize-events.mdx b/src/content/partials/queues/event-subscriptions/vectorize-events.mdx new file mode 100644 index 00000000000000..fbdfca03358751 --- /dev/null +++ b/src/content/partials/queues/event-subscriptions/vectorize-events.mdx @@ -0,0 +1,52 @@ +#### `index.created` + +Triggered when an index is created. + +**Example:** + +```json +{ + "type": "cf.vectorize.index.created", + "source": { + "type": "vectorize" + }, + "payload": { + "name": "my-vector-index", + "description": "Index for embeddings", + "createdAt": "2025-05-01T02:48:57.132Z", + "modifiedAt": "2025-05-01T02:48:57.132Z", + "dimensions": 1536, + "metric": "cosine" + }, + "metadata": { + "accountId": "f9f79265f388666de8122cfb508d7776", + "eventSubscriptionId": "1830c4bb612e43c3af7f4cada31fbf3f", + "eventSchemaVersion": 1, + "eventTimestamp": "2025-05-01T02:48:57.132Z" + } +} +``` + +#### `index.deleted` + +Triggered when an index is deleted. + +**Example:** + +```json +{ + "type": "cf.vectorize.index.deleted", + "source": { + "type": "vectorize" + }, + "payload": { + "name": "my-vector-index" + }, + "metadata": { + "accountId": "f9f79265f388666de8122cfb508d7776", + "eventSubscriptionId": "1830c4bb612e43c3af7f4cada31fbf3f", + "eventSchemaVersion": 1, + "eventTimestamp": "2025-05-01T02:48:57.132Z" + } +} +``` diff --git a/src/content/partials/queues/event-subscriptions/workers-ai-events.mdx b/src/content/partials/queues/event-subscriptions/workers-ai-events.mdx new file mode 100644 index 00000000000000..0353629c8d3549 --- /dev/null +++ b/src/content/partials/queues/event-subscriptions/workers-ai-events.mdx @@ -0,0 +1,77 @@ +#### `batch.queued` + +Triggered when a batch request is queued. + +**Example:** + +```json +{ + "type": "cf.workersAi.model.batch.queued", + "source": { + "type": "workersAi.model", + "modelName": "@cf/baai/bge-base-en-v1.5" + }, + "payload": { + "requestId": "req-12345678-90ab-cdef-1234-567890abcdef" + }, + "metadata": { + "accountId": "f9f79265f388666de8122cfb508d7776", + "eventSubscriptionId": "1830c4bb612e43c3af7f4cada31fbf3f", + "eventSchemaVersion": 1, + "eventTimestamp": "2025-05-01T02:48:57.132Z" + } +} +``` + +#### `batch.succeeded` + +Triggered when a batch request has completed. + +**Example:** + +```json +{ + "type": "cf.workersAi.model.batch.succeeded", + "source": { + "type": "workersAi.model", + "modelName": "@cf/baai/bge-base-en-v1.5" + }, + "payload": { + "requestId": "req-12345678-90ab-cdef-1234-567890abcdef" + }, + "metadata": { + "accountId": "f9f79265f388666de8122cfb508d7776", + "eventSubscriptionId": "1830c4bb612e43c3af7f4cada31fbf3f", + "eventSchemaVersion": 1, + "eventTimestamp": "2025-05-01T02:48:57.132Z" + } +} +``` + +#### `batch.failed` + +Triggered when a batch request has failed. + +**Example:** + +```json +{ + "type": "cf.workersAi.model.batch.failed", + "source": { + "type": "workersAi.model", + "modelName": "@cf/baai/bge-base-en-v1.5" + }, + "payload": { + "requestId": "req-12345678-90ab-cdef-1234-567890abcdef", + "message": "Model execution failed", + "internalCode": 5001, + "httpCode": 500 + }, + "metadata": { + "accountId": "f9f79265f388666de8122cfb508d7776", + "eventSubscriptionId": "1830c4bb612e43c3af7f4cada31fbf3f", + "eventSchemaVersion": 1, + "eventTimestamp": "2025-05-01T02:48:57.132Z" + } +} +``` diff --git a/src/content/partials/queues/event-subscriptions/workers-builds-events.mdx b/src/content/partials/queues/event-subscriptions/workers-builds-events.mdx new file mode 100644 index 00000000000000..5a30ffa8866513 --- /dev/null +++ b/src/content/partials/queues/event-subscriptions/workers-builds-events.mdx @@ -0,0 +1,175 @@ +#### `build.started` + +Triggered when a build starts. + +**Example:** + +```json +{ + "type": "cf.workersBuilds.worker.build.started", + "source": { + "type": "workersBuilds.worker", + "workerName": "my-worker" + }, + "payload": { + "buildUuid": "build-12345678-90ab-cdef-1234-567890abcdef", + "status": "running", + "buildOutcome": null, + "createdAt": "2025-05-01T02:48:57.132Z", + "initializingAt": "2025-05-01T02:48:58.132Z", + "runningAt": "2025-05-01T02:48:59.132Z", + "stoppedAt": null, + "buildTriggerMetadata": { + "buildTriggerSource": "push_event", + "branch": "main", + "commitHash": "abc123def456", + "commitMessage": "Fix bug in authentication", + "author": "developer@example.com", + "buildCommand": "npm run build", + "deployCommand": "wrangler deploy", + "rootDirectory": "/", + "repoName": "my-worker-repo", + "providerAccountName": "github-user", + "providerType": "github" + } + }, + "metadata": { + "accountId": "f9f79265f388666de8122cfb508d7776", + "eventSubscriptionId": "1830c4bb612e43c3af7f4cada31fbf3f", + "eventSchemaVersion": 1, + "eventTimestamp": "2025-05-01T02:48:57.132Z" + } +} +``` + +#### `build.failed` + +Triggered when a build fails. + +**Example:** + +```json +{ + "type": "cf.workersBuilds.worker.build.failed", + "source": { + "type": "workersBuilds.worker", + "workerName": "my-worker" + }, + "payload": { + "buildUuid": "build-12345678-90ab-cdef-1234-567890abcdef", + "status": "failed", + "buildOutcome": "failure", + "createdAt": "2025-05-01T02:48:57.132Z", + "initializingAt": "2025-05-01T02:48:58.132Z", + "runningAt": "2025-05-01T02:48:59.132Z", + "stoppedAt": "2025-05-01T02:50:00.132Z", + "buildTriggerMetadata": { + "buildTriggerSource": "push_event", + "branch": "main", + "commitHash": "abc123def456", + "commitMessage": "Fix bug in authentication", + "author": "developer@example.com", + "buildCommand": "npm run build", + "deployCommand": "wrangler deploy", + "rootDirectory": "/", + "repoName": "my-worker-repo", + "providerAccountName": "github-user", + "providerType": "github" + } + }, + "metadata": { + "accountId": "f9f79265f388666de8122cfb508d7776", + "eventSubscriptionId": "1830c4bb612e43c3af7f4cada31fbf3f", + "eventSchemaVersion": 1, + "eventTimestamp": "2025-05-01T02:48:57.132Z" + } +} +``` + +#### `build.canceled` + +Triggered when a build is canceled. + +**Example:** + +```json +{ + "type": "cf.workersBuilds.worker.build.canceled", + "source": { + "type": "workersBuilds.worker", + "workerName": "my-worker" + }, + "payload": { + "buildUuid": "build-12345678-90ab-cdef-1234-567890abcdef", + "status": "canceled", + "buildOutcome": "canceled", + "createdAt": "2025-05-01T02:48:57.132Z", + "initializingAt": "2025-05-01T02:48:58.132Z", + "runningAt": "2025-05-01T02:48:59.132Z", + "stoppedAt": "2025-05-01T02:49:30.132Z", + "buildTriggerMetadata": { + "buildTriggerSource": "push_event", + "branch": "main", + "commitHash": "abc123def456", + "commitMessage": "Fix bug in authentication", + "author": "developer@example.com", + "buildCommand": "npm run build", + "deployCommand": "wrangler deploy", + "rootDirectory": "/", + "repoName": "my-worker-repo", + "providerAccountName": "github-user", + "providerType": "github" + } + }, + "metadata": { + "accountId": "f9f79265f388666de8122cfb508d7776", + "eventSubscriptionId": "1830c4bb612e43c3af7f4cada31fbf3f", + "eventSchemaVersion": 1, + "eventTimestamp": "2025-05-01T02:48:57.132Z" + } +} +``` + +#### `build.succeeded` + +Triggered when a build succeeds. + +**Example:** + +```json +{ + "type": "cf.workersBuilds.worker.build.succeeded", + "source": { + "type": "workersBuilds.worker", + "workerName": "my-worker" + }, + "payload": { + "buildUuid": "build-12345678-90ab-cdef-1234-567890abcdef", + "status": "success", + "buildOutcome": "success", + "createdAt": "2025-05-01T02:48:57.132Z", + "initializingAt": "2025-05-01T02:48:58.132Z", + "runningAt": "2025-05-01T02:48:59.132Z", + "stoppedAt": "2025-05-01T02:50:15.132Z", + "buildTriggerMetadata": { + "buildTriggerSource": "push_event", + "branch": "main", + "commitHash": "abc123def456", + "commitMessage": "Fix bug in authentication", + "author": "developer@example.com", + "buildCommand": "npm run build", + "deployCommand": "wrangler deploy", + "rootDirectory": "/", + "repoName": "my-worker-repo", + "providerAccountName": "github-user", + "providerType": "github" + } + }, + "metadata": { + "accountId": "f9f79265f388666de8122cfb508d7776", + "eventSubscriptionId": "1830c4bb612e43c3af7f4cada31fbf3f", + "eventSchemaVersion": 1, + "eventTimestamp": "2025-05-01T02:48:57.132Z" + } +} +``` diff --git a/src/content/partials/queues/event-subscriptions/workflows-events.mdx b/src/content/partials/queues/event-subscriptions/workflows-events.mdx new file mode 100644 index 00000000000000..3df38e1c77de3c --- /dev/null +++ b/src/content/partials/queues/event-subscriptions/workflows-events.mdx @@ -0,0 +1,155 @@ +#### `instance.queued` + +Triggered when an instance was created and is awaiting execution. + +**Example:** + +```json +{ + "type": "cf.workflows.workflow.instance.queued", + "source": { + "type": "workflows.workflow", + "workflowName": "my-workflow" + }, + "payload": { + "versionId": "v1", + "instanceId": "inst-12345678-90ab-cdef-1234-567890abcdef" + }, + "metadata": { + "accountId": "f9f79265f388666de8122cfb508d7776", + "eventSubscriptionId": "1830c4bb612e43c3af7f4cada31fbf3f", + "eventSchemaVersion": 1, + "eventTimestamp": "2025-05-01T02:48:57.132Z" + } +} +``` + +#### `instance.started` + +Triggered when an instance starts or resumes execution. + +**Example:** + +```json +{ + "type": "cf.workflows.workflow.instance.started", + "source": { + "type": "workflows.workflow", + "workflowName": "my-workflow" + }, + "payload": { + "versionId": "v1", + "instanceId": "inst-12345678-90ab-cdef-1234-567890abcdef" + }, + "metadata": { + "accountId": "f9f79265f388666de8122cfb508d7776", + "eventSubscriptionId": "1830c4bb612e43c3af7f4cada31fbf3f", + "eventSchemaVersion": 1, + "eventTimestamp": "2025-05-01T02:48:57.132Z" + } +} +``` + +#### `instance.paused` + +Triggered when an instance pauses execution. + +**Example:** + +```json +{ + "type": "cf.workflows.workflow.instance.paused", + "source": { + "type": "workflows.workflow", + "workflowName": "my-workflow" + }, + "payload": { + "versionId": "v1", + "instanceId": "inst-12345678-90ab-cdef-1234-567890abcdef" + }, + "metadata": { + "accountId": "f9f79265f388666de8122cfb508d7776", + "eventSubscriptionId": "1830c4bb612e43c3af7f4cada31fbf3f", + "eventSchemaVersion": 1, + "eventTimestamp": "2025-05-01T02:48:57.132Z" + } +} +``` + +#### `instance.errored` + +Triggered when an instance step throws an error. + +**Example:** + +```json +{ + "type": "cf.workflows.workflow.instance.errored", + "source": { + "type": "workflows.workflow", + "workflowName": "my-workflow" + }, + "payload": { + "versionId": "v1", + "instanceId": "inst-12345678-90ab-cdef-1234-567890abcdef" + }, + "metadata": { + "accountId": "f9f79265f388666de8122cfb508d7776", + "eventSubscriptionId": "1830c4bb612e43c3af7f4cada31fbf3f", + "eventSchemaVersion": 1, + "eventTimestamp": "2025-05-01T02:48:57.132Z" + } +} +``` + +#### `instance.terminated` + +Triggered when an instance is manually terminated. + +**Example:** + +```json +{ + "type": "cf.workflows.workflow.instance.terminated", + "source": { + "type": "workflows.workflow", + "workflowName": "my-workflow" + }, + "payload": { + "versionId": "v1", + "instanceId": "inst-12345678-90ab-cdef-1234-567890abcdef" + }, + "metadata": { + "accountId": "f9f79265f388666de8122cfb508d7776", + "eventSubscriptionId": "1830c4bb612e43c3af7f4cada31fbf3f", + "eventSchemaVersion": 1, + "eventTimestamp": "2025-05-01T02:48:57.132Z" + } +} +``` + +#### `instance.completed` + +Triggered when an instance finishes execution successfully. + +**Example:** + +```json +{ + "type": "cf.workflows.workflow.instance.completed", + "source": { + "type": "workflows.workflow", + "workflowName": "my-workflow" + }, + "payload": { + "versionId": "v1", + "instanceId": "inst-12345678-90ab-cdef-1234-567890abcdef" + }, + "metadata": { + "accountId": "f9f79265f388666de8122cfb508d7776", + "eventSubscriptionId": "1830c4bb612e43c3af7f4cada31fbf3f", + "eventSchemaVersion": 1, + "eventTimestamp": "2025-05-01T02:48:57.132Z" + } +} +```