@proveanything/smartlinks 1.3.5 → 1.3.8

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.
@@ -66,3 +66,45 @@ export interface Collection {
66
66
  export type CollectionResponse = Collection;
67
67
  export type CollectionCreateRequest = Omit<Collection, 'id' | 'shortId'>;
68
68
  export type CollectionUpdateRequest = Partial<Omit<Collection, 'id' | 'shortId'>>;
69
+ /**
70
+ * Configuration for an app module within a collection.
71
+ */
72
+ export interface AppConfig {
73
+ /** Unique identifier for the app */
74
+ id: string;
75
+ /** Underling app module id */
76
+ srcAppId: string;
77
+ /** Display name of the app */
78
+ name: string;
79
+ /** Optional description of the app */
80
+ description?: string;
81
+ /** Optional icon for the app */
82
+ faIcon?: string;
83
+ /** app category */
84
+ category: "Authenticity" | "Documentation" | "Commerce" | "Engagement" | "AI" | "Digital Product Passports" | "Integration" | "Web3" | "Other";
85
+ /** Whether the app is enabled for this collection */
86
+ active?: boolean;
87
+ /** Whether the app is only accessible to owners */
88
+ ownersOnly?: boolean;
89
+ /** Whether the app is hidden in the UI */
90
+ hidden?: boolean;
91
+ /** Universal iframe URL for external embedding */
92
+ publicIframeUrl?: string;
93
+ /** supports multiple pages / deep links into the app */
94
+ supportsDeepLinks?: boolean;
95
+ /** App component configuration */
96
+ usage: {
97
+ collection: boolean;
98
+ product: boolean;
99
+ proof: boolean;
100
+ widget: boolean;
101
+ };
102
+ [key: string]: any;
103
+ }
104
+ /**
105
+ * Response containing app configurations for a collection.
106
+ */
107
+ export interface AppsConfigResponse {
108
+ /** Array of app configurations */
109
+ apps: AppConfig[];
110
+ }
@@ -1,6 +1,6 @@
1
1
  # Smartlinks API Summary
2
2
 
3
- Version: 1.3.5 | Generated: 2026-02-02T20:16:48.361Z
3
+ Version: 1.3.8 | Generated: 2026-02-05T19:14:34.871Z
4
4
 
5
5
  This is a concise summary of all available API functions and types.
6
6
 
@@ -856,6 +856,37 @@ interface Collection {
856
856
  }
857
857
  ```
858
858
 
859
+ **AppConfig** (interface)
860
+ ```typescript
861
+ interface AppConfig {
862
+ id: string
863
+ srcAppId: string
864
+ name: string
865
+ description?: string
866
+ faIcon?: string
867
+ category: "Authenticity" | "Documentation" | "Commerce" | "Engagement" | "AI" | "Digital Product Passports" | "Integration" | "Web3" | "Other";
868
+ active?: boolean
869
+ ownersOnly?: boolean
870
+ hidden?: boolean
871
+ publicIframeUrl?: string
872
+ supportsDeepLinks?: boolean;
873
+ usage: {
874
+ collection: boolean; // use at the collecton level
875
+ product: boolean; // use at the product level
876
+ proof: boolean; // use at the proof level
877
+ widget: boolean; // has a widget component available
878
+ }
879
+ [key: string]: any
880
+ }
881
+ ```
882
+
883
+ **AppsConfigResponse** (interface)
884
+ ```typescript
885
+ interface AppsConfigResponse {
886
+ apps: AppConfig[]
887
+ }
888
+ ```
889
+
859
890
  **CollectionResponse** = `Collection`
860
891
 
861
892
  **CollectionCreateRequest** = `Omit<Collection, 'id' | 'shortId'>`
@@ -2998,6 +3029,9 @@ Retrieve a collection by its shortId (public endpoint).
2998
3029
  **getSettings**(collectionId: string, settingGroup: string, admin?: boolean) → `Promise<any>`
2999
3030
  Retrieve a specific settings group for a collection (public endpoint).
3000
3031
 
3032
+ **getAppsConfig**(collectionId: string) → `Promise<AppsConfigResponse>`
3033
+ Retrieve all configured app module definitions for a collection (public endpoint).
3034
+
3001
3035
  **updateSettings**(collectionId: string, settingGroup: string, settings: any) → `Promise<any>`
3002
3036
  Update a specific settings group for a collection (admin endpoint).
3003
3037
 
@@ -3506,19 +3540,29 @@ Get a single tag mapping by tagId. ```typescript const tag = await tags.get('col
3506
3540
  params?: ListTagsRequest) → `Promise<ListTagsResponse>`
3507
3541
  List all tags for a collection with optional filters and pagination. ```typescript // List all tags const all = await tags.list('coll_123') // List with filters const filtered = await tags.list('coll_123', { productId: 'prod_456', variantId: 'var_789', limit: 50, offset: 0 }) ```
3508
3542
 
3509
- **publicGet**(collectionId: string,
3543
+ **getTag**(tagId: string,
3544
+ params?: PublicGetTagRequest) → `Promise<PublicGetTagResponse>`
3545
+ Public lookup of a single tag by tagId (global). Optionally embed related collection, product, or proof data. No authentication required. ```typescript // Simple lookup const result = await tags.getTag('TAG001') // With embedded data const withData = await tags.getTag('TAG001', { embed: 'collection,product,proof' }) console.log(withData.tag, withData.collection, withData.product, withData.proof) ```
3546
+
3547
+ **publicGet**(_collectionId: string,
3510
3548
  tagId: string,
3511
3549
  params?: PublicGetTagRequest) → `Promise<PublicGetTagResponse>`
3512
- Public lookup of a single tag by tagId within a specific collection. Optionally embed related collection, product, or proof data. No authentication required. ```typescript // Simple lookup const result = await tags.publicGet('coll_123', 'TAG001') // With embedded data const withData = await tags.publicGet('coll_123', 'TAG001', { embed: 'collection,product,proof' }) console.log(withData.tag, withData.collection, withData.product, withData.proof) ```
3550
+ Backward-compat: Public lookup with collectionId parameter (ignored). Calls global route under /public/tags/:tagId.
3513
3551
 
3514
- **publicBatchLookup**(collectionId: string,
3515
- data: PublicBatchLookupRequest) → `Promise<PublicBatchLookupResponse>`
3552
+ **lookupTags**(data: PublicBatchLookupRequest) → `Promise<PublicBatchLookupResponse>`
3516
3553
  Public batch lookup of multiple tags in a single request (POST). Only returns tags from the specified collection. Optionally embed related data. Related data is deduplicated and batch-fetched. No authentication required. ```typescript const result = await tags.publicBatchLookup('coll_123', { tagIds: ['TAG001', 'TAG002', 'TAG003'], embed: 'collection,product' }) // Access tags and deduplicated collections/products console.log(result.tags['TAG001']) console.log(result.collections) console.log(result.products) ```
3517
3554
 
3518
- **publicBatchLookupQuery**(collectionId: string,
3519
- params: PublicBatchLookupQueryRequest) → `Promise<PublicBatchLookupQueryResponse>`
3555
+ **publicBatchLookup**(_collectionId: string,
3556
+ data: PublicBatchLookupRequest) → `Promise<PublicBatchLookupResponse>`
3557
+ Backward-compat: Public batch lookup with collectionId parameter (ignored). Calls global route under /public/tags/lookup.
3558
+
3559
+ **lookupTagsQuery**(params: PublicBatchLookupQueryRequest) → `Promise<PublicBatchLookupQueryResponse>`
3520
3560
  Public batch lookup of multiple tags using query parameters (GET). Only returns tags from the specified collection. Alternative to publicBatchLookup for simple GET requests. No authentication required. ```typescript const result = await tags.publicBatchLookupQuery('coll_123', { tagIds: 'TAG001,TAG002,TAG003', embed: 'collection' }) ```
3521
3561
 
3562
+ **publicBatchLookupQuery**(_collectionId: string,
3563
+ params: PublicBatchLookupQueryRequest) → `Promise<PublicBatchLookupQueryResponse>`
3564
+ Backward-compat: Public batch lookup (GET) with collectionId parameter (ignored). Calls global route under /public/tags/lookup.
3565
+
3522
3566
  ### template
3523
3567
 
3524
3568
  **getAll**(collectionId: string) → `Promise<Template[]>`
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@proveanything/smartlinks",
3
- "version": "1.3.5",
3
+ "version": "1.3.8",
4
4
  "description": "Official JavaScript/TypeScript SDK for the Smartlinks API",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",
@@ -10,11 +10,11 @@
10
10
  "README.md"
11
11
  ],
12
12
  "scripts": {
13
- "build": "tsc && node scripts/copy-docs-to-dist.js",
13
+ "build": "tsc && node generate-api-summary.js && node scripts/copy-docs-to-dist.js",
14
14
  "docs": "typedoc",
15
15
  "docs:summary": "node generate-api-summary.js",
16
16
  "build:docs": "tsc build-docs.ts --outDir dist && node dist/build-docs.js",
17
- "prepublishOnly": "npm run build && npm run docs:summary"
17
+ "prepublishOnly": "npm run build"
18
18
  },
19
19
  "keywords": [
20
20
  "smartlinks",