Back to portfolio

UCL PRODUCT / WORKING LOCAL SANDBOX

An API launch kit.
Built around trust in every call.

Pratinidhi explores how an API provider can give AI applications paid access to a useful service, while making usage, credit and failures understandable.

TypeScriptNext.jsPostgreSQLRedis

Product experiment, not a production payment service. Screens show a running local application with synthetic requests and test credit.

ONE REQUEST. FOLLOW THE CREDIT.

Watch a call
earn its charge.

A request goes out. Credit waits.
Only a successful result gets charged.

PRODUCT WALKTHROUGH / TEST DATA
AI AGENT 01
Agent workspace
Check this invoice’s status.
Calling Invoice status API
PRATINIDHI 02
Ready for the call
Request ID Spend limit
AGENT TEST CREDIT INR
₹20.00balance
₹0.00 held · ₹20.00 available
₹1.50
PROVIDER API 03
Sample endpoint
Invoice status₹1.50 / successful call
01An agent asks for a result.
18-second illustrated loop

Illustrated from the launch-kit sandbox: ₹20 test credit, ₹1.50 per call, modeled 200 / 502 responses. This is not a live API connection or payment. Each loop resets the same example.

IN EVERYDAY LANGUAGE

A small balance.
A clear record.

Imagine a business offers an API: a service another application can ask for information. Charging for each useful request sounds simple, until a request fails, gets retried or exceeds a budget.

This sandbox makes those situations visible. A provider sets a sample service name and price. An agent receives test credit. You can then run a successful call, deliberately fail one, repeat a request and inspect what happened to the balance.

The aim is not another checkout screen. It is a clearer relationship between a request, its result and the charge attached to it.

THE WIDER LOCAL PRODUCT

Give the provider
a place to operate.

These genuine screenshots show the wider application running locally: provider pricing, agent credit and billing records. The focused launch-kit experiment described below is a separate testing journey.

Demonstration only: company names, accounts and balances are synthetic. “Live”, “Paid”, UPI/Razorpay and invoice labels belong to local test-mode screens using payment stand-ins. No actual payment or compliance certification is represented.

DESIGNED AROUND THE EDGE CASES

Success is only
one of the paths.

A useful response

The success fixture commits a test-credit charge and records its ledger entries.

A failed request

The failure fixture releases reserved credit instead of charging for an unsuccessful result.

The same request again

A duplicate request ID is refused without another charge in this sandbox journey.

A spending boundary

A monthly spending cap can refuse a new paid call. Setting the cap to zero pauses paid calls.

These are exercised sandbox behaviors, not a guarantee of distributed exactly-once processing, production resilience or commercial billing accuracy.

FOR TECHNICAL READERS

More than
a front-end demo.

The Next.js interface talks to an isolated server adapter. The experiment uses the existing MeterCore request lifecycle, Redis reservations and a PostgreSQL-backed ledger. Successful fixtures commit a charge; failed fixtures release the reservation.

Amounts are represented in integer paise rather than floating-point rupees. The sandbox settles ledger entries synchronously and pauses the session if settlement fails. That deliberate simplification is different from proving a production asynchronous billing pipeline.

Session and data boundaries

The local experiment uses dedicated sandbox stores, short-lived sessions and synthetic provider/agent records. A server-side key is not exposed in the visitor interface. Sessions and history have bounded lifetimes; this is a supervised demonstration, not a public multi-tenant service.

How the India Toolkit fits

The India Toolkit is a related TypeScript/MCP integration surface for Indian business utilities. It is distinct from the provider-facing launch-kit experiment shown here. Format validation is not government verification, and the presence of an integration does not establish regulatory compliance.

WHAT IS BUILT / WHAT COMES NEXT

Evidence first.
Claims later.

Working locally

Provider setup, test-credit allocation, synthetic request outcomes, duplicate protection, spending controls and backend ledger inspection.

Still to validate

Real provider integrations, live payments, production onboarding, operational security, deployment resilience and commercial demand. No compliance certification, scale benchmark or live-customer outcome is claimed.

Smith’s role: shaping and building the product experiment, connecting the interface to the metering and ledger workflow, and making its boundaries explicit.

Discuss a similar product challenge