Skip to content

feat(providers): add provider capability metadata and feature degradation (#708) - #740

Open
ravendevhub wants to merge 1 commit into
Core-Foundry:mainfrom
ravendevhub:feat/provider-capabilities-708
Open

feat(providers): add provider capability metadata and feature degradation (#708)#740
ravendevhub wants to merge 1 commit into
Core-Foundry:mainfrom
ravendevhub:feat/provider-capabilities-708

Conversation

@ravendevhub

Copy link
Copy Markdown

Summary

Resolves #708 by introducing a provider capability metadata and degradation engine (listener/src/providers/provider-capabilities.ts) allowing notification providers to declare supported features (markdown, embeds, attachments) and automatically degrading unsupported elements gracefully without hard dependencies in the core pipeline.

Changes

  1. Capability Taxonomy & Degradation Engine (listener/src/providers/provider-capabilities.ts):
    • Defines NotificationCapability enum (RICH_FORMATTING, EMBEDDED_LINKS, ATTACHMENTS, BATCHING, etc.).
    • Implements adaptPayloadForProvider to automatically downgrade markdown to plaintext and expand action buttons to raw URLs for constrained providers.
    • Built-in capability profiles for Discord, Generic Webhooks, and SMS.
  2. Automated Unit Tests (listener/src/providers/provider-capabilities.test.ts):
    • Tests rich rendering, markdown stripping, and attachment notice fallbacks.
  3. Documentation (docs/PROVIDER_CAPABILITIES.md):
    • Complete specification of provider capability flags and degradation rules.

Acceptance Criteria

  • Providers can declare supported capabilities.
  • Unsupported features are handled gracefully.
  • The core notification pipeline does not depend on a specific provider.

…tion (Core-Foundry#708)

- Define NotificationCapability taxonomy (rich formatting, links, attachments, batching)
- Implement adaptPayloadForProvider engine with graceful degradation for unsupported features
- Decouple core notification pipeline from destination-specific formatting
- Add test coverage in provider-capabilities.test.ts and docs in docs/PROVIDER_CAPABILITIES.md
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add Provider Capability Metadata

1 participant