---
sidebar:
  hidden: true
title: roboto.domain.platform_events.events
---
## Module Contents

### CLOUDEVENTS_SPECVERSION

```python
roboto.domain.platform_events.events.CLOUDEVENTS_SPECVERSION = '1.0'
```

`from roboto.domain.platform_events import CLOUDEVENTS_SPECVERSION`

[Source](https://github.com/roboto-ai/roboto-python-sdk/blob/main/src/roboto/domain/platform_events/events.py#L22-L22)

The CloudEvents spec version [`PlatformEvent.to_cloudevent()`](/reference/python-sdk/roboto/domain/platform_events/events#roboto.domain.platform_events.events.PlatformEvent.to_cloudevent) produces.

### CLOUDEVENTS_TYPE_PREFIX

```python
roboto.domain.platform_events.events.CLOUDEVENTS_TYPE_PREFIX = 'ai.roboto.'
```

`from roboto.domain.platform_events import CLOUDEVENTS_TYPE_PREFIX`

[Source](https://github.com/roboto-ai/roboto-python-sdk/blob/main/src/roboto/domain/platform_events/events.py#L25-L25)

Reverse-DNS prefix CloudEvents recommends on `type`. It appears only in what [`PlatformEvent.to_cloudevent()`](/reference/python-sdk/roboto/domain/platform_events/events#roboto.domain.platform_events.events.PlatformEvent.to_cloudevent) returns; subscriptions, conditions, and templates name an event by its bare [`PlatformEventType`](/reference/python-sdk/roboto/domain/platform_events/events#roboto.domain.platform_events.events.PlatformEventType) value (`file.uploaded`).

### DatasetCreatedPayload

```python
class roboto.domain.platform_events.events.DatasetCreatedPayload(/, **data: Any)
```

`from roboto.domain.platform_events import DatasetCreatedPayload`

[Source](https://github.com/roboto-ai/roboto-python-sdk/blob/main/src/roboto/domain/platform_events/events.py#L188-L194)

Bases: `pydantic.BaseModel`

Payload for [`PlatformEventType.DatasetCreated`](/reference/python-sdk/roboto/domain/platform_events/events#roboto.domain.platform_events.events.PlatformEventType.DatasetCreated).

**Parameters**

- **data** (`Any`)

**Attributes**

- **DatasetCreatedPayload.dataset_id** (`str`): The created dataset.
- **DatasetCreatedPayload.model_config**: Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

### DatasetMetadataUpdatedPayload

```python
class roboto.domain.platform_events.events.DatasetMetadataUpdatedPayload(/, **data: Any)
```

`from roboto.domain.platform_events import DatasetMetadataUpdatedPayload`

[Source](https://github.com/roboto-ai/roboto-python-sdk/blob/main/src/roboto/domain/platform_events/events.py#L176-L185)

Bases: `pydantic.BaseModel`

Payload for [`PlatformEventType.DatasetMetadataUpdated`](/reference/python-sdk/roboto/domain/platform_events/events#roboto.domain.platform_events.events.PlatformEventType.DatasetMetadataUpdated).

**Parameters**

- **data** (`Any`)

**Attributes**

- **DatasetMetadataUpdatedPayload.changeset** (`roboto.updates.MetadataChangeset`): The applied metadata/tag delta, served to conditions as the `changed` and `tag` roots.
- **DatasetMetadataUpdatedPayload.dataset_id** (`str`): The dataset whose metadata changed.
- **DatasetMetadataUpdatedPayload.model_config**: Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

### DatasetTagAddedPayload

```python
class roboto.domain.platform_events.events.DatasetTagAddedPayload(/, **data: Any)
```

`from roboto.domain.platform_events import DatasetTagAddedPayload`

[Source](https://github.com/roboto-ai/roboto-python-sdk/blob/main/src/roboto/domain/platform_events/events.py#L197-L206)

Bases: `pydantic.BaseModel`

Payload for [`PlatformEventType.DatasetTagAdded`](/reference/python-sdk/roboto/domain/platform_events/events#roboto.domain.platform_events.events.PlatformEventType.DatasetTagAdded).

**Parameters**

- **data** (`Any`)

**Attributes**

- **DatasetTagAddedPayload.dataset_id** (`str`): The tagged dataset.
- **DatasetTagAddedPayload.model_config**: Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- **DatasetTagAddedPayload.tags_added** (`list[str]`): Tags added by the mutation, served to conditions as the `tag` root.

### EventCreatedPayload

```python
class roboto.domain.platform_events.events.EventCreatedPayload(/, **data: Any)
```

`from roboto.domain.platform_events import EventCreatedPayload`

[Source](https://github.com/roboto-ai/roboto-python-sdk/blob/main/src/roboto/domain/platform_events/events.py#L245-L251)

Bases: `pydantic.BaseModel`

Payload for [`PlatformEventType.EventCreated`](/reference/python-sdk/roboto/domain/platform_events/events#roboto.domain.platform_events.events.PlatformEventType.EventCreated).

**Parameters**

- **data** (`Any`)

**Attributes**

- **EventCreatedPayload.event_id** (`str`): The created event, an [`EventRecord`](/reference/python-sdk/roboto/domain/events/record#roboto.domain.events.record.EventRecord).
- **EventCreatedPayload.model_config**: Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

### FileIngestedPayload

```python
class roboto.domain.platform_events.events.FileIngestedPayload(/, **data: Any)
```

`from roboto.domain.platform_events import FileIngestedPayload`

[Source](https://github.com/roboto-ai/roboto-python-sdk/blob/main/src/roboto/domain/platform_events/events.py#L134-L152)

Bases: `pydantic.BaseModel`

Payload for [`PlatformEventType.FileIngested`](/reference/python-sdk/roboto/domain/platform_events/events#roboto.domain.platform_events.events.PlatformEventType.FileIngested).

**Parameters**

- **data** (`Any`)

**Attributes**

- **FileIngestedPayload.dataset_id** (`str`): Dataset containing the ingested file.
- **FileIngestedPayload.file_id** (`str`): The ingested file.
- **FileIngestedPayload.file_version** (`int | None`) = `None`: The file's version when the event was published; a newer version may exist by the time a trigger evaluates. Versions number revisions of the file record, which a metadata or tag edit advances just as an overwrite of the file's contents does. `None` on events published before the payload carried this field.
- **FileIngestedPayload.model_config**: Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- **FileIngestedPayload.transaction_id** (`str | None`) = `None`: Upload transaction the file arrived in, when known.

### FileMetadataUpdatedPayload

```python
class roboto.domain.platform_events.events.FileMetadataUpdatedPayload(/, **data: Any)
```

`from roboto.domain.platform_events import FileMetadataUpdatedPayload`

[Source](https://github.com/roboto-ai/roboto-python-sdk/blob/main/src/roboto/domain/platform_events/events.py#L155-L173)

Bases: `pydantic.BaseModel`

Payload for [`PlatformEventType.FileMetadataUpdated`](/reference/python-sdk/roboto/domain/platform_events/events#roboto.domain.platform_events.events.PlatformEventType.FileMetadataUpdated).

**Parameters**

- **data** (`Any`)

**Attributes**

- **FileMetadataUpdatedPayload.changeset** (`roboto.updates.MetadataChangeset`): The applied metadata/tag delta, served to conditions as the `changed` and `tag` roots.
- **FileMetadataUpdatedPayload.dataset_id** (`str`): Dataset containing the updated file.
- **FileMetadataUpdatedPayload.file_id** (`str`): The file whose metadata changed.
- **FileMetadataUpdatedPayload.file_version** (`int | None`) = `None`: The file's version when the event was published; a newer version may exist by the time a trigger evaluates. Versions number revisions of the file record, which a metadata or tag edit advances just as an overwrite of the file's contents does. `None` on events published before the payload carried this field.
- **FileMetadataUpdatedPayload.model_config**: Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

### FileUploadedPayload

```python
class roboto.domain.platform_events.events.FileUploadedPayload(/, **data: Any)
```

`from roboto.domain.platform_events import FileUploadedPayload`

[Source](https://github.com/roboto-ai/roboto-python-sdk/blob/main/src/roboto/domain/platform_events/events.py#L101-L119)

Bases: `pydantic.BaseModel`

Payload for [`PlatformEventType.FileUploaded`](/reference/python-sdk/roboto/domain/platform_events/events#roboto.domain.platform_events.events.PlatformEventType.FileUploaded).

**Parameters**

- **data** (`Any`)

**Attributes**

- **FileUploadedPayload.dataset_id** (`str`): Dataset the file was uploaded to.
- **FileUploadedPayload.file_id** (`str`): The uploaded file.
- **FileUploadedPayload.file_version** (`int | None`) = `None`: The file's version when the event was published; a newer version may exist by the time a trigger evaluates. Versions number revisions of the file record, which a metadata or tag edit advances just as an overwrite of the file's contents does. `None` on events published before the payload carried this field.
- **FileUploadedPayload.model_config**: Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- **FileUploadedPayload.transaction_id** (`str | None`) = `None`: Upload transaction the file arrived in, when the upload used one.

### InvocationCompletedPayload

```python
class roboto.domain.platform_events.events.InvocationCompletedPayload(/, **data: Any)
```

`from roboto.domain.platform_events import InvocationCompletedPayload`

[Source](https://github.com/roboto-ai/roboto-python-sdk/blob/main/src/roboto/domain/platform_events/events.py#L209-L224)

Bases: `pydantic.BaseModel`

Payload for [`PlatformEventType.InvocationCompleted`](/reference/python-sdk/roboto/domain/platform_events/events#roboto.domain.platform_events.events.PlatformEventType.InvocationCompleted).

**Parameters**

- **data** (`Any`)

**Attributes**

- **InvocationCompletedPayload.action_name** (`str`): Name of the invoked action. Unique within [`action_owner_id`](/reference/python-sdk/roboto/domain/platform_events/events#roboto.domain.platform_events.events.InvocationCompletedPayload.action_owner_id)'s org.
- **InvocationCompletedPayload.action_owner_id** (`str`): Org that owns the invoked action.
- **InvocationCompletedPayload.invocation_id** (`str`): The completed invocation.
- **InvocationCompletedPayload.model_config**: Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- **InvocationCompletedPayload.status** (`roboto.domain.actions.invocation_record.InvocationStatus`): Terminal status the invocation reached.

### InvocationFailedPayload

```python
class roboto.domain.platform_events.events.InvocationFailedPayload(/, **data: Any)
```

`from roboto.domain.platform_events import InvocationFailedPayload`

[Source](https://github.com/roboto-ai/roboto-python-sdk/blob/main/src/roboto/domain/platform_events/events.py#L227-L242)

Bases: `pydantic.BaseModel`

Payload for [`PlatformEventType.InvocationFailed`](/reference/python-sdk/roboto/domain/platform_events/events#roboto.domain.platform_events.events.PlatformEventType.InvocationFailed).

**Parameters**

- **data** (`Any`)

**Attributes**

- **InvocationFailedPayload.action_name** (`str`): Name of the invoked action. Unique within [`action_owner_id`](/reference/python-sdk/roboto/domain/platform_events/events#roboto.domain.platform_events.events.InvocationFailedPayload.action_owner_id)'s org.
- **InvocationFailedPayload.action_owner_id** (`str`): Org that owns the invoked action.
- **InvocationFailedPayload.invocation_id** (`str`): The failed invocation.
- **InvocationFailedPayload.model_config**: Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- **InvocationFailedPayload.status** (`roboto.domain.actions.invocation_record.InvocationStatus`): Terminal status the invocation reached (`Failed` or `Deadly`).

### PlatformEvent

```python
class roboto.domain.platform_events.events.PlatformEvent(/, **data: Any)
```

`from roboto.domain.platform_events import PlatformEvent`

[Source](https://github.com/roboto-ai/roboto-python-sdk/blob/main/src/roboto/domain/platform_events/events.py#L313-L435)

Bases: `pydantic.BaseModel`

One occurrence of something that happened on the platform, as a trigger receives it.

[`id`](/reference/python-sdk/roboto/domain/platform_events/events#roboto.domain.platform_events.events.PlatformEvent.id), [`source`](/reference/python-sdk/roboto/domain/platform_events/events#roboto.domain.platform_events.events.PlatformEvent.source), [`type`](/reference/python-sdk/roboto/domain/platform_events/events#roboto.domain.platform_events.events.PlatformEvent.type), [`time`](/reference/python-sdk/roboto/domain/platform_events/events#roboto.domain.platform_events.events.PlatformEvent.time) and [`subject`](/reference/python-sdk/roboto/domain/platform_events/events#roboto.domain.platform_events.events.PlatformEvent.subject) are the CloudEvents 1.0 context attributes; [`to_cloudevent()`](/reference/python-sdk/roboto/domain/platform_events/events#roboto.domain.platform_events.events.PlatformEvent.to_cloudevent) renders the occurrence in that spec's structured-JSON form. The envelope stays thin: [`data`](/reference/python-sdk/roboto/domain/platform_events/events#roboto.domain.platform_events.events.PlatformEvent.data) carries entity ids and facts fixed at [`time`](/reference/python-sdk/roboto/domain/platform_events/events#roboto.domain.platform_events.events.PlatformEvent.time), such as a metadata delta or a terminal status, and never mutable entity state — conditions and target templates read an entity's current state at evaluation time through an [`EventNamespace`](/reference/python-sdk/roboto/domain/triggers/namespace#roboto.domain.triggers.namespace.EventNamespace).

**Parameters**

- **data** (`Any`)

**Attributes**

- **PlatformEvent.data** (`PlatformEventPayload`): The per-type payload. Its model must be the one registered for [`type`](/reference/python-sdk/roboto/domain/platform_events/events#roboto.domain.platform_events.events.PlatformEvent.type) in the default catalog; a mismatch is rejected at validation time.
- **PlatformEvent.id** (`str`): Producer-vended event id, unique within [`source`](/reference/python-sdk/roboto/domain/platform_events/events#roboto.domain.platform_events.events.PlatformEvent.source); deterministic where possible (e.g. `evt:{invocation_id}:completed`).
- **PlatformEvent.model_config**: Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- **PlatformEvent.org_id** (`str`): Organization in which the event occurred and whose triggers see it.
- **PlatformEvent.schema_version** (`int`) = `1`: Version of the envelope + payload schema. Bumped only for breaking changes.
- **PlatformEvent.source** (`str`): The org and the deployment the event happened in, as built by [`platform_event_source()`](/reference/python-sdk/roboto/domain/platform_events/events#roboto.domain.platform_events.events.platform_event_source).
- **PlatformEvent.time** (`datetime.datetime`): When the event occurred.
- **PlatformEvent.type** (`PlatformEventType`): Which kind of event this is. Dictates the concrete model of [`data`](/reference/python-sdk/roboto/domain/platform_events/events#roboto.domain.platform_events.events.PlatformEvent.data).

**Properties**

- **PlatformEvent.subject** (`str`): The entity the event is about, as a `roboto://` URI (`roboto://file/fl_1a2b`).

  Computed from [`data`](/reference/python-sdk/roboto/domain/platform_events/events#roboto.domain.platform_events.events.PlatformEvent.data) by the event type's catalog descriptor rather than stored, so it cannot disagree with the payload, and serialized like a declared field.

- **PlatformEvent.subject_uri** (`roboto.uri.RobotoUri`): [`subject`](/reference/python-sdk/roboto/domain/platform_events/events#roboto.domain.platform_events.events.PlatformEvent.subject) as a parsed [`RobotoUri`](/reference/python-sdk/roboto/uri#roboto.uri.RobotoUri).

#### PlatformEvent.to_cloudevent()

```python
def to_cloudevent() -> dict[str, Any]
```

[Source](https://github.com/roboto-ai/roboto-python-sdk/blob/main/src/roboto/domain/platform_events/events.py#L372-L396)

Return this event as CloudEvents 1.0 structured JSON (`application/cloudevents+json`).

Nothing serializes it yet: the command bus carries the model itself. It exists so an outbound webhook body needs no redesign.

Context attributes sit at the top level under their spec names, with `type` carrying [`CLOUDEVENTS_TYPE_PREFIX`](/reference/python-sdk/roboto/domain/platform_events/events#roboto.domain.platform_events.events.CLOUDEVENTS_TYPE_PREFIX) and `datacontenttype` fixed at `application/json`. [`org_id`](/reference/python-sdk/roboto/domain/platform_events/events#roboto.domain.platform_events.events.PlatformEvent.org_id) and [`schema_version`](/reference/python-sdk/roboto/domain/platform_events/events#roboto.domain.platform_events.events.PlatformEvent.schema_version) arrive as the extension attributes `orgid` and `schemaversion`, because extension names must be lowercase alphanumerics. The returned dict is JSON-serializable as-is.

**Returns**

- `dict[str, Any]`

### PlatformEventPayload

```python
roboto.domain.platform_events.events.PlatformEventPayload
```

`from roboto.domain.platform_events import PlatformEventPayload`

[Source](https://github.com/roboto-ai/roboto-python-sdk/blob/main/src/roboto/domain/platform_events/events.py#L278-L291)

Union of every per-type payload model. Which member is legal for a given [`PlatformEvent`](/reference/python-sdk/roboto/domain/platform_events/events#roboto.domain.platform_events.events.PlatformEvent) is dictated by its [`type`](/reference/python-sdk/roboto/domain/platform_events/events#roboto.domain.platform_events.events.PlatformEvent.type).

### PlatformEventType

```python
class roboto.domain.platform_events.events.PlatformEventType
```

`from roboto.domain.platform_events import PlatformEventType`

[Source](https://github.com/roboto-ai/roboto-python-sdk/blob/main/src/roboto/domain/platform_events/events.py#L31-L98)

Bases: `roboto.compat.StrEnum`

A thing that happens on the platform that triggers can subscribe to.

Every member has a [`PlatformEventDescriptor`](/reference/python-sdk/roboto/domain/platform_events/catalog#roboto.domain.platform_events.catalog.PlatformEventDescriptor) in the default [`PlatformEventCatalog`](/reference/python-sdk/roboto/domain/platform_events/catalog#roboto.domain.platform_events.catalog.PlatformEventCatalog) describing its payload model, the namespace roots it exposes to conditions and templates, and the [`OncePer`](/reference/python-sdk/roboto/domain/platform_events/once_per#roboto.domain.platform_events.once_per.OncePer) values it supports.

**Attributes**

- **PlatformEventType.DatasetCreated** = `'dataset.created'`: A dataset was created.
- **PlatformEventType.DatasetMetadataUpdated** = `'dataset.metadata_updated'`: A dataset's metadata or tags changed.
- **PlatformEventType.DatasetTagAdded** = `'dataset.tag_added'`: One or more tags were added to a dataset.
- **PlatformEventType.EventCreated** = `'event.created'`: An event, the annotation marking a span of time on your data, was created.
- **PlatformEventType.FileIngested** = `'file.ingested'`: A file finished ingestion (post-processing) and its topics are available.
- **PlatformEventType.FileMetadataUpdated** = `'file.metadata_updated'`: A file's metadata or tags changed.
- **PlatformEventType.FileUploaded** = `'file.uploaded'`: A file finished uploading to a dataset.
- **PlatformEventType.InvocationCompleted** = `'invocation.completed'`: An action invocation reached a successful terminal status.
- **PlatformEventType.InvocationFailed** = `'invocation.failed'`: An action invocation reached a failed terminal status (`Failed` or `Deadly`).
- **PlatformEventType.ScheduleFired** = `'schedule.fired'`: A trigger's own schedule reached one of its minutes. Not subscribable: a trigger fires on a schedule by declaring a [`Schedule`](/reference/python-sdk/roboto/domain/triggers/sources#roboto.domain.triggers.sources.Schedule) source, and the scheduler delivers this occurrence to that trigger alone.
- **PlatformEventType.SessionIngested** = `'session.ingested'`: Every ingestable file in a complete session is ingested. Fires again, as a new occurrence, each time the session's ingestable files change and are all ingested again.
- **PlatformEventType.UploadCompleted** = `'dataset.upload_completed'`: An upload transaction to a dataset completed (all of its files uploaded).

**Properties**

- **PlatformEventType.cloudevents_type** (`str`): This type as a CloudEvents `type` attribute: `ai.roboto.file.uploaded`.

#### PlatformEventType.from_cloudevents_type()

```python
@classmethod
def from_cloudevents_type(value: str) -> PlatformEventType
```

[Source](https://github.com/roboto-ai/roboto-python-sdk/blob/main/src/roboto/domain/platform_events/events.py#L46-L59)

Return the event type a CloudEvents `type` attribute names; the inverse of [`cloudevents_type`](/reference/python-sdk/roboto/domain/platform_events/events#roboto.domain.platform_events.events.PlatformEventType.cloudevents_type).

**Parameters**

- **value** (`str`): A prefixed type, such as `ai.roboto.file.uploaded`.

**Raises**

- `ValueError`: `value` lacks the prefix or names no platform event type.

**Returns**

- `PlatformEventType`

### ScheduleFiredPayload

```python
class roboto.domain.platform_events.events.ScheduleFiredPayload(/, **data: Any)
```

`from roboto.domain.platform_events import ScheduleFiredPayload`

[Source](https://github.com/roboto-ai/roboto-python-sdk/blob/main/src/roboto/domain/platform_events/events.py#L266-L275)

Bases: `pydantic.BaseModel`

Payload for [`PlatformEventType.ScheduleFired`](/reference/python-sdk/roboto/domain/platform_events/events#roboto.domain.platform_events.events.PlatformEventType.ScheduleFired).

**Parameters**

- **data** (`Any`)

**Attributes**

- **ScheduleFiredPayload.model_config**: Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- **ScheduleFiredPayload.scheduled_for** (`datetime.datetime`): The scheduled minute (UTC) this occurrence stands for.
- **ScheduleFiredPayload.trigger_id** (`str`): The trigger whose schedule fired.

### SessionIngestedPayload

```python
class roboto.domain.platform_events.events.SessionIngestedPayload(/, **data: Any)
```

`from roboto.domain.platform_events import SessionIngestedPayload`

[Source](https://github.com/roboto-ai/roboto-python-sdk/blob/main/src/roboto/domain/platform_events/events.py#L254-L263)

Bases: `pydantic.BaseModel`

Payload for [`PlatformEventType.SessionIngested`](/reference/python-sdk/roboto/domain/platform_events/events#roboto.domain.platform_events.events.PlatformEventType.SessionIngested).

**Parameters**

- **data** (`Any`)

**Attributes**

- **SessionIngestedPayload.ingestion_number** (`int`): Which announcement this is for the session, starting at 1.
- **SessionIngestedPayload.model_config**: Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- **SessionIngestedPayload.session_id** (`str`): The session whose ingestable files are all ingested.

### UploadCompletedPayload

```python
class roboto.domain.platform_events.events.UploadCompletedPayload(/, **data: Any)
```

`from roboto.domain.platform_events import UploadCompletedPayload`

[Source](https://github.com/roboto-ai/roboto-python-sdk/blob/main/src/roboto/domain/platform_events/events.py#L122-L131)

Bases: `pydantic.BaseModel`

Payload for [`PlatformEventType.UploadCompleted`](/reference/python-sdk/roboto/domain/platform_events/events#roboto.domain.platform_events.events.PlatformEventType.UploadCompleted).

**Parameters**

- **data** (`Any`)

**Attributes**

- **UploadCompletedPayload.dataset_id** (`str`): Dataset the upload targeted.
- **UploadCompletedPayload.model_config**: Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- **UploadCompletedPayload.transaction_id** (`str`): The completed upload transaction.

### platform_event_source()

```python
def roboto.domain.platform_events.events.platform_event_source(
    api_domain: Optional[str],
    org_id: str,
) -> str
```

`from roboto.domain.platform_events import platform_event_source`

[Source](https://github.com/roboto-ai/roboto-python-sdk/blob/main/src/roboto/domain/platform_events/events.py#L296-L310)

Return the CloudEvents `source` for one org's events on one deployment.

The value is the org's own API resource, `https://{api_domain}/v1/orgs/{org_id}`. No two deployments produce the same `source`, so it pairs with [`PlatformEvent.id`](/reference/python-sdk/roboto/domain/platform_events/events#roboto.domain.platform_events.events.PlatformEvent.id) to identify a single occurrence.

**Parameters**

- **api_domain** (`Optional[str]`): Public API host of the emitting deployment, such as `api.roboto.ai`. Without one, the result is the relative reference `/v1/orgs/{org_id}`.
- **org_id** (`str`): Organization whose events carry this source.

**Returns**

- `str`
