arvo-core
    Preparing search index...

    Type Alias CreateArvoEvent<TData, TType>

    Represents the input parameters for creating an ArvoEvent.

    type CreateArvoEvent<TData extends ArvoEventData, TType extends string> = {
        accesscontrol?: string;
        data: TData;
        datacontenttype?: string;
        dataschema?: string;
        domain?: string;
        executionunits?: number;
        id?: { deduplication: "DEVELOPER_MANAGED" | "ARVO_MANAGED"; value: string };
        parentid?: string;
        redirectto?: string;
        source: string;
        specversion?: "1.0";
        subject: string;
        time?: string;
        to?: string;
        traceparent?: string;
        tracestate?: string;
        type: TType;
    }

    Type Parameters

    • TData extends ArvoEventData

      The type of the event data, extending ArvoEventData.

    • TType extends string

      The type name of the event

    Index

    Properties

    accesscontrol?: string

    Defines access controls for the event. Can be a UserID, encrypted string, or key-value pairs.

    data: TData

    The event payload. This payload must be JSON serializable.

    datacontenttype?: string

    Content type of the data value. Must include 'application/cloudevents+json' or 'application/json'. For an ArvoEvent, it is set automatically to 'application/cloudevents+json;charset=UTF-8;profile=arvo'

    dataschema?: string

    Identifies the schema that data adheres to. Must be a valid URI if present.

    domain?: string

    Specifies the processing domain for event routing and workflow orchestration. Must contain only lowercase letters, numbers, and dots.

    executionunits?: number

    Represents the cost associated with generating the cloudevent.

    id?: { deduplication: "DEVELOPER_MANAGED" | "ARVO_MANAGED"; value: string }

    The event id serves as the primary deduplication key within the Arvo system, ensuring idempotent event processing. If not provided, a UUID v4 will be automatically generated.

    Type Declaration

    • deduplication: "DEVELOPER_MANAGED" | "ARVO_MANAGED"

      Deduplication identifier management strategy.

      • DEVELOPER_MANAGED: You, the developer, guarantee uniqueness of the identifier value. The provided value is used directly as the deduplication key without modification.

      • ARVO_MANAGED: Arvo manages identifier uniqueness by generating a composite key. The final identifier follows the format base64({uuid: uuid4(), value: value}), where a UUID v4 prefix ensures global uniqueness while preserving the developer's value for reference.

    • value: string

      The id value

    parentid?: string

    The unique identifier of the event that directly triggered the creation of this event within the Arvo ecosystem.

    redirectto?: string

    Indicates alternative recipients or destinations for events. Must be a valid URI if present.

    source: string

    Identifies the context in which an event happened. Must be a valid URI representing the event producer.

    specversion?: "1.0"

    The version of the CloudEvents specification used. Must be '1.0' for this version.

    subject: string

    Identifies the subject of the event. For Arvo, this must be the Process Id.

    time?: string

    Timestamp of when the occurrence happened. Must be in ISO 8601 format with timezone offset.

    to?: string

    Defines the consumer machine of the event. Used for event routing. Must be a valid URI if present.

    traceparent?: string

    Contains trace context information for distributed tracing (OpenTelemetry).

    tracestate?: string

    Conveys vendor-specific trace information across service boundaries (OpenTelemetry).

    type: TType

    Describes the type of event. Should be prefixed with a reverse-DNS name.