@paynodelabs/paynode-402-cli 2.5.2 → 2.6.0

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.
@@ -63,7 +63,7 @@ export interface RawCatalogApiItem {
63
63
 
64
64
  function normalizeCatalogItem(raw: RawCatalogApiItem): CatalogApiItem {
65
65
  return {
66
- id: raw.id || raw.api_id || '',
66
+ id: raw.api_id || raw.id?.replace(/-(testnet|mainnet)$/, '') || '',
67
67
  name: raw.name || raw.title || raw.api_name || raw.api_id || 'unnamed',
68
68
  description: raw.description,
69
69
  tags: Array.isArray(raw.tags) ? raw.tags : [],
@@ -147,7 +147,12 @@ export class MarketplaceClient {
147
147
  if (network) params.set('network', network);
148
148
  const query = params.toString();
149
149
  const path = `/api/v1/paid-apis/${encodeURIComponent(apiId)}${query ? `?${query}` : ''}`;
150
- const raw = await this.request<any>(path);
150
+ const raw = await this.request<any>(path, {
151
+ method: 'POST',
152
+ headers: {
153
+ 'X-PayNode-Discovery': 'true'
154
+ }
155
+ });
151
156
  return normalizeCatalogItem(raw);
152
157
  }
153
158
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@paynodelabs/paynode-402-cli",
3
- "version": "2.5.2",
3
+ "version": "2.6.0",
4
4
  "description": "The official command-line interface for the PayNode protocol. Designed for AI Agents to execute stateless micro-payments via HTTP 402.",
5
5
  "type": "module",
6
6
  "main": "./index.ts",