Skip to content

Latest commit

 

History

1 Commit

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 

Repository files navigation

ucashpay-fastapi

Minimal FastAPI example for U.CASH Pay. Client-side pay link + server-side tracked checkout. Non-custodial.

Run

pip install -r requirements.txt
export UCASH_CLOUD_TOKEN=your_store_cloud_token
uvicorn app:app --reload   # http://localhost:8000

Routes

  • GET /pay?amount=10&currency=USD&title=Pro+plan -> 302 to hosted checkout (client-side embed link).
  • POST /api/checkout JSON {amount, currency, external_reference, title, redirect} -> {ok, payment_url} (server-side create-transaction, idempotent).

Set up your pay.u.cash account

  1. Sign up at pay.u.cash, click the verification email link.
  2. Set receive addresses under Settings -> Addresses (raw, ENS, UD, or FIO).
  3. Create a store under Account -> Stores, copy its Store Cloud Token.
  4. For cards, connect your own Stripe under Settings -> Payment processors.

License: MIT.

About

FastAPI example for U.CASH Pay: client-side pay link + server-side checkout. Non-custodial.

Topics

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages