Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 10 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,19 +22,29 @@ use CloudEvents\V1\CloudEventImmutable;

// Immutable CloudEvent
$immutableEvent = new CloudEventImmutable(
# Event ID
'1n6bFxDMHZFChlI4TVI9tdzphB9',
# Event source
'/examples/php-sdk',
# Event type
'com.example.type',
# Data attached to event
['example' => 'first-event'],
# mime-type of extra data
'application/json'
);

// Mutable CloudEvent
$mutableEvent = new CloudEvent(
# Event ID
'1n6bFxDMHZFChlI4TVI9tdzphB9',
# Event source
'/examples/php-sdk',
# Event type
'com.example.type',
# Data attached to event
['example' => 'first-event'],
# mime-type of extra data
'application/json'
);

Expand Down
Loading