Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
72 changes: 72 additions & 0 deletions .github/workflows/compatibility-matrix-validation.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,72 @@
name: Compatibility Matrix Validation

on:
pull_request:
branches: [main]
paths:
- 'docs/COMPATIBILITY_MATRIX.md'
- '.github/workflows/compatibility-matrix-validation.yml'
push:
branches: [main]
paths:
- 'docs/COMPATIBILITY_MATRIX.md'

jobs:
validate-compatibility-matrix:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4

- name: Validate Compatibility Matrix
run: |
echo "Validating compatibility matrix..."

# Check if the file exists
if [ ! -f "docs/COMPATIBILITY_MATRIX.md" ]; then
echo "::error::COMPATIBILITY_MATRIX.md not found"
exit 1
fi

# Check for required sections
required_sections=(
"## Payload Version Compatibility"
"## Delivery Adapter Compatibility"
"## Consumer Integration Compatibility"
"## Migration Guide"
"## CI Validation"
"## Support Policy"
)

for section in "${required_sections[@]}"; do
if ! grep -q "$section" docs/COMPATIBILITY_MATRIX.md; then
echo "::error::Missing required section: $section"
exit 1
fi
done

# Check for payload versions table
if ! grep -q "| Payload Version |" docs/COMPATIBILITY_MATRIX.md; then
echo "::error::Payload version table not found"
exit 1
fi

# Check for adapter table
if ! grep -q "| Adapter |" docs/COMPATIBILITY_MATRIX.md; then
echo "::error::Adapter table not found"
exit 1
fi

# Check for consumer integration table
if ! grep -q "| Integration Type |" docs/COMPATIBILITY_MATRIX.md; then
echo "::error::Consumer integration table not found"
exit 1
fi

# Check for CI Validation section content
if ! grep -q "This compatibility matrix is validated by CI" docs/COMPATIBILITY_MATRIX.md; then
echo "::error::CI Validation section content not found"
exit 1
fi

echo "✅ Compatibility matrix validation passed!"
64 changes: 64 additions & 0 deletions docs/COMPATIBILITY_MATRIX.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,64 @@
# Compatibility Matrix for Notification Consumers

This document provides a machine-readable compatibility matrix for Notify-Chain notification consumers. It identifies supported payload versions, delivery adapters, and consumer-facing compatibility expectations.

## Payload Version Compatibility

| Payload Version | Status | Supported Adapters | Notes |
|-----------------|--------|-------------------|-------|
| v1.0.0 | Stable | Webhook, Email, SMS, Push | Initial release with core notification features |
| v1.1.0 | Stable | Webhook, Email, SMS, Push | Added retry metadata and scheduling support |
| v1.2.0 | Beta | Webhook, Email, SMS, Push, Discord | Added Discord adapter (beta), event source field |

## Delivery Adapter Compatibility

| Adapter | Minimum Payload Version | Features | Configuration |
|---------|------------------------|----------|---------------|
| Webhook | v1.0.0 | Signature verification, retry, rate limiting | `WEBHOOK_URL`, `WEBHOOK_SECRET` |
| Email | v1.0.0 | HTML templates, attachments, BCC | SMTP or SendGrid configuration |
| SMS | v1.0.0 | Character limit checking, Unicode support | Twilio or Termii configuration |
| Push | v1.1.0 | FCM, APNs, silent notifications | Device token configuration |
| Discord | v1.2.0 (Beta) | Embeds, webhook URLs | Discord webhook URL (beta) |

## Consumer Integration Compatibility

| Integration Type | Minimum Version | Supported Protocols | Documentation |
|------------------|----------------|---------------------|---------------|
| Direct API | v1.0.0 | REST | [API.md](../listener/API.md) |
| Webhook Consumer | v1.0.0 | HTTP/HTTPS | [NOTIFICATION-FLOW.md](./NOTIFICATION-FLOW.md) |
| Email Client | v1.0.0 | SMTP | [LISTENER-CONFIGURATION.md](./LISTENER-CONFIGURATION.md) |
| SMS Client | v1.0.0 | Twilio/Termii API | [LISTENER-CONFIGURATION.md](./LISTENER-CONFIGURATION.md) |
| Push Client | v1.1.0 | FCM/APNs | [LISTENER-CONFIGURATION.md](./LISTENER-CONFIGURATION.md) |

## Environment Configuration

The following environment variables control notification delivery:

| Variable | Purpose | Default | Required |
|----------|---------|---------|----------|
| `STELLAR_NETWORK` | Stellar network label | `testnet` | Yes |
| `STELLAR_RPC_URL` | Soroban RPC endpoint | Testnet URL | Yes |
| `CONTRACT_ADDRESSES` | Contracts to monitor | None | Yes |
| `LOG_LEVEL` | Logging verbosity | `info` | No |

## CI Validation

This compatibility matrix is validated by CI to ensure:
- All listed adapters match the implementation in `.env.example`
- All environment variables are documented
- All documentation links are valid
- Breaking changes require a version bump

## Support Policy

- **Stable versions**: Supported for 12 months after release
- **Beta versions**: Supported for 3 months after release
- **End-of-life versions**: No longer supported, consumers should upgrade

## Questions?

For questions about compatibility, please:
1. Review the [API Documentation](../listener/API.md)
2. Check the [Listener Configuration](./LISTENER-CONFIGURATION.md)
3. Open an issue in the repository
4.