Skip to content

feat(recurring): add 0.2.0 admit and revoke cycle helpers - #1766

Merged
LeoSlrRf merged 2 commits into
masterfrom
feat/req-429-lib-admit-revoke
Aug 31, 2026
Merged

feat(recurring): add 0.2.0 admit and revoke cycle helpers#1766
LeoSlrRf merged 2 commits into
masterfrom
feat/req-429-lib-admit-revoke

Conversation

@LeoSlrRf

@LeoSlrRf LeoSlrRf commented Aug 25, 2026

Copy link
Copy Markdown
Contributor

Add admitCycles and revokeCycles support for ERC20 Recurring Payment Proxy v0.2.0

Exposes two new relayer-role functions from the 0.2.0 recurring payment proxy contract:

  • admitCycles / encodeAdmitCycles — allows a relayer to admit specific cycles (identified by a bitmask) so that a subscriber can self-trigger them.
  • revokeCycles / encodeRevokeCycles — allows a relayer to revoke previously admitted cycles without affecting relayer-initiated triggers.

Both functions accept a scheduleKey and a mask (BigNumberish), and the encode* variants produce calldata without requiring a deployed proxy address. The async variants resolve the proxy address from the known deployment on the target network and throw if none is found.

LeoSlrRf commented Aug 25, 2026

Copy link
Copy Markdown
Contributor Author

@greptile-apps

greptile-apps Bot commented Aug 25, 2026

Copy link
Copy Markdown
Contributor

Greptile Summary

The PR adds calldata encoders and signer-based transaction helpers for admitting and revoking cycles through ERC20 Recurring Payment Proxy v0.2.0.

  • Adds encodeAdmitCycles and admitCycles.
  • Adds encodeRevokeCycles and revokeCycles.
  • Adds unit coverage for encoding, missing deployments, and transaction submission.

Confidence Score: 5/5

The PR appears safe to merge because no blocking failure remains.

No blocking failure remains.

Important Files Changed

Filename Overview
packages/payment-processor/src/payment/erc20-recurring-payment-proxy.ts Adds v0.2.0 admit/revoke calldata encoding and transaction-submission helpers using the existing proxy address and sender utilities.
packages/payment-processor/test/payment/erc-20-recurring-payment.test.ts Adds unit tests for the new encoding and submission helpers.

Reviews (2): Last reviewed commit: "test(recurring): use derived schedule ke..." | Re-trigger Greptile

Comment thread packages/payment-processor/test/payment/erc-20-recurring-payment.test.ts Outdated
@LeoSlrRf
LeoSlrRf marked this pull request as ready for review August 25, 2026 13:18
@LeoSlrRf
LeoSlrRf requested review from a team, MantisClone and bassgeta and removed request for a team August 25, 2026 13:18

@MantisClone MantisClone left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Approved.

These helpers correctly expose the new admission and revocation calls without adding client-side authority: the contract still enforces the relayer role, and callers supply the contract-derived schedule key rather than treating scheduleId as the key.

LeoSlrRf commented Aug 31, 2026

Copy link
Copy Markdown
Contributor Author

Merge activity

  • Aug 31, 8:49 AM UTC: A user started a stack merge that includes this pull request via Graphite.
  • Aug 31, 9:23 AM UTC: Graphite rebased this pull request as part of a merge.
  • Aug 31, 9:37 AM UTC: @LeoSlrRf merged this pull request with Graphite.

@LeoSlrRf
LeoSlrRf changed the base branch from feat/req-429-lib-cancel-hash-sign to graphite-base/1766 August 31, 2026 09:06
@LeoSlrRf
LeoSlrRf changed the base branch from graphite-base/1766 to master August 31, 2026 09:21
@LeoSlrRf
LeoSlrRf force-pushed the feat/req-429-lib-admit-revoke branch from 127aba5 to e2afaca Compare August 31, 2026 09:22
@LeoSlrRf
LeoSlrRf merged commit e04f81c into master Aug 31, 2026
9 checks passed
@LeoSlrRf
LeoSlrRf deleted the feat/req-429-lib-admit-revoke branch August 31, 2026 09:37
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.

3 participants