Description
The asset-issuance template deploys custom Stellar assets. Add a compliance checking service that verifies assets against a configurable blocklist and propagates compliance flags (KYC required, restricted jurisdiction) to the generated template configuration.
Requirements and Context
- Check asset issuer against a configurable blocklist stored in Supabase
- Check jurisdiction restrictions: some assets blocked in specific regions
- Propagate compliance flags to the generated template as environment variables
- Flag propagation must not block deployment — only add warnings to deployment log
Suggested Execution
Branch: feat/stellar-asset-compliance-checking
Implement Changes
- Create
asset-compliance.service.ts in apps/backend/src/services/
- Add
asset_compliance_rules Supabase table with issuer, region, and flag columns (migration)
- Integrate compliance check into the deployment pipeline after asset pair validation
- Add tests for blocklist match, jurisdiction restriction, and flag propagation
Test and Commit
Run pnpm test -- asset-compliance and confirm blocklist enforcement and flag propagation tests pass.
Example Commit Message
feat(compliance): add asset compliance checking service with regulatory flag propagation
Co-authored-by: <your-name>
Guidelines
- Branch off
main, keep PRs focused on one issue
- All new code must include unit or integration tests
- Ensure
pnpm lint and pnpm typecheck pass before review
- Link this issue in your PR description
- Request review from at least one maintainer before merging
Description
The asset-issuance template deploys custom Stellar assets. Add a compliance checking service that verifies assets against a configurable blocklist and propagates compliance flags (KYC required, restricted jurisdiction) to the generated template configuration.
Requirements and Context
Suggested Execution
Branch:
feat/stellar-asset-compliance-checkingImplement Changes
asset-compliance.service.tsinapps/backend/src/services/asset_compliance_rulesSupabase table with issuer, region, and flag columns (migration)Test and Commit
Run
pnpm test -- asset-complianceand confirm blocklist enforcement and flag propagation tests pass.Example Commit Message
Guidelines
main, keep PRs focused on one issuepnpm lintandpnpm typecheckpass before review