sub2
  • sub2 protocol
  • Concepts
    • Subscription
    • Fees
    • Fee auction
    • Sponsored subscriptions
    • Processors
  • Deployments
  • SDK
    • Query subscriptions
    • Listen for incoming subscriptions
    • Listen for canceled subscriptions
    • Listen for incoming payments
    • Sponsor subscriptions
    • Check if user is a payed subscriber
    • Cancel subscription
    • Process payments
    • Query active subscriptions to recipient
    • Query active subscriptions from sender
  • Popup integration
  • Become a payment processor
  • Technical Reference
  • DAO
Powered by GitBook
On this page
  1. SDK

Query active subscriptions from sender

PreviousQuery active subscriptions to recipientNextPopup integration

Last updated 11 months ago

Besides the ability to query arbitrary subscriptions as seen , sub2-sdk also supports querying active subscriptions with a given sender.

const subscriptions: Subscription[] = await sub2SDK.getActiveSubscriptionsFromSender(sender);

Here, sender is of type 0x${string}. The function only returns active subscriptions which means subscriptions that are on cooldown or in auction mode.

here