Skip to content

Trac-Systems/trac-dapp-example

Repository files navigation

Tuxedex (Next.js)

This dapp talks to a trac-peer HTTP RPC (default http://127.0.0.1:5001/v1) and uses the TAP wallet browser extension for account + signing.

Configure peer RPC

The app server proxies requests to trac-peer via environment variables:

UPSTREAM_PROTOCOL=http
UPSTREAM_HOST=127.0.0.1
UPSTREAM_PORT=5001
UPSTREAM_PREFIX=/v1

Run

npm install
npm run dev

Peer endpoints used

  • Contract interface: GET /v1/contract/schema
  • Contract tx flow:
    • GET /v1/contract/nonce
    • POST /v1/contract/tx/prepare
    • POST /v1/contract/tx (sim: true then sim: false)
  • State (Dex collection): GET /v1/state?key=app/tuxedex/<pubKeyHex>&confirmed=false (legacy key from the current contract)

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 2

  •  
  •