You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Feature Request: CBC event handling - CloudEvent parsing, dispatch, and feature status API #412
The cbc module added in v0.59.0 covers the pull side of the CBC integration: fetching tenant configuration on demand. However, CBC also pushes CloudEvents to application or agent webhook endpoints whenever configuration changes or AI features are toggled. Currently there is no SDK support for receiving, parsing, validating, or dispatching these events.
Without SDK support, every application/agent team must:
Manually parse raw CloudEvent payloads from incoming HTTP requests
Validate the type, specversion, and data fields themselves
Route events to the appropriate handler
There is also no way to query the current feature activation state via CBCClient, meaning applications cannot check feature status without implementing a separate API call.
Propose a Solution
Two additions to the existing sap_cloud_sdk.cbc module:
1. Event handler API
A lightweight event handler that registers callbacks by event type, parses incoming CloudEvents into typed CBC event objects, and dispatches them to the appropriate callback.
Three event types to support:
cbc.notification.consumptionversion.created
cbc.notification.consumptionversion.updated
cbc.notification.feature.activation.v1
Proposed API sketch:
fromsap_cloud_sdkimportcbchandler=cbc.CBCEventHandler()
defhandle_cv_change(event: cbc.ConsumptionVersionEvent) ->None:
# event.app_tenant_id, event.consumption_version_id
...
defhandle_features(event: cbc.FeatureActivationEvent) ->None:
# event.features: list[cbc.FeatureStatus]forfinevent.features:
print(f.feature_id, f.is_enabled())
handler.on_consumption_version_event(handle_cv_change)
handler.on_feature_activation_event(handle_features)
# In your web framework's webhook route:handler.handle_request(request.headers, request.body)
CBCEventHandler.handle_request(headers, body) parses the incoming CloudEvent, validates type, and routes to the registered callback. Raises CBCEventError (subclass of CBCError) on malformed envelopes.
2. Feature status pull API on CBCClient
v0.59.0 introduced CBCClient with methods to pull business configuration from CBC. AI feature status was out of scope at the time. This adds get_feature_statuses() to complete the client.
Each team parses events themselves: duplicated boilerplate with no consistency.
Generic CloudEvents library only: cloudevents Python SDK handles the envelope but provides no CBC-specific dispatch, typed models, or integration with CBCClient.
Affected Development Phase
Development
Impact
Impaired
Timeline
Active development is underway. I am willing to work on this and open a pull request once the issue is approved.
Raised PR #422. I have run the /review-pr and /security-review skills. Both pass clean. I have also run the updated SDK against a real demo agent which is integrated with CBC. Evidence of test results and skill reports are provided in the PR description and PR comment respectively.
Activity
NicoleMGomes commentedon Oct 21, 2026
Hi,
The contribution can proceed. Please share the PR with us only when all checks are ok.
Thank you,
Nicole Gomes
soumyadey commentedon Oct 22, 2026
Hi @NicoleMGomes ,
Raised PR #422. I have run the
/review-prand/security-reviewskills. Both pass clean. I have also run the updated SDK against a real demo agent which is integrated with CBC. Evidence of test results and skill reports are provided in the PR description and PR comment respectively.Thanks,
Soumya Dey