Chargebee · AsyncAPI Specification

Chargebee Webhooks

Version 2

AsyncAPI description of Chargebee's webhook (event) surface. When a notable change occurs on a Chargebee site (customer created, subscription cancelled, invoice generated, payment failed, etc.) Chargebee POSTs an Event object to each configured webhook endpoint. This document models the Event envelope and the documented event_type identifiers grouped by resource category. Event types are sourced from https://apidocs.chargebee.com/docs/api/events/event-types. The content object carried inside each event holds the relevant resource(s) (subscription, customer, invoice, transaction, credit_note, etc.) — the detailed resource schemas live in the Chargebee REST API reference and the Chargebee OpenAPI repository (https://github.com/chargebee/openapi).

View Spec View on GitHub BillingSubscriptionsRecurring BillingRevenuePaymentsSaaSAsyncAPIWebhooksEvents

Channels

customer
subscribe receiveCustomerEvent
Receive a Chargebee customer event.
Customer lifecycle events.
subscription
subscribe receiveSubscriptionEvent
Subscription lifecycle events.
invoice
subscribe receiveInvoiceEvent
Invoice and pending-invoice lifecycle events.
credit_note
subscribe receiveCreditNoteEvent
Credit note lifecycle events.
transaction
subscribe receiveTransactionEvent
Transaction lifecycle events.
payment
subscribe receivePaymentEvent
Payment, refund, and payment intent events.
payment_source
subscribe receivePaymentSourceEvent
Payment source (card, bank account, etc.) events.
payment_schedule
subscribe receivePaymentScheduleEvent
Payment schedule scheme and instance events.
gift
subscribe receiveGiftEvent
Gift subscription events.
quote
subscribe receiveQuoteEvent
Quote lifecycle events.
coupon
subscribe receiveCouponEvent
Coupon, coupon set, and coupon code events.
item
subscribe receiveItemEvent
Product catalog v2 item, item price, item family, and differential price events.
feature
subscribe receiveFeatureEvent
Entitlement feature lifecycle events.
entitlement_override
subscribe receiveEntitlementOverrideEvent
Customer-level entitlement override events.
order
subscribe receiveOrderEvent
Order and sales order events.
contract_term
subscribe receiveContractTermEvent
Subscription contract term events.
business_entity
subscribe receiveBusinessEntityEvent
Business entity and hierarchy events.
promotional_credits
subscribe receivePromotionalCreditsEvent
Promotional credit ledger events.
unbilled_charges
subscribe receiveUnbilledChargesEvent
Unbilled charge lifecycle events.
token
subscribe receiveTokenEvent
Payment token events (tokenization).
voucher
subscribe receiveVoucherEvent
Voucher events.
tax_withheld
subscribe receiveTaxWithheldEvent
Tax withheld lifecycle events.
rule
subscribe receiveRuleEvent
Rule lifecycle events.
usage
subscribe receiveUsageEvent
Usage metering events.
purchase
subscribe receivePurchaseEvent
Purchase events.
omnichannel
subscribe receiveOmnichannelEvent
Omnichannel subscription and transaction events (Chargebee Omnichannel).
site_signals
subscribe receiveSiteSignalEvent
Site-wide signal events (alerts, dunning, MRR).

Messages

