8000 GitHub - benjaminkincses/mintscope: Offline compatibility checks for Cashu mint and melt routes using a public mint information snapshot. · GitHub
[go: up one dir, main page]

Skip to content
benjaminkincsesPublic

About

Offline compatibility checks for Cashu mint and melt routes using a public mint information snapshot.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Latest commit

 

History

1 Commit

Folders and files

Repository files navigation

Mintscope

Mintscope answers one question about a Cashu mint. Given the mint's public information snapshot, does it advertise the requested direction, payment method, unit and amount? The page displays the matching rows and their inclusive bounds so you can check the answer yourself.

Run it

Open index.html in a browser with JavaScript enabled. All inspection runs on the device. The bundled fictional snapshots work offline. You can also paste the JSON from a mint's public GET /v1/info endpoint.

  1. Try the default minting example with method bolt11, unit sat and amount 500. The sample advertises 10 through 5000 sat.
  2. Change the amount to 5001. The matching row remains visible, and the verdict changes to “Outside advertised limits.”
  3. Load “Melting paused” to see how an explicit disabled flag takes precedence. Choose “Missing mint settings” to see an example where the available evidence is insufficient.

Enter the integer amount in the unit shown by the mint. Include only public metadata. Results describe the supplied snapshot. Availability, fees, authentication requirements and the acceptance of a particular quote depend on the mint. The inspector never requests a quote, opens a wallet or transfers funds.

Build and test

Node.js 22 or newer is sufficient. No packages or network connection are required.

node build.mjs
node --test engine.test.mjs

build.mjs embeds engine.mjs in shell.html and writes index.html. The ZIP includes the built page, both inputs, the build script, the tests and the MIT license. The hosted download link serves /mintscope-source.zip. When opened from disk, the footer lets you save a copy of the self-contained HTML.

What the engine checks

Minting uses NUT-04, melting uses NUT-05 and each operation has its own method and unit pairs. The inspector matches the exact pair. Missing bounds leave that side of the range unspecified. Conflicting results across duplicate rows, malformed bounds or an unclear enabled state produce “Insufficient evidence.” The page does not convert currencies or estimate fees.

The tests cover inclusive limits, missing limits, conflicting duplicates, malformed rows, direction and unit matching, and rejection of private fields. All fixtures are synthetic.

Protocol references

Released under the MIT License. See LICENSE.

About

Offline compatibility checks for Cashu mint and melt routes using a public mint information snapshot.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages

0