python_outbox_core.adapters.examples.kong_simple¶
Minimal Kong AI Gateway adapter example.
EDUCATIONAL EXAMPLE - NOT production-ready. For production use: python-kong-integration package.
Shows how to extend CloudEventsFormatter for Kong AI Gateway.
Classes¶
Example: Kong AI Gateway CloudEvents formatter. |
Module Contents¶
- class python_outbox_core.adapters.examples.kong_simple.KongSimpleFormatter(source: str, kong_namespace: str = 'default', consumer_group: str = 'default', rate_limit_tier: str = 'standard')¶
Bases:
python_outbox_core.formatters.CloudEventsFormatterExample: Kong AI Gateway CloudEvents formatter.
Extends CloudEventsFormatter with Kong-specific metadata (namespace, consumer group, rate limit tier).
- Example:
>>> formatter = KongSimpleFormatter( ... source="my-service", ... kong_namespace="production" ... ) >>> formatted = formatter.format(event)
- kong_namespace = 'default'¶
- consumer_group = 'default'¶
- rate_limit_tier = 'standard'¶
- enrich_metadata(event_data: Dict[str, Any]) Dict[str, Any]¶
Add Kong-specific metadata to CloudEvent.