{"_id":"@agentpay-sui/gateway","name":"@agentpay-sui/gateway","dist-tags":{"latest":"0.1.0"},"versions":{"0.1.0":{"name":"@agentpay-sui/gateway","version":"0.1.0","type":"module","main":"./dist/server.js","types":"./dist/server.d.ts","exports":{".":{"types":"./dist/server.d.ts","import":"./dist/server.js"}},"bin":{"agentpay-gateway":"dist/server.js"},"publishConfig":{"access":"public"},"dependencies":{"express":"^5.2.1","@agentpay-sui/x402-sui":"0.1.0","@agentpay-sui/shared":"0.1.0"},"devDependencies":{"@types/express":"^5.0.6","@types/node":"^25.0.0","tsx":"^4.21.0","typescript":"^5.9.3"},"scripts":{"build":"tsc -p tsconfig.build.json","dev":"tsx src/server.ts","phase5:smoke":"tsx scripts/phase5-smoke.ts","phase6:smoke":"tsx scripts/phase6-smoke.ts","phase7:smoke":"tsx scripts/phase7-smoke.ts","test":"node --experimental-strip-types --experimental-specifier-resolution=node --test test/*.test.ts","typecheck":"tsc -p tsconfig.json --noEmit"},"_id":"@agentpay-sui/gateway@0.1.0","description":"Self-hostable paid-tool gateway for AgentPay/Sui x402 routes.","_integrity":"sha512-1MttI3YZu1311jLCNF9LUGTMQ6RnXRMbssKERcPQjPQmd0C0mhfsG+QXtJgwN8GoI2DNeS+Q2bfkq8lC/zg4Dg==","_resolved":"/private/var/folders/s0/b6zql__n7v19sv58nl_4096w0000gn/T/8188816add3e99e68b563fe52228e4bd/agentpay-sui-gateway-0.1.0.tgz","_from":"file:agentpay-sui-gateway-0.1.0.tgz","_nodeVersion":"25.5.0","_npmVersion":"11.8.0","dist":{"integrity":"sha512-1MttI3YZu1311jLCNF9LUGTMQ6RnXRMbssKERcPQjPQmd0C0mhfsG+QXtJgwN8GoI2DNeS+Q2bfkq8lC/zg4Dg==","shasum":"daae154451c7e14f89051d9e029fa0d0e9ba166e","tarball":"https://registry.npmjs.org/@agentpay-sui/gateway/-/gateway-0.1.0.tgz","fileCount":5,"unpackedSize":37672,"signatures":[{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEQCIAy+DI87Tk5HCKXG8Arx8uAjtFdDU0p9l+5E84iUcCgPAiBeWR3MFnZufx8Jb+xRm9bfFVme4ACpX44TZOaY+E2dCw=="}]},"_npmUser":{"name":"divi280605","email":"divyansh242805@gmail.com"},"directories":{},"maintainers":[{"name":"divi280605","email":"divyansh242805@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/gateway_0.1.0_1781255878325_0.9605642926727855"},"_hasShrinkwrap":false}},"time":{"created":"2026-06-12T09:17:58.205Z","0.1.0":"2026-06-12T09:17:58.487Z","modified":"2026-06-12T09:17:58.664Z"},"maintainers":[{"name":"divi280605","email":"divyansh242805@gmail.com"}],"description":"Self-hostable paid-tool gateway for AgentPay/Sui x402 routes.","readme":"# @agentpay-sui/gateway\n\nSelf-hostable paid-tool gateway for AgentPay/Sui x402 routes.\n\nThe gateway sits in front of API providers and enforces the payment boundary:\n\n1. unpaid request returns `402` with `PAYMENT-REQUIRED`\n2. paid retry sends `PAYMENT-SIGNATURE`\n3. gateway calls facilitator `/verify`\n4. provider runs only after verification\n5. gateway calls facilitator `/settle` only after provider success\n6. response includes `PAYMENT-RESPONSE` with receipt/reputation metadata\n\n## Run\n\n```bash\nagentpay-gateway\n```\n\nCommon environment:\n\n```bash\nFACILITATOR_URL=https://your-facilitator.example\nAGENTPAY_NETWORK=sui:testnet\nAGENTPAY_GATEWAY_TOOLS_JSON='[{\"slug\":\"weather\",\"toolId\":\"0x...\",\"expectedPayee\":\"0x...\",\"coinType\":\"0x2::sui::SUI\",\"amount\":\"1000000\",\"symbol\":\"SUI\",\"decimals\":9}]'\nAGENTPAY_GATEWAY_CORS_ORIGINS=https://your-app.example\n```\n\nReal no-key providers:\n\n```bash\nAGENTPAY_WEATHER_PROVIDER=open-meteo\nAGENTPAY_PYTH_PROVIDER=hermes\nAGENTPAY_PYTH_HERMES_URL=https://hermes-beta.pyth.network\nAGENTPAY_WEB_FETCH_ALLOW_NETWORK=true\nAGENTPAY_WEB_FETCH_ALLOWED_HOSTS=docs.sui.io\n```\n\n## Embed\n\n```ts\nimport { createGatewayApp } from \"@agentpay-sui/gateway\";\n\nconst app = createGatewayApp({\n  facilitatorUrl: \"https://your-facilitator.example\",\n});\n\napp.listen(8081);\n```\n","readmeFilename":"README.md","_rev":"1-4572905bfc11b0c26dc08fc1ead42473"}