m2m-market 2.4.0 → 2.4.1
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/README.md +6 -2
- package/package.json +1 -1
- package/protocols.js +1 -1
package/README.md
CHANGED
|
@@ -154,8 +154,12 @@ If the seller refuses the paid request, `purchase.status` is
|
|
|
154
154
|
`unauthorized`, `payment_required`, `forbidden`, `not_found`,
|
|
155
155
|
`method_not_allowed`, `payload_too_large`, `unsupported_media_type`,
|
|
156
156
|
`unprocessable_input`, `rate_limited`, `seller_error` or `other_non_2xx`. The
|
|
157
|
-
request is not retried
|
|
158
|
-
(`charge_policy: "retained_pending_review"`)
|
|
157
|
+
request is not retried. The purchase stays pending
|
|
158
|
+
(`charge_policy: "retained_pending_review"`) until M2M checks the payment on
|
|
159
|
+
the chain. It is then released and the charge is returned, and the status
|
|
160
|
+
becomes `reconciled_released`. If the payment did settle, the status becomes
|
|
161
|
+
`reconciled_settled` and the charge stands. The same applies to
|
|
162
|
+
`seller_error_refund_pending_review`.
|
|
159
163
|
|
|
160
164
|
## OpenAI-compatible tool
|
|
161
165
|
|
package/package.json
CHANGED
package/protocols.js
CHANGED
|
@@ -32,7 +32,7 @@ export async function connectMcp({ accessToken, timeoutMs = 30000, fetchImpl = g
|
|
|
32
32
|
const transport = new sdk.StreamableHTTPClientTransport(new URL(MCP_RESOURCE), {
|
|
33
33
|
fetch: guardedFetch, reconnectionOptions: { maxRetries: 0, initialReconnectionDelay: 1000, maxReconnectionDelay: 1000, reconnectionDelayGrowFactor: 1 }
|
|
34
34
|
});
|
|
35
|
-
const client = new sdk.Client({ name: 'm2m-market', version: '2.4.
|
|
35
|
+
const client = new sdk.Client({ name: 'm2m-market', version: '2.4.1' });
|
|
36
36
|
try { await client.connect(transport); }
|
|
37
37
|
catch { await client.close().catch(() => {}); throw new M2MAPIError('mcp_connection_failed'); }
|
|
38
38
|
return client; // caller closes it in finally; no automatic paid call or replay
|