Skip to main content
Pylva is the usage and cost ledger upstream of billing. Your app reports raw usage. Pylva prices it on the server. Pylva can create reviewable invoice records from customer usage and pricing. Stripe handles payment collection and hosted invoice delivery after you connect Stripe.

What Pylva provides

Pylva connects agent telemetry to billing operations:
  • Customer-level usage and cost records.
  • Server-side pricing for LLM models and non-LLM metrics.
  • Draft invoice records for a customer and billing period.
  • Invoice review before a finalized invoice is sent.
  • Stripe Connect handoff for finalized invoices.
  • Customer portal visibility when you choose to share usage or invoice information.
Pylva is not a payment processor, tax system, accounting system, collections system, or Stripe replacement.

Workflow

  1. Track usage with the SDK using stable customer_id and step values.
  2. Configure pricing for LLM models and non-LLM metrics.
  3. Review unknown pricing before billing.
  4. Generate draft invoices for a customer and billing period.
  5. Review line items, pricing version, excluded unpriced usage, and invoice status.
  6. Finalize the invoice through the connected Stripe account.
  7. Share customer-facing portal access when customers need usage visibility.

Unknown pricing

Unpriced usage is excluded from invoices until pricing is configured, so review unknown pricing before billing customers. This prevents a draft invoice from including a source whose price is not known yet. It also means draft invoice totals can be lower than the customer actually consumed if pricing gaps are still open. Before finalizing an invoice, review:
  • Missing LLM model pricing.
  • Missing non-LLM metric pricing.
  • Unexpected metric names.
  • The billing period and customer.
  • The pricing version used for the invoice.

Customer portal

The customer portal gives end-users visibility into approved usage and invoice information when you choose to share it. Use portal links when customers need to inspect usage, current-period cost, invoice details, or budget progress without getting access to the builder dashboard. For portal access, visibility, and safe sharing details, see Customer Portal.

Safe billing checklist

  • Use opaque, stable customer identifiers.
  • Keep metric names stable before pricing them.
  • Configure pricing before relying on margin or invoice totals.
  • Review unknown pricing tasks before sending invoices.
  • Review draft invoices before finalization.
  • Connect Stripe only when you are ready for Stripe to handle invoice delivery and payment collection.