CustomerChanged
customer_changed
A customer was changed.
CustomerCreated
customer_created
A new customer was created.
CustomerDeleted
customer_deleted
A customer was deleted.
CustomerMovedIn
customer_moved_in
A customer was moved into the site.
CustomerMovedOut
customer_moved_out
A customer was moved out of the site.
CustomerBusinessEntityChanged
customer_business_entity_changed
A customer's business entity was changed.
CustomerEntitlementsUpdated
customer_entitlements_updated
A customer's entitlements were updated.
SubscriptionActivated
subscription_activated
Subscription moved out of trial into active state.
SubscriptionActivatedWithBackdating
subscription_activated_with_backdating
SubscriptionAdvanceInvoiceScheduleAdded
subscription_advance_invoice_schedule_added
SubscriptionAdvanceInvoiceScheduleRemoved
subscription_advance_invoice_schedule_removed
SubscriptionAdvanceInvoiceScheduleUpdated
subscription_advance_invoice_schedule_updated
SubscriptionBusinessEntityChanged
subscription_business_entity_changed
SubscriptionCanceledWithBackdating
subscription_canceled_with_backdating
SubscriptionCancellationReminder
subscription_cancellation_reminder
SubscriptionCancellationScheduled
subscription_cancellation_scheduled
SubscriptionCancelled
subscription_cancelled
Subscription was cancelled.
SubscriptionChanged
subscription_changed
SubscriptionChangedWithBackdating
subscription_changed_with_backdating
SubscriptionChangesScheduled
subscription_changes_scheduled
SubscriptionCreated
subscription_created
A new subscription was created.
SubscriptionCreatedWithBackdating
subscription_created_with_backdating
SubscriptionDeleted
subscription_deleted
SubscriptionEntitlementsCreated
subscription_entitlements_created
SubscriptionEntitlementsUpdated
subscription_entitlements_updated
SubscriptionItemsRenewed
subscription_items_renewed
SubscriptionMovedIn
subscription_moved_in
SubscriptionMovedOut
subscription_moved_out
SubscriptionMovementFailed
subscription_movement_failed
SubscriptionPauseScheduled
subscription_pause_scheduled
SubscriptionPaused
subscription_paused
SubscriptionRampApplied
subscription_ramp_applied
SubscriptionRampCreated
subscription_ramp_created
SubscriptionRampDeleted
subscription_ramp_deleted
SubscriptionRampDrafted
subscription_ramp_drafted
SubscriptionRampUpdated
subscription_ramp_updated
SubscriptionReactivated
subscription_reactivated
SubscriptionReactivatedWithBackdating
subscription_reactivated_with_backdating
SubscriptionRenewalReminder
subscription_renewal_reminder
SubscriptionRenewed
subscription_renewed
SubscriptionResumed
subscription_resumed
SubscriptionResumptionScheduled
subscription_resumption_scheduled
SubscriptionScheduledCancellationRemoved
subscription_scheduled_cancellation_removed
SubscriptionScheduledChangesRemoved
subscription_scheduled_changes_removed
SubscriptionScheduledPauseRemoved
subscription_scheduled_pause_removed
SubscriptionScheduledResumptionRemoved
subscription_scheduled_resumption_removed
SubscriptionShippingAddressUpdated
subscription_shipping_address_updated
SubscriptionStarted
subscription_started
SubscriptionTrialEndReminder
subscription_trial_end_reminder
SubscriptionTrialExtended
subscription_trial_extended
InvoiceDeleted
invoice_deleted
InvoiceGenerated
invoice_generated
A new invoice was generated.
InvoiceGeneratedWithBackdating
invoice_generated_with_backdating
InvoiceUpdated
invoice_updated
PendingInvoiceCreated
pending_invoice_created
PendingInvoiceUpdated
pending_invoice_updated
CreditNoteCreated
credit_note_created
CreditNoteCreatedWithBackdating
credit_note_created_with_backdating
CreditNoteDeleted
credit_note_deleted
CreditNoteUpdated
credit_note_updated
TransactionCreated
transaction_created
TransactionDeleted
transaction_deleted
TransactionUpdated
transaction_updated
AuthorizationSucceeded
authorization_succeeded
AuthorizationVoided
authorization_voided
PaymentDueReminder
payment_due_reminder
PaymentFailed
payment_failed
A payment attempt failed.
PaymentInitiated
payment_initiated
PaymentIntentCreated
payment_intent_created
PaymentIntentUpdated
payment_intent_updated
PaymentRefunded
payment_refunded
PaymentSucceeded
payment_succeeded
A payment attempt succeeded.
RefundInitiated
refund_initiated
CardAdded
card_added
CardDeleted
card_deleted
CardExpired
card_expired
CardExpiryReminder
card_expiry_reminder
CardUpdated
card_updated
PaymentSourceAdded
payment_source_added
PaymentSourceDeleted
payment_source_deleted
PaymentSourceExpired
payment_source_expired
PaymentSourceExpiring
payment_source_expiring
PaymentSourceLocallyDeleted
payment_source_locally_deleted
PaymentSourceUpdated
payment_source_updated
VirtualBankAccountAdded
virtual_bank_account_added
VirtualBankAccountDeleted
virtual_bank_account_deleted
VirtualBankAccountUpdated
virtual_bank_account_updated
PaymentScheduleSchemeCreated
payment_schedule_scheme_created
PaymentScheduleSchemeDeleted
payment_schedule_scheme_deleted
PaymentSchedulesCreated
payment_schedules_created
PaymentSchedulesUpdated
payment_schedules_updated
GiftCancelled
gift_cancelled
GiftClaimed
gift_claimed
GiftExpired
gift_expired
GiftScheduled
gift_scheduled
GiftUnclaimed
gift_unclaimed
GiftUpdated
gift_updated
QuoteCreated
quote_created
QuoteDeleted
quote_deleted
QuoteUpdated
quote_updated
CouponCreated
coupon_created
CouponDeleted
coupon_deleted
CouponUpdated
coupon_updated
CouponSetCreated
coupon_set_created
CouponSetDeleted
coupon_set_deleted
CouponSetUpdated
coupon_set_updated
CouponCodesAdded
coupon_codes_added
CouponCodesDeleted
coupon_codes_deleted
CouponCodesUpdated
coupon_codes_updated
ItemCreated
item_created
ItemDeleted
item_deleted
ItemUpdated
item_updated
ItemFamilyCreated
item_family_created
ItemFamilyDeleted
item_family_deleted
ItemFamilyUpdated
item_family_updated
ItemPriceCreated
item_price_created
ItemPriceDeleted
item_price_deleted
ItemPriceUpdated
item_price_updated
ItemEntitlementsRemoved
item_entitlements_removed
ItemEntitlementsUpdated
item_entitlements_updated
ItemPriceEntitlementsRemoved
item_price_entitlements_removed
ItemPriceEntitlementsUpdated
item_price_entitlements_updated
AttachedItemCreated
attached_item_created
AttachedItemDeleted
attached_item_deleted
AttachedItemUpdated
attached_item_updated
DifferentialPriceCreated
differential_price_created
DifferentialPriceDeleted
differential_price_deleted
DifferentialPriceUpdated
differential_price_updated
PriceVariantCreated
price_variant_created
PriceVariantDeleted
price_variant_deleted
PriceVariantUpdated
price_variant_updated
FeatureActivated
feature_activated
FeatureArchived
feature_archived
FeatureCreated
feature_created
FeatureDeleted
feature_deleted
FeatureReactivated
feature_reactivated
FeatureUpdated
feature_updated
EntitlementOverridesAutoRemoved
entitlement_overrides_auto_removed
EntitlementOverridesRemoved
entitlement_overrides_removed
EntitlementOverridesUpdated
entitlement_overrides_updated
OrderCancelled
order_cancelled
OrderCreated
order_created
OrderDeleted
order_deleted
OrderDelivered
order_delivered
OrderReadyToProcess
order_ready_to_process
OrderReadyToShip
order_ready_to_ship
OrderResent
order_resent
OrderReturned
order_returned
OrderUpdated
order_updated
SalesOrderCreated
sales_order_created
SalesOrderUpdated
sales_order_updated
ContractTermCancelled
contract_term_cancelled
ContractTermCompleted
contract_term_completed
ContractTermCreated
contract_term_created
ContractTermRenewed
contract_term_renewed
ContractTermTerminated
contract_term_terminated
BusinessEntityCreated
business_entity_created
BusinessEntityDeleted
business_entity_deleted
BusinessEntityUpdated
business_entity_updated
HierarchyCreated
hierarchy_created
HierarchyDeleted
hierarchy_deleted
PromotionalCreditsAdded
promotional_credits_added
PromotionalCreditsDeducted
promotional_credits_deducted
UnbilledChargesCreated
unbilled_charges_created
UnbilledChargesDeleted
unbilled_charges_deleted
UnbilledChargesInvoiced
unbilled_charges_invoiced
UnbilledChargesVoided
unbilled_charges_voided
TokenConsumed
token_consumed
TokenCreated
token_created
TokenExpired
token_expired
VoucherCreated
voucher_created
VoucherCreateFailed
voucher_create_failed
VoucherExpired
voucher_expired
TaxWithheldDeleted
tax_withheld_deleted
TaxWithheldRecorded
tax_withheld_recorded
TaxWithheldRefunded
tax_withheld_refunded
RuleCreated
rule_created
RuleDeleted
rule_deleted
RuleUpdated
rule_updated
AddUsagesReminder
add_usages_reminder
UsageFileIngested
usage_file_ingested
PurchaseCreated
purchase_created
RecordPurchaseFailed
record_purchase_failed
OmnichannelOneTimeOrderCreated
omnichannel_one_time_order_created
OmnichannelOneTimeOrderItemCancelled
omnichannel_one_time_order_item_cancelled
OmnichannelSubscriptionCreated
omnichannel_subscription_created
OmnichannelSubscriptionImported
omnichannel_subscription_imported
OmnichannelSubscriptionMovedIn
omnichannel_subscription_moved_in
OmnichannelSubscriptionItemCancellationScheduled
omnichannel_subscription_item_cancellation_scheduled
OmnichannelSubscriptionItemCancelled
omnichannel_subscription_item_cancelled
OmnichannelSubscriptionItemChangeScheduled
omnichannel_subscription_item_change_scheduled
OmnichannelSubscriptionItemChanged
omnichannel_subscription_item_changed
OmnichannelSubscriptionItemDowngraded
omnichannel_subscription_item_downgraded
OmnichannelSubscriptionItemDunningExpired
omnichannel_subscription_item_dunning_expired
OmnichannelSubscriptionItemDunningStarted
omnichannel_subscription_item_dunning_started
OmnichannelSubscriptionItemExpired
omnichannel_subscription_item_expired
OmnichannelSubscriptionItemGracePeriodExpired
omnichannel_subscription_item_grace_period_expired
OmnichannelSubscriptionItemGracePeriodStarted
omnichannel_subscription_item_grace_period_started
OmnichannelSubscriptionItemPauseScheduled
omnichannel_subscription_item_pause_scheduled
OmnichannelSubscriptionItemPaused
omnichannel_subscription_item_paused
OmnichannelSubscriptionItemReactivated
omnichannel_subscription_item_reactivated
OmnichannelSubscriptionItemRecovered
omnichannel_subscription_item_recovered
OmnichannelSubscriptionItemRenewed
omnichannel_subscription_item_renewed
OmnichannelSubscriptionItemResubscribed
omnichannel_subscription_item_resubscribed
OmnichannelSubscriptionItemResumed
omnichannel_subscription_item_resumed
OmnichannelSubscriptionItemScheduledCancellationRemoved
omnichannel_subscription_item_scheduled_cancellation_removed
OmnichannelSubscriptionItemScheduledChangeRemoved
omnichannel_subscription_item_scheduled_change_removed
OmnichannelSubscriptionItemUpdated
omnichannel_subscription_item_updated
OmnichannelSubscriptionItemUpgraded
omnichannel_subscription_item_upgraded
OmnichannelTransactionCreated
omnichannel_transaction_created
AlertStatusChanged
alert_status_changed
DunningUpdated
dunning_updated
MrrUpdated
mrr_updated

