Skip to content

Platform Events

Services communicate change across the Packt Platform by emitting events. This page describes the public events that are part of the platform's contractual boundaries and how to consume them safely.

Public vs Internal Events

Kind Purpose Who May Use It
Public Notify the platform that something happened. Stable contract; safe to build integrations on Any downstream service or event target
Internal Signal things inside a single service. Implementation detail Only that service

Public event names use the packt.* prefix. Internal event names use the internal.* prefix. Do not integrate with another service's internal events — they can change at any time.

Event Naming Convention

Public event names follow a dot-separated structure:

  1. packt (fixed)
  2. service — e.g. content, products, distribution
  3. resource — e.g. document, product, pricing, channel
  4. version — e.g. v1
  5. action — e.g. created, updated, deleted, published

Examples: packt.content.document.v1.created, packt.products.pricing.v1.updated.

Event Envelope

Event payloads use the CloudEvents envelope. The event type attribute is the event name above. The data payload is defined per event and may be JSON or protobuf. Consume by event type and version so payloads can evolve without breaking subscribers.

Transport

Public events are published to AWS EventBridge buses. Attach targets (Lambdas, SQS, other buses) by event name or pattern.

Best Practices

  • At-least-once delivery — events may be delivered more than once. Handle idempotency using the event ID.
  • Cross-service reactions only — use public events to react to changes in other services, not your own.
  • Do not depend on internal events — if you need a public event that does not exist yet, request it.

Event Catalogue

Content Lake

Event Bus Event Name Description
content packt.content.document.v1.created A new document was created
content packt.content.document.v1.updated Document content was updated
content packt.content.document.v1.deleted A document was deleted
content packt.content.ingestion.v1.created An ingestion job was created
content packt.content.ingestion.v1.started An ingestion job started
content packt.content.ingestion.v1.completed An ingestion job completed
content packt.content.enhancement.v1.started Document enhancement started
content packt.content.enhancement.v1.completed Document enhancement completed
content packt.content.version.v1.created A new document version was created
content packt.content.version.v1.deleted A document version was deleted
content packt.content.version.v1.compacted Document versions were compacted
content packt.content.tags.v1.added Tags were added to a document
content packt.content.tags.v1.removed Tags were removed from a document
content packt.content.entity.v1.matched Matched entities within a document changed
content packt.content.entity.v1.updated Entity data was refreshed

Product Management

Event Bus Event Name Description
products packt.products.product.v1.created A product was created
products packt.products.product.v1.updated A product was updated
products packt.products.product.v1.deleted A product was deleted
products packt.products.product.v1.drafted A product entered DRAFT state
products packt.products.product.v1.scheduled A product was scheduled for publication
products packt.products.product.v1.published A product was published
products packt.products.product.v1.withdrawn A product was withdrawn
products packt.products.pricing.v1.updated Product pricing was updated
products packt.products.content.v1.attached Content was attached to a product
products packt.products.content.v1.detached Content was removed from a product
products packt.products.content.v1.updated Attached content was updated in the Content Lake
products packt.products.promotion.v1.created A promotion was created
products packt.products.promotion.v1.updated A promotion was updated
products packt.products.promotion.v1.deleted A promotion was deleted
products packt.products.promotion.v1.started A promotion started
products packt.products.promotion.v1.ended A promotion ended

Distribution

Event Bus Event Name Description
distribution packt.distribution.channel.v1.created A distribution channel was created
distribution packt.distribution.channel.v1.updated A distribution channel was updated
distribution packt.distribution.channel.v1.deleted A distribution channel was deleted
distribution packt.distribution.channel.v1.activated A distribution channel was activated
distribution packt.distribution.channel.v1.deactivated A distribution channel was deactivated
distribution packt.distribution.restriction.v1.added A distribution restriction was added
distribution packt.distribution.restriction.v1.removed A distribution restriction was removed