Skip to content

feat: add creator and protocol fee split logic with tests#7

Merged
Chucks1093 merged 1 commit into
accesslayerorg:mainfrom
wheval:feat/creator-logic
Mar 25, 2026
Merged

feat: add creator and protocol fee split logic with tests#7
Chucks1093 merged 1 commit into
accesslayerorg:mainfrom
wheval:feat/creator-logic

Conversation

@wheval

@wheval wheval commented Mar 24, 2026

Copy link
Copy Markdown
Contributor

Summary

Closes #4

  • Add fee module with FeeConfig (creator_bps, protocol_bps) and compute_fee_split for creator/protocol fee calculation
  • Add DataKey::FeeConfig, set_fee_config, get_fee_config, and compute_fees_for_payment to creator-keys contract
  • Add unit tests for fee split math and integration tests for contract methods
  • Add docs/fee-assumptions.md documenting rounding rules, validation, overflow limits, and client/server integration notes

Testing

  • cargo fmt --all -- --check
  • cargo clippy --workspace --all-targets -- -D warnings
  • cargo test --workspace

Checklist

  • Linked issue or backlog item
  • Contract behavior and invariants are described clearly
  • Docs updated if contract interfaces or workflows changed
  • Scope stays limited to one contract concern

@drips-wave

drips-wave Bot commented Mar 24, 2026

Copy link
Copy Markdown

@wheval Great news! 🎉 Based on an automated assessment of this PR, the linked Wave issue(s) no longer count against your application limits.

You can now already apply to more issues while waiting for a review of this PR. Keep up the great work! 🚀

Learn more about application limits

@Chucks1093 Chucks1093 merged commit 38b340c into accesslayerorg:main Mar 25, 2026
1 check passed
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 creator and protocol fee split logic

2 participants