Servers

https
webhook {your_endpoint_url}
Customer-hosted HTTPS endpoint registered in the Chargebee site under Settings > Webhooks. Chargebee POSTs each event as JSON to this URL. Endpoints may be secured with HTTP Basic Auth credentials configured on the webhook.

AsyncAPI Specification

Raw ↑
asyncapi: 2.6.0
info:
  title: Chargebee Webhooks
  version: "2"
  description: |
    AsyncAPI description of Chargebee's webhook (event) surface. When a notable
    change occurs on a Chargebee site (customer created, subscription cancelled,
    invoice generated, payment failed, etc.) Chargebee POSTs an Event object to
    each configured webhook endpoint. This document models the Event envelope
    and the documented event_type identifiers grouped by resource category.

    Event types are sourced from
    https://apidocs.chargebee.com/docs/api/events/event-types. The content
    object carried inside each event holds the relevant resource(s)
    (subscription, customer, invoice, transaction, credit_note, etc.) — the
    detailed resource schemas live in the Chargebee REST API reference and the
    Chargebee OpenAPI repository (https://github.com/chargebee/openapi).
  contact:
    name: Chargebee API Support
    url: https://www.chargebee.com/docs/api
  externalDocs:
    description: Chargebee Events documentation
    url: https://apidocs.chargebee.com/docs/api/events
defaultContentType: application/json
servers:
  webhook:
    url: '{your_endpoint_url}'
    protocol: https
    description: |
      Customer-hosted HTTPS endpoint registered in the Chargebee site under
      Settings > Webhooks. Chargebee POSTs each event as JSON to this URL.
      Endpoints may be secured with HTTP Basic Auth credentials configured on
      the webhook.
    variables:
      your_endpoint_url:
        default: https://example.com/chargebee/webhook
        description: The HTTPS URL you registered with Chargebee for webhook delivery.
    security:
      - basicAuth: []
channels:
  customer:
    description: Customer lifecycle events.
    subscribe:
      operationId: receiveCustomerEvent
      summary: Receive a Chargebee customer event.
      message:
        oneOf:
          - $ref: '#/components/messages/CustomerChanged'
          - $ref: '#/components/messages/CustomerCreated'
          - $ref: '#/components/messages/CustomerDeleted'
          - $ref: '#/components/messages/CustomerMovedIn'
          - $ref: '#/components/messages/CustomerMovedOut'
          - $ref: '#/components/messages/CustomerBusinessEntityChanged'
          - $ref: '#/components/messages/CustomerEntitlementsUpdated'
  subscription:
    description: Subscription lifecycle events.
    subscribe:
      operationId: receiveSubscriptionEvent
      message:
        oneOf:
          - $ref: '#/components/messages/SubscriptionActivated'
          - $ref: '#/components/messages/SubscriptionActivatedWithBackdating'
          - $ref: '#/components/messages/SubscriptionAdvanceInvoiceScheduleAdded'
          - $ref: '#/components/messages/SubscriptionAdvanceInvoiceScheduleRemoved'
          - $ref: '#/components/messages/SubscriptionAdvanceInvoiceScheduleUpdated'
          - $ref: '#/components/messages/SubscriptionBusinessEntityChanged'
          - $ref: '#/components/messages/SubscriptionCanceledWithBackdating'
          - $ref: '#/components/messages/SubscriptionCancellationReminder'
          - $ref: '#/components/messages/SubscriptionCancellationScheduled'
          - $ref: '#/components/messages/SubscriptionCancelled'
          - $ref: '#/components/messages/SubscriptionChanged'
          - $ref: '#/components/messages/SubscriptionChangedWithBackdating'
          - $ref: '#/components/messages/SubscriptionChangesScheduled'
          - $ref: '#/components/messages/SubscriptionCreated'
          - $ref: '#/components/messages/SubscriptionCreatedWithBackdating'
          - $ref: '#/components/messages/SubscriptionDeleted'
          - $ref: '#/components/messages/SubscriptionEntitlementsCreated'
          - $ref: '#/components/messages/SubscriptionEntitlementsUpdated'
          - $ref: '#/components/messages/SubscriptionItemsRenewed'
          - $ref: '#/components/messages/SubscriptionMovedIn'
          - $ref: '#/components/messages/SubscriptionMovedOut'
          - $ref: '#/components/messages/SubscriptionMovementFailed'
          - $ref: '#/components/messages/SubscriptionPauseScheduled'
          - $ref: '#/components/messages/SubscriptionPaused'
          - $ref: '#/components/messages/SubscriptionRampApplied'
          - $ref: '#/components/messages/SubscriptionRampCreated'
          - $ref: '#/components/messages/SubscriptionRampDeleted'
          - $ref: '#/components/messages/SubscriptionRampDrafted'
          - $ref: '#/components/messages/SubscriptionRampUpdated'
          - $ref: '#/components/messages/SubscriptionReactivated'
          - $ref: '#/components/messages/SubscriptionReactivatedWithBackdating'
          - $ref: '#/components/messages/SubscriptionRenewalReminder'
          - $ref: '#/components/messages/SubscriptionRenewed'
          - $ref: '#/components/messages/SubscriptionResumed'
          - $ref: '#/components/messages/SubscriptionResumptionScheduled'
          - $ref: '#/components/messages/SubscriptionScheduledCancellationRemoved'
          - $ref: '#/components/messages/SubscriptionScheduledChangesRemoved'
          - $ref: '#/components/messages/SubscriptionScheduledPauseRemoved'
          - $ref: '#/components/messages/SubscriptionScheduledResumptionRemoved'
          - $ref: '#/components/messages/SubscriptionShippingAddressUpdated'
          - $ref: '#/components/messages/SubscriptionStarted'
          - $ref: '#/components/messages/SubscriptionTrialEndReminder'
          - $ref: '#/components/messages/SubscriptionTrialExtended'
  invoice:
    description: Invoice and pending-invoice lifecycle events.
    subscribe:
      operationId: receiveInvoiceEvent
      message:
        oneOf:
          - $ref: '#/components/messages/InvoiceDeleted'
          - $ref: '#/components/messages/InvoiceGenerated'
          - $ref: '#/components/messages/InvoiceGeneratedWithBackdating'
          - $ref: '#/components/messages/InvoiceUpdated'
          - $ref: '#/components/messages/PendingInvoiceCreated'
          - $ref: '#/components/messages/PendingInvoiceUpdated'
  credit_note:
    description: Credit note lifecycle events.
    subscribe:
      operationId: receiveCreditNoteEvent
      message:
        oneOf:
          - $ref: '#/components/messages/CreditNoteCreated'
          - $ref: '#/components/messages/CreditNoteCreatedWithBackdating'
          - $ref: '#/components/messages/CreditNoteDeleted'
          - $ref: '#/components/messages/CreditNoteUpdated'
  transaction:
    description: Transaction lifecycle events.
    subscribe:
      operationId: receiveTransactionEvent
      message:
        oneOf:
          - $ref: '#/components/messages/TransactionCreated'
          - $ref: '#/components/messages/TransactionDeleted'
          - $ref: '#/components/messages/TransactionUpdated'
  payment:
    description: Payment, refund, and payment intent events.
    subscribe:
      operationId: receivePaymentEvent
      message:
        oneOf:
          - $ref: '#/components/messages/AuthorizationSucceeded'
          - $ref: '#/components/messages/AuthorizationVoided'
          - $ref: '#/components/messages/PaymentDueReminder'
          - $ref: '#/components/messages/PaymentFailed'
          - $ref: '#/components/messages/PaymentInitiated'
          - $ref: '#/components/messages/PaymentIntentCreated'
          - $ref: '#/components/messages/PaymentIntentUpdated'
          - $ref: '#/components/messages/PaymentRefunded'
          - $ref: '#/components/messages/PaymentSucceeded'
          - $ref: '#/components/messages/RefundInitiated'
  payment_source:
    description: Payment source (card, bank account, etc.) events.
    subscribe:
      operationId: receivePaymentSourceEvent
      message:
        oneOf:
          - $ref: '#/components/messages/CardAdded'
          - $ref: '#/components/messages/CardDeleted'
          - $ref: '#/components/messages/CardExpired'
          - $ref: '#/components/messages/CardExpiryReminder'
          - $ref: '#/components/messages/CardUpdated'
          - $ref: '#/components/messages/PaymentSourceAdded'
          - $ref: '#/components/messages/PaymentSourceDeleted'
          - $ref: '#/components/messages/PaymentSourceExpired'
          - $ref: '#/components/messages/PaymentSourceExpiring'
          - $ref: '#/components/messages/PaymentSourceLocallyDeleted'
          - $ref: '#/components/messages/PaymentSourceUpdated'
          - $ref: '#/components/messages/VirtualBankAccountAdded'
          - $ref: '#/components/messages/VirtualBankAccountDeleted'
          - $ref: '#/components/messages/VirtualBankAccountUpdated'
  payment_schedule:
    description: Payment schedule scheme and instance events.
    subscribe:
      operationId: receivePaymentScheduleEvent
      message:
        oneOf:
          - $ref: '#/components/messages/PaymentScheduleSchemeCreated'
          - $ref: '#/components/messages/PaymentScheduleSchemeDeleted'
          - $ref: '#/components/messages/PaymentSchedulesCreated'
          - $ref: '#/components/messages/PaymentSchedulesUpdated'
  gift:
    description: Gift subscription events.
    subscribe:
      operationId: receiveGiftEvent
      message:
        oneOf:
          - $ref: '#/components/messages/GiftCancelled'
          - $ref: '#/components/messages/GiftClaimed'
          - $ref: '#/components/messages/GiftExpired'
          - $ref: '#/components/messages/GiftScheduled'
          - $ref: '#/components/messages/GiftUnclaimed'
          - $ref: '#/components/messages/GiftUpdated'
  quote:
    description: Quote lifecycle events.
    subscribe:
      operationId: receiveQuoteEvent
      message:
        oneOf:
          - $ref: '#/components/messages/QuoteCreated'
          - $ref: '#/components/messages/QuoteDeleted'
          - $ref: '#/components/messages/QuoteUpdated'
  coupon:
    description: Coupon, coupon set, and coupon code events.
    subscribe:
      operationId: receiveCouponEvent
      message:
        oneOf:
          - $ref: '#/components/messages/CouponCreated'
          - $ref: '#/components/messages/CouponDeleted'
          - $ref: '#/components/messages/CouponUpdated'
          - $ref: '#/components/messages/CouponSetCreated'
          - $ref: '#/components/messages/CouponSetDeleted'
          - $ref: '#/components/messages/CouponSetUpdated'
          - $ref: '#/components/messages/CouponCodesAdded'
          - $ref: '#/components/messages/CouponCodesDeleted'
          - $ref: '#/components/messages/CouponCodesUpdated'
  item:
    description: Product catalog v2 item, item price, item family, and differential price events.
    subscribe:
      operationId: receiveItemEvent
      message:
        oneOf:
          - $ref: '#/components/messages/ItemCreated'
          - $ref: '#/components/messages/ItemDeleted'
          - $ref: '#/components/messages/ItemUpdated'
          - $ref: '#/components/messages/ItemFamilyCreated'
          - $ref: '#/components/messages/ItemFamilyDeleted'
          - $ref: '#/components/messages/ItemFamilyUpdated'
          - $ref: '#/components/messages/ItemPriceCreated'
          - $ref: '#/components/messages/ItemPriceDeleted'
          - $ref: '#/components/messages/ItemPriceUpdated'
          - $ref: '#/components/messages/ItemEntitlementsRemoved'
          - $ref: '#/components/messages/ItemEntitlementsUpdated'
          - $ref: '#/components/messages/ItemPriceEntitlementsRemoved'
          - $ref: '#/components/messages/ItemPriceEntitlementsUpdated'
          - $ref: '#/components/messages/AttachedItemCreated'
          - $ref: '#/components/messages/AttachedItemDeleted'
          - $ref: '#/components/messages/AttachedItemUpdated'
          - $ref: '#/components/messages/DifferentialPriceCreated'
          - $ref: '#/components/messages/DifferentialPriceDeleted'
          - $ref: '#/components/messages/DifferentialPriceUpdated'
          - $ref: '#/components/messages/PriceVariantCreated'
          - $ref: '#/components/messages/PriceVariantDeleted'
          - $ref: '#/components/messages/PriceVariantUpdated'
  feature:
    description: Entitlement feature lifecycle events.
    subscribe:
      operationId: receiveFeatureEvent
      message:
        oneOf:
          - $ref: '#/components/messages/FeatureActivated'
          - $ref: '#/components/messages/FeatureArchived'
          - $ref: '#/components/messages/FeatureCreated'
          - $ref: '#/components/messages/FeatureDeleted'
          - $ref: '#/components/messages/FeatureReactivated'
          - $ref: '#/components/messages/FeatureUpdated'
  entitlement_override:
    description: Customer-level entitlement override events.
    subscribe:
      operationId: receiveEntitlementOverrideEvent
      message:
        oneOf:
          - $ref: '#/components/messages/EntitlementOverridesAutoRemoved'
          - $ref: '#/components/messages/EntitlementOverridesRemoved'
          - $ref: '#/components/messages/EntitlementOverridesUpdated'
  order:
    description: Order and sales order events.
    subscribe:
      operationId: receiveOrderEvent
      message:
        oneOf:
          - $ref: '#/components/messages/OrderCancelled'
          - $ref: '#/components/messages/OrderCreated'
          - $ref: '#/components/messages/OrderDeleted'
          - $ref: '#/components/messages/OrderDelivered'
          - $ref: '#/components/messages/OrderReadyToProcess'
          - $ref: '#/components/messages/OrderReadyToShip'
          - $ref: '#/components/messages/OrderResent'
          - $ref: '#/components/messages/OrderReturned'
          - $ref: '#/components/messages/OrderUpdated'
          - $ref: '#/components/messages/SalesOrderCreated'
          - $ref: '#/components/messages/SalesOrderUpdated'
  contract_term:
    description: Subscription contract term events.
    subscribe:
      operationId: receiveContractTermEvent
      message:
        oneOf:
          - $ref: '#/components/messages/ContractTermCancelled'
          - $ref: '#/components/messages/ContractTermCompleted'
          - $ref: '#/components/messages/ContractTermCreated'
          - $ref: '#/components/messages/ContractTermRenewed'
          - $ref: '#/components/messages/ContractTermTerminated'
  business_entity:
    description: Business entity and hierarchy events.
    subscribe:
      operationId: receiveBusinessEntityEvent
      message:
        oneOf:
          - $ref: '#/components/messages/BusinessEntityCreated'
          - $ref: '#/components/messages/BusinessEntityDeleted'
          - $ref: '#/components/messages/BusinessEntityUpdated'
          - $ref: '#/components/messages/HierarchyCreated'
          - $ref: '#/components/messages/HierarchyDeleted'
  promotional_credits:
    description: Promotional credit ledger events.
    subscribe:
      operationId: receivePromotionalCreditsEvent
      message:
        oneOf:
          - $ref: '#/components/messages/PromotionalCreditsAdded'
          - $ref: '#/components/messages/PromotionalCreditsDeducted'
  unbilled_charges:
    description: Unbilled charge lifecycle events.
    subscribe:
      operationId: receiveUnbilledChargesEvent
      message:
        oneOf:
          - $ref: '#/components/messages/UnbilledChargesCreated'
          - $ref: '#/components/messages/UnbilledChargesDeleted'
          - $ref: '#/components/messages/UnbilledChargesInvoiced'
          - $ref: '#/components/messages/UnbilledChargesVoided'
  token:
    description: Payment token events (tokenization).
    subscribe:
      operationId: receiveTokenEvent
      message:
        oneOf:
          - $ref: '#/components/messages/TokenConsumed'
          - $ref: '#/components/messages/TokenCreated'
          - $ref: '#/components/messages/TokenExpired'
  voucher:
    description: Voucher events.
    subscribe:
      operationId: receiveVoucherEvent
      message:
        oneOf:
          - $ref: '#/components/messages/VoucherCreated'
          - $ref: '#/components/messages/VoucherCreateFailed'
          - $ref: '#/components/messages/VoucherExpired'
  tax_withheld:
    description: Tax withheld lifecycle events.
    subscribe:
      operationId: receiveTaxWithheldEvent
      message:
        oneOf:
          - $ref: '#/components/messages/TaxWithheldDeleted'
          - $ref: '#/components/messages/TaxWithheldRecorded'
          - $ref: '#/components/messages/TaxWithheldRefunded'
  rule:
    description: Rule lifecycle events.
    subscribe:
      operationId: receiveRuleEvent
      message:
        oneOf:
          - $ref: '#/components/messages/RuleCreated'
          - $ref: '#/components/messages/RuleDeleted'
          - $ref: '#/components/messages/RuleUpdated'
  usage:
    description: Usage metering events.
    subscribe:
      operationId: receiveUsageEvent
      message:
        oneOf:
          - $ref: '#/components/messages/AddUsagesReminder'
          - $ref: '#/components/messages/UsageFileIngested'
  purchase:
    description: Purchase events.
    subscribe:
      operationId: receivePurchaseEvent
      message:
        oneOf:
          - $ref: '#/components/messages/PurchaseCreated'
          - $ref: '#/components/messages/RecordPurchaseFailed'
  omnichannel:
    description: Omnichannel subscription and transaction events (Chargebee Omnichannel).
    subscribe:
      operationId: receiveOmnichannelEvent
      message:
        oneOf:
          - $ref: '#/components/messages/OmnichannelOneTimeOrderCreated'
          - $ref: '#/components/messages/OmnichannelOneTimeOrderItemCancelled'
          - $ref: '#/components/messages/OmnichannelSubscriptionCreated'
          - $ref: '#/components/messages/OmnichannelSubscriptionImported'
          - $ref: '#/components/messages/OmnichannelSubscriptionMovedIn'
          - $ref: '#/components/messages/OmnichannelSubscriptionItemCancellationScheduled'
          - $ref: '#/components/messages/OmnichannelSubscriptionItemCancelled'
          - $ref: '#/components/messages/OmnichannelSubscriptionItemChangeScheduled'
          - $ref: '#/components/messages/OmnichannelSubscriptionItemChanged'
          - $ref: '#/components/messages/OmnichannelSubscriptionItemDowngraded'
          - $ref: '#/components/messages/OmnichannelSubscriptionItemDunningExpired'
          - $ref: '#/components/messages/OmnichannelSubscriptionItemDunningStarted'
          - $ref: '#/components/messages/OmnichannelSubscriptionItemExpired'
          - $ref: '#/components/messages/OmnichannelSubscriptionItemGracePeriodExpired'
          - $ref: '#/components/messages/OmnichannelSubscriptionItemGracePeriodStarted'
          - $ref: '#/components/messages/OmnichannelSubscriptionItemPauseScheduled'
          - $ref: '#/components/messages/OmnichannelSubscriptionItemPaused'
          - $ref: '#/components/messages/OmnichannelSubscriptionItemReactivated'
          - $ref: '#/components/messages/OmnichannelSubscriptionItemRecovered'
          - $ref: '#/components/messages/OmnichannelSubscriptionItemRenewed'
          - $ref: '#/components/messages/OmnichannelSubscriptionItemResubscribed'
          - $ref: '#/components/messages/OmnichannelSubscriptionItemResumed'
          - $ref: '#/components/messages/OmnichannelSubscriptionItemScheduledCancellationRemoved'
          - $ref: '#/components/messages/OmnichannelSubscriptionItemScheduledChangeRemoved'
          - $ref: '#/components/messages/OmnichannelSubscriptionItemUpdated'
          - $ref: '#/components/messages/OmnichannelSubscriptionItemUpgraded'
          - $ref: '#/components/messages/OmnichannelTransactionCreated'
  site_signals:
    description: Site-wide signal events (alerts, dunning, MRR).
    subscribe:
      operationId: receiveSiteSignalEvent
      message:
        oneOf:
          - $ref: '#/components/messages/AlertStatusChanged'
          - $ref: '#/components/messages/DunningUpdated'
          - $ref: '#/components/messages/MrrUpdated'
components:
  securitySchemes:
    basicAuth:
      type: userPassword
      description: |
        Optional HTTP Basic Auth credentials configured on the webhook endpoint
        in the Chargebee site UI. Chargebee sends these credentials in the
        Authorization header on each webhook POST.
  schemas:
    EventSource:
      type: string
      description: Origin of the operation that produced the event.
      enum:
        - admin_console
        - api
        - bulk_operation
        - external_service
        - hosted_page
        - migration
        - portal
        - scheduled_job
        - system
    ApiVersion:
      type: string
      description: Indicates whether the event content follows v1 or v2 API structure.
      enum:
        - v1
        - v2
    WebhookStatus:
      type: string
      description: Delivery status for a webhook attempt.
      enum:
        - scheduled
        - succeeded
        - re_scheduled
        - failed
        - skipped
        - not_configured
    WebhookCall:
      type: object
      description: One row in the event.webhooks array; describes a webhook delivery attempt.
      properties:
        id:
          type: string
        webhook_status:
          $ref: '#/components/schemas/WebhookStatus'
        object:
          type: string
          enum: [webhook]
        webhook_name:
          type: string
    EventContent:
      type: object
      description: |
        Resource payload for the event. Chargebee places one or more resource
        objects (e.g. subscription, customer, invoice, transaction, credit_note,
        card, payment_source, coupon, item, item_price, quote, gift, order,
        unbilled_charge, business_entity, etc.) here, keyed by resource name.
        The exact set of keys depends on event_type. Full resource schemas are
        published in the Chargebee REST API reference and OpenAPI repository.
      additionalProperties: true
    Event:
      type: object
      description: |
        Chargebee Event envelope. Every webhook POST body has shape `{ id, ... ,
        event_type, content: { ... } }` with these fields.
      required:
        - id
        - occurred_at
        - source
        - event_type
        - api_version
        - content
      properties:
        id:
          type: string
          maxLength: 40
          description: Unique identifier for the event.
        occurred_at:
          type: integer
          format: int64
          description: UTC seconds at which the event occurred.
        source:
          $ref: '#/components/schemas/EventSource'
        user:
          type: string
          description: |
            Identifier of who triggered the event (email for admin_console,
            API key name for api, service name for external_service, etc.).
        webhook_status:
          $ref: '#/components/schemas/WebhookStatus'
        webhook_failure_reason:
          type: string
          description: Populated when a previous webhook delivery attempt failed.
        webhooks:
          type: array
          items:
            $ref: '#/components/schemas/WebhookCall'
        object:
          type: string
          enum: [event]
        api_version:
          $ref: '#/components/schemas/ApiVersion'
        event_type:
          type: string
          description: The specific event_type identifier.
        origin_user:
          type: string
          description: Optional email captured via the chargebee-event-origin-user custom header.
        content:
          $ref: '#/components/schemas/EventContent'
  messageTraits:
    EventEnvelopeTrait:
      headers:
        type: object
        properties:
          Content-Type:
            type: string
            enum: [application/json]
          User-Agent:
            type: string
            description: Chargebee user agent string.
          Authorization:
            type: string
            description: HTTP Basic credentials if configured for the webhook endpoint.
      contentType: application/json
  messages:
    # ---------- Customer ----------
    CustomerChanged:
      name: customer_changed
      title: customer_changed
      summary: A customer was changed.
      traits: [{ $ref: '#/components/messageTraits/EventEnvelopeTrait' }]
      payload: { $ref: '#/components/schemas/Event' }
    CustomerCreated:
      name: customer_created
      title: customer_created
      summary: A new customer was created.
      traits: [{ $ref: '#/components/messageTraits/EventEnvelopeTrait' }]
      payload: { $ref: '#/components/schemas/Event' }
    CustomerDeleted:
      name: customer_deleted
      title: customer_deleted
      summary: A customer was deleted.
      traits: [{ $ref: '#/components/messageTraits/EventEnvelopeTrait' }]
      payload: { $ref: '#/components/schemas/Event' }
    CustomerMovedIn:
      name: customer_moved_in
      title: customer_moved_in
      summary: A customer was moved into the site.
      traits: [{ $ref: '#/components/messageTraits/EventEnvelopeTrait' }]
      payload: { $ref: '#/components/schemas/Event' }
    CustomerMovedOut:
      name: customer_moved_out
      title: customer_moved_out
      summary: A customer was moved out of the site.
      traits: [{ $ref: '#/components/messageTraits/EventEnvelopeTrait' }]
      payload: { $ref: '#/components/schemas/Event' }
    CustomerBusinessEntityChanged:
      name: customer_business_entity_changed
      title: customer_business_entity_changed
      summary: A customer's business entity was changed.
      traits: [{ $ref: '#/components/messageTraits/EventEnvelopeTrait' }]
      payload: { $ref: '#/components/schemas/Event' }
    CustomerEntitlementsUpdated:
      name: customer_entitlements_updated
      title: customer_entitlements_updated
      summary: A customer's entitlements were updated.
      traits: [{ $ref: '#/components/messageTraits/EventEnvelopeTrait' }]
      payload: { $ref: '#/components/schemas/Event' }

    # ---------- Subscription ----------
    SubscriptionActivated:
      name: subscription_activated
      title: subscription_activated
      summary: Subscription moved out of trial into active state.
      traits: [{ $ref: '#/components/messageTraits/EventEnvelopeTrait' }]
      payload: { $ref: '#/components/schemas/Event' }
    SubscriptionActivatedWithBackdating:
      name: subscription_activated_with_backdating
      title: subscription_activated_with_backdating
      traits: [{ $ref: '#/components/messageTraits/EventEnvelopeTrait' }]
      payload: { $ref: '#/components/schemas/Event' }
    SubscriptionAdvanceInvoiceScheduleAdded:
      name: subscription_advance_invoice_schedule_added
      title: subscription_advance_invoice_schedule_added
      traits: [{ $ref: '#/components/messageTraits/EventEnvelopeTrait' }]
      payload: { $ref: '#/components/schemas/Event' }
    SubscriptionAdvanceInvoiceScheduleRemoved:
      name: subscription_advance_invoice_schedule_removed
      title: subscription_advance_invoice_schedule_removed
      traits: [{ $ref: '#/components/messageTraits/EventEnvelopeTrait' }]
      payload: { $ref: '#/components/schemas/Event' }
    SubscriptionAdvanceInvoiceScheduleUpdated:
      name: subscription_advance_invoice_schedule_updated
      title: subscription_advance_invoice_schedule_updated
      traits: [{ $ref: '#/components/messageTraits/EventEnvelopeTrait' }]
      payload: { $ref: '#/components/schemas/Event' }
    SubscriptionBusinessEntityChanged:
      name: subscription_business_entity_changed
      title: subscription_business_entity_changed
      traits: [{ $ref: '#/components/messageTraits/EventEnvelopeTrait' }]
      payload: { $ref: '#/components/schemas/Event' }
    SubscriptionCanceledWithBackdating:
      name: subscription_canceled_with_backdating
      title: subscription_canceled_with_backdating
      traits: [{ $ref: '#/components/messageTraits/EventEnvelopeTrait' }]
      payload: { $ref: '#/components/schemas/Event' }
    SubscriptionCancellationReminder:
      name: subscription_cancellation_reminder
      title: subscription_cancellation_reminder
      traits: [{ $ref: '#/components/messageTraits/EventEnvelopeTrait' }]
      payload: { $ref: '#/components/schemas/Event' }
    SubscriptionCancellationScheduled:
      name: subscription_cancellation_scheduled
      title: subscription_cancellation_scheduled
      traits: [{ $ref: '#/components/messageTraits/EventEnvelopeTrait' }]
      payload: { $ref: '#/components/schemas/Event' }
    SubscriptionCancelled:
      name: subscription_cancelled
      title: subscription_cancelled
      summary: Subscription was cancelled.
      traits: [{ $ref: '#/components/messageTraits/EventEnvelopeTrait' }]
      payload: { $ref: '#/components/schemas/Event' }
    SubscriptionChanged:
      name: subscription_changed
      title: subscription_changed
      traits: [{ $ref: '#/components/messageTraits/EventEnvelopeTrait' }]
      payload: { $ref: '#/components/schemas/Event' }
    SubscriptionChangedWithBackdating:
      name: subscription_changed_with_backdating
      title: subscription_changed_with_backdating
      traits: [{ $ref: '#/components/messageTraits/EventEnvelopeTrait' }]
      payload: { $ref: '#/components/schemas/Event' }
    SubscriptionChangesScheduled:
      name: subscription_changes_scheduled
      title: subscription_changes_scheduled
      traits: [{ $ref: '#/components/messageTraits/EventEnvelopeTrait' }]
      payload: { $ref: '#/components/schemas/Event' }
    SubscriptionCreated:
      name: subscription_created
      title: subscription_created
      summary: A new subscription was created.
      traits: [{ $ref: '#/components/messageTraits/EventEnvelopeTrait' }]
      payload: { $ref: '#/components/schemas/Event' }
    SubscriptionCreatedWithBackdating:
      name: subscription_created_with_backdating
      title: subscription_created_with_backdating
      traits: [{ $ref: '#/components/messageTraits/EventEnvelopeTrait' }]
      payload: { $ref: '#/components/schemas/Event' }
    SubscriptionDeleted:
      name: subscription_deleted
      title: subscription_deleted
      traits: [{ $ref: '#/components/messageTraits/EventEnvelopeTrait' }]
      payload: { $ref: '#/components/schemas/Event' }
    SubscriptionEntitlementsCreated:
      name: subscription_entitlements_created
      title: subscription_entitlements_created
      traits: [{ $ref: '#/components/messageTraits/EventEnvelopeTrait' }]
      payload: { $ref: '#/components/schemas/Event' }
    SubscriptionEntitlementsUpdated:
      name: subscription_entitlements_updated
      title: subscription_entitlements_updated
      traits: [{ $ref: '#/components/messageTraits/EventEnvelopeTrait' }]
      payload: { $ref: '#/components/schemas/Event' }
    SubscriptionItemsRenewed:
      name: subscription_items_renewed
      title: subscription_items_renewed
      traits: [{ $ref: '#/components/messageTraits/EventEnvelopeTrait' }]
      payload: { $ref: '#/components/schemas/Event' }
    SubscriptionMovedIn:
      name: subscription_moved_in
      title: subscription_moved_in
      traits: [{ $ref: '#/components/messageTraits/EventEnvelopeTrait' }]
      payload: { $ref: '#/components/schemas/Event' }
    SubscriptionMovedOut:
      name: subscription_moved_out
      title: subscription_moved_out
      traits: [{ $ref: '#/components/messageTraits/EventEnvelopeTrait' }]
      payload: { $ref: '#/components/schemas/Event' }
    SubscriptionMovementFailed:
      name: subscription_movement_failed
      title: subscription_movement_failed
      traits: [{ $ref: '#/components/messageTraits/EventEnvelopeTrait' }]
      payload: { $ref: '#/components/schemas/Event' }
    SubscriptionPauseScheduled:
      name: subscription_pause_scheduled
      title: subscription_pause_scheduled
      traits: [{ $ref: '#/components/messageTraits/EventEnvelopeTrait' }]
      payload: { $ref: '#/components/schemas/Event' }
    SubscriptionPaused:
      name: subscription_paused
      title: subscription_paused
      traits: [{ $ref: '#/components/messageTraits/EventEnvelopeTrait' }]
      payload: { $ref: '#/components/schemas/Event' }
    SubscriptionRampApplied:
      name: subscription_ramp_applied
      title: subscription_ramp_applied
      traits: [{ $ref: '#/components/messageTraits/EventEnvelopeTrait' }]
      payload: { $ref: '#/components/schemas/Event' }
    SubscriptionRampCreated:
      name: subscription_ramp_created
      title: subscription_ramp_created
      traits: [{ $ref: '#/components/messageTraits/EventEnvelopeTrait' }]
      payload: { $ref: '#/components/schemas/Event' }
    SubscriptionRampDeleted:
      name: subscription_ramp_deleted
      title: subscription_ramp_deleted
      traits: [{ $ref: '#/components/messageTraits/EventEnvelopeTrait' }]
      payload: { $ref: '#/components/schemas/Event' }
    SubscriptionRampDrafted:
      name: subscription_ramp_drafted
      title: subscr

# --- truncated at 32 KB (73 KB total) ---
# Full source: https://raw.githubusercontent.com/api-evangelist/chargebee/refs/heads/main/asyncapi/chargebee-asyncapi.yml