home / skills / plurigrid / asi / flowglad-integration
This skill automates zero-webhook billing for AI agents by generating polling-based checkout flows and ledger-driven usage metering.
npx playbooks add skill plurigrid/asi --skill flowglad-integrationReview the files below or copy the command above to add this skill to your agents.
---
name: flowglad-integration
description: Zero-webhook billing for AI agents
version: 1.0.0
trit: 1
---
# Flowglad Integration
> **Trit**: +1 (PLUS) - Generates billing flows
Zero-webhook billing platform for AI agent subscriptions.
## Overview
Resolves credit balance friction via polling-based checkout.
## GF(3) Triad
| Trit | Skill | Role |
|------|-------|------|
| -1 | amp-skill | Validates credit |
| 0 | unified-reafference | Coordinates state |
| +1 | flowglad-integration | Generates checkout |
## Patterns That Work
- Polling-based checkout (no webhooks)
- Usage metering via ledger
- Multi-tenant with RLS
## Patterns to Avoid
- Webhook-dependent flows
- Synchronous payment confirmation
## Related Skills
- amp-skill
- unified-reafference
- aptos-trading
## SDF Interleaving
This skill connects to **Software Design for Flexibility** (Hanson & Sussman, 2021):
### Primary Chapter: 10. Adventure Game Example
**Concepts**: autonomous agent, game, synthesis
### GF(3) Balanced Triad
```
flowglad-integration (−) + SDF.Ch10 (+) + [balancer] (○) = 0
```
**Skill Trit**: -1 (MINUS - verification)
### Secondary Chapters
- Ch4: Pattern Matching
### Connection Pattern
Adventure games synthesize techniques. This skill integrates multiple patterns.
This skill provides a zero-webhook billing integration for AI agents, enabling polling-based checkout and subscription management. It removes webhook dependency and resolves credit balance friction by using ledger metering and polling to confirm payments. The implementation targets multi-tenant deployments and enforces row-level security for tenant isolation. It is written in Python and designed to be embedded into agent billing workflows.
The integration generates checkout flows and monitors ledger entries to detect confirmed usage and payments via polling rather than webhooks. It validates credit and usage through a coordinated state system that ties invoices, ledger entries, and subscription records together. The skill exposes lightweight hooks for agents to request checkouts, poll for confirmation, and reconcile balances. Multi-tenant support is handled with RLS and per-tenant ledgers to prevent cross-tenant leakage.
How does polling avoid double charges?
Metering and ledger entries are idempotent; each usage record has a unique idempotency key and the ledger enforces single-apply semantics during reconciliation.
What if polling latency is unacceptable for my UX?
Tune polling intervals and use optimistic UI with clear state messaging. For critical flows, combine fast local credit checks with ledger-backed final confirmation.