Repository navigation
PushSubscription
Viames Marino edited this page Feb 23, 2026
·
1 revision
Pair\Models\PushSubscription is the ActiveRecord model for push_subscriptions.
It stores endpoint and key material used by Web Push delivery.
-
userId(nullable for guests) endpointp256dhauthuserAgentrevokedAtlastSeenAtcreatedAtupdatedAt
Usually accessed through SubscriptionRepository:
$subs = (new \Pair\Push\SubscriptionRepository())->listByUser($userId);Or with ActiveRecord query helpers when needed.
- datetime and integer fields are auto-cast in
_init(). - Repository layer is preferred for business operations.
See also: SubscriptionRepository, Notification, PushDispatcher.
Home · Setup · Configuration
Build with Pair 4
- Generator
- Controllers and responses
- Read models
- ActiveRecord and queries
- Forms and validation
- PairUI.js and HTML fragments
APIs and authentication
- API guide and CRUD
- Middleware and rate limits
- Users, sessions, and ACL
- Passkeys and social login
- Native mobile setup
Integrate and operate
- Integrations
- Runtime extensions and adapter keys
- Cache and cache stores
- Logs and observability
- PWA and push
- Packages and distribution
- Upgrade to v4