mtok-relay 0.1.1 → 0.1.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/LICENSE ADDED
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2026 Roy Ashbrook
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
package/README.md ADDED
@@ -0,0 +1,12 @@
1
+ # mtok-relay
2
+
3
+ Reference seller relay for [mtok.market](https://mtok.market). Run with:
4
+
5
+ npx mtok-relay --offer <id> --model <id> --upstream <url>
6
+
7
+
8
+ ---
9
+
10
+ Read-only public mirror. The source of truth is the private mtok.market
11
+ monorepo; this repo is synced automatically. Do not open pull requests here.
12
+ Home: https://mtok.market
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env node
2
- // GENERATED by scripts/build-relay-bundle.mjs from relay/mtok-relay.mjs — do not edit by hand.
2
+ // GENERATED from mtok-relay.mjs — do not edit by hand.
3
3
 
4
4
  // mtok-relay.mjs
5
5
  import http from "node:http";
@@ -4643,7 +4643,7 @@ function privateKeyToAccount(privateKey, options = {}) {
4643
4643
  };
4644
4644
  }
4645
4645
 
4646
- // ../api/src/core/errors.js
4646
+ // core/errors.js
4647
4647
  function apiError(status, code, message, details) {
4648
4648
  const err = new Error(message);
4649
4649
  err.status = status;
@@ -4652,7 +4652,7 @@ function apiError(status, code, message, details) {
4652
4652
  return err;
4653
4653
  }
4654
4654
 
4655
- // ../api/src/core/onchain.js
4655
+ // core/onchain.js
4656
4656
  var TRANSFER_TOPIC = "0xddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef";
4657
4657
  var topicToAddress = (topic) => "0x" + String(topic).slice(-40).toLowerCase();
4658
4658
  var lc = (a) => String(a || "").toLowerCase();
package/package.json CHANGED
@@ -1,23 +1,46 @@
1
1
  {
2
2
  "name": "mtok-relay",
3
- "version": "0.1.1",
3
+ "version": "0.1.2",
4
4
  "description": "Reference seller relay for mtok.market — accepts on-chain-prepaid chunk draws and serves inference from an upstream you control. Run with: npx mtok-relay --offer <id> --model <id> --upstream <url>.",
5
5
  "type": "module",
6
- "bin": { "mtok-relay": "dist/mtok-relay.mjs" },
7
- "files": ["dist"],
8
- "engines": { "node": ">=20" },
6
+ "bin": {
7
+ "mtok-relay": "dist/mtok-relay.mjs"
8
+ },
9
+ "files": [
10
+ "dist"
11
+ ],
12
+ "engines": {
13
+ "node": ">=20"
14
+ },
9
15
  "homepage": "https://mtok.market",
10
- "keywords": ["mtok", "ai", "inference", "tokens", "marketplace", "seller", "relay", "base", "usdc"],
11
- "publishConfig": { "access": "public" },
16
+ "keywords": [
17
+ "mtok",
18
+ "ai",
19
+ "inference",
20
+ "tokens",
21
+ "marketplace",
22
+ "seller",
23
+ "relay",
24
+ "base",
25
+ "usdc"
26
+ ],
27
+ "publishConfig": {
28
+ "access": "public"
29
+ },
12
30
  "license": "MIT",
13
31
  "scripts": {
14
- "build:relay": "node ../scripts/build-relay-bundle.mjs",
15
- "prepublishOnly": "node ../scripts/build-relay-bundle.mjs"
32
+ "build:relay": "node build-relay-bundle.mjs",
33
+ "prepublishOnly": "node build-relay-bundle.mjs"
16
34
  },
17
35
  "devDependencies": {
18
- "viem": "^2.0.0"
36
+ "viem": "^2.0.0",
37
+ "esbuild": "^0.28.1"
19
38
  },
20
39
  "overrides": {
21
40
  "ws": "^8.21.0"
41
+ },
42
+ "repository": {
43
+ "type": "git",
44
+ "url": "git+https://github.com/mtok-market/relay.git"
22
45
  }
23
46
  }