@proveanything/smartlinks 2.0.9 → 2.0.11
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/dist/ai-tools.d.ts +35 -0
- package/dist/ai-tools.js +69 -0
- package/dist/api/ai.d.ts +7 -12
- package/dist/api/ai.js +2 -10
- package/dist/docs/API_SUMMARY.md +343 -1
- package/dist/docs/agent-tools.md +26 -14
- package/dist/docs/ai.md +79 -0
- package/dist/docs/app-manifest.md +4 -2
- package/dist/docs/host-dependency-contract.md +10 -6
- package/dist/docs/overview.md +1 -1
- package/dist/index.d.ts +2 -0
- package/dist/index.js +2 -0
- package/dist/openapi.yaml +484 -6
- package/dist/shared-dependencies.d.ts +3 -3
- package/dist/shared-dependencies.js +8 -6
- package/dist/types/ai.d.ts +323 -0
- package/dist/types/appManifest.d.ts +1 -1
- package/docs/API_SUMMARY.md +343 -1
- package/docs/agent-tools.md +26 -14
- package/docs/ai.md +79 -0
- package/docs/app-manifest.md +4 -2
- package/docs/host-dependency-contract.md +10 -6
- package/docs/overview.md +1 -1
- package/openapi.yaml +484 -6
- package/package.json +1 -1
package/dist/openapi.yaml
CHANGED
|
@@ -777,7 +777,8 @@ paths:
|
|
|
777
777
|
description: Success
|
|
778
778
|
content:
|
|
779
779
|
application/json:
|
|
780
|
-
schema:
|
|
780
|
+
schema:
|
|
781
|
+
$ref: "#/components/schemas/AICacheRef"
|
|
781
782
|
400:
|
|
782
783
|
description: Bad request
|
|
783
784
|
401:
|
|
@@ -803,7 +804,8 @@ paths:
|
|
|
803
804
|
description: Success
|
|
804
805
|
content:
|
|
805
806
|
application/json:
|
|
806
|
-
schema:
|
|
807
|
+
schema:
|
|
808
|
+
$ref: "#/components/schemas/AIGenerateImageResponse"
|
|
807
809
|
400:
|
|
808
810
|
description: Bad request
|
|
809
811
|
401:
|
|
@@ -1011,9 +1013,7 @@ paths:
|
|
|
1011
1013
|
content:
|
|
1012
1014
|
application/json:
|
|
1013
1015
|
schema:
|
|
1014
|
-
|
|
1015
|
-
items:
|
|
1016
|
-
$ref: "#/components/schemas/AISearchPhotosPhoto"
|
|
1016
|
+
$ref: "#/components/schemas/AISearchPhotosResponse"
|
|
1017
1017
|
400:
|
|
1018
1018
|
description: Bad request
|
|
1019
1019
|
401:
|
|
@@ -1132,7 +1132,8 @@ paths:
|
|
|
1132
1132
|
description: Success
|
|
1133
1133
|
content:
|
|
1134
1134
|
application/json:
|
|
1135
|
-
schema:
|
|
1135
|
+
schema:
|
|
1136
|
+
$ref: "#/components/schemas/AIUploadedFile"
|
|
1136
1137
|
400:
|
|
1137
1138
|
description: Bad request
|
|
1138
1139
|
401:
|
|
@@ -15222,6 +15223,25 @@ components:
|
|
|
15222
15223
|
- standard
|
|
15223
15224
|
- flex
|
|
15224
15225
|
- priority
|
|
15226
|
+
server_tools:
|
|
15227
|
+
type: array
|
|
15228
|
+
items:
|
|
15229
|
+
type: object
|
|
15230
|
+
additionalProperties: true
|
|
15231
|
+
allowCapabilities:
|
|
15232
|
+
type: array
|
|
15233
|
+
items:
|
|
15234
|
+
$ref: "#/components/schemas/AiToolCapability"
|
|
15235
|
+
only:
|
|
15236
|
+
type: array
|
|
15237
|
+
items:
|
|
15238
|
+
$ref: "#/components/schemas/AiToolName"
|
|
15239
|
+
exclude:
|
|
15240
|
+
type: array
|
|
15241
|
+
items:
|
|
15242
|
+
$ref: "#/components/schemas/AiToolName"
|
|
15243
|
+
maxSteps:
|
|
15244
|
+
type: number
|
|
15225
15245
|
required:
|
|
15226
15246
|
- enabled
|
|
15227
15247
|
ResponsesResult:
|
|
@@ -15275,6 +15295,8 @@ components:
|
|
|
15275
15295
|
- openai
|
|
15276
15296
|
responseTime:
|
|
15277
15297
|
type: number
|
|
15298
|
+
_agent:
|
|
15299
|
+
$ref: "#/components/schemas/ResponsesAgentTrace"
|
|
15278
15300
|
required:
|
|
15279
15301
|
- id
|
|
15280
15302
|
- object
|
|
@@ -16023,16 +16045,121 @@ components:
|
|
|
16023
16045
|
AISearchPhotosPhoto:
|
|
16024
16046
|
type: object
|
|
16025
16047
|
properties:
|
|
16048
|
+
id:
|
|
16049
|
+
type: string
|
|
16026
16050
|
url:
|
|
16027
16051
|
type: string
|
|
16052
|
+
thumb:
|
|
16053
|
+
type: string
|
|
16028
16054
|
alt:
|
|
16029
16055
|
type: string
|
|
16056
|
+
width:
|
|
16057
|
+
type: number
|
|
16058
|
+
height:
|
|
16059
|
+
type: number
|
|
16030
16060
|
photographer:
|
|
16031
16061
|
type: string
|
|
16032
16062
|
photographerUrl:
|
|
16033
16063
|
type: string
|
|
16034
16064
|
required:
|
|
16035
16065
|
- url
|
|
16066
|
+
AISearchPhotosResponse:
|
|
16067
|
+
type: object
|
|
16068
|
+
properties:
|
|
16069
|
+
provider:
|
|
16070
|
+
type: string
|
|
16071
|
+
results:
|
|
16072
|
+
type: array
|
|
16073
|
+
items:
|
|
16074
|
+
$ref: "#/components/schemas/AISearchPhotosPhoto"
|
|
16075
|
+
total:
|
|
16076
|
+
type: number
|
|
16077
|
+
total_pages:
|
|
16078
|
+
type: number
|
|
16079
|
+
required:
|
|
16080
|
+
- provider
|
|
16081
|
+
- results
|
|
16082
|
+
AIGeneratedImage:
|
|
16083
|
+
type: object
|
|
16084
|
+
properties:
|
|
16085
|
+
url:
|
|
16086
|
+
type: string
|
|
16087
|
+
b64_json:
|
|
16088
|
+
type: string
|
|
16089
|
+
revised_prompt:
|
|
16090
|
+
type: string
|
|
16091
|
+
required:
|
|
16092
|
+
- url
|
|
16093
|
+
- b64_json
|
|
16094
|
+
AIGenerateImageResponse:
|
|
16095
|
+
type: object
|
|
16096
|
+
properties:
|
|
16097
|
+
provider:
|
|
16098
|
+
type: string
|
|
16099
|
+
model:
|
|
16100
|
+
type: string
|
|
16101
|
+
images:
|
|
16102
|
+
type: array
|
|
16103
|
+
items:
|
|
16104
|
+
$ref: "#/components/schemas/AIGeneratedImage"
|
|
16105
|
+
required:
|
|
16106
|
+
- provider
|
|
16107
|
+
- images
|
|
16108
|
+
AIGenerateContentCandidate:
|
|
16109
|
+
type: object
|
|
16110
|
+
properties:
|
|
16111
|
+
content:
|
|
16112
|
+
type: object
|
|
16113
|
+
additionalProperties: true
|
|
16114
|
+
finishReason:
|
|
16115
|
+
type: string
|
|
16116
|
+
AIGenerateContentResponse:
|
|
16117
|
+
type: object
|
|
16118
|
+
properties:
|
|
16119
|
+
provider:
|
|
16120
|
+
type: string
|
|
16121
|
+
model:
|
|
16122
|
+
type: string
|
|
16123
|
+
candidates:
|
|
16124
|
+
type: array
|
|
16125
|
+
items:
|
|
16126
|
+
$ref: "#/components/schemas/AIGenerateContentCandidate"
|
|
16127
|
+
usageMetadata:
|
|
16128
|
+
type: object
|
|
16129
|
+
additionalProperties: true
|
|
16130
|
+
promptTokenCount:
|
|
16131
|
+
type: number
|
|
16132
|
+
candidatesTokenCount:
|
|
16133
|
+
type: number
|
|
16134
|
+
totalTokenCount:
|
|
16135
|
+
type: number
|
|
16136
|
+
responseTime:
|
|
16137
|
+
type: number
|
|
16138
|
+
AIUploadedFile:
|
|
16139
|
+
type: object
|
|
16140
|
+
properties:
|
|
16141
|
+
name:
|
|
16142
|
+
type: string
|
|
16143
|
+
uri:
|
|
16144
|
+
type: string
|
|
16145
|
+
url:
|
|
16146
|
+
type: string
|
|
16147
|
+
mimeType:
|
|
16148
|
+
type: string
|
|
16149
|
+
sizeBytes:
|
|
16150
|
+
type: object
|
|
16151
|
+
additionalProperties: true
|
|
16152
|
+
state:
|
|
16153
|
+
type: string
|
|
16154
|
+
AICacheRef:
|
|
16155
|
+
type: object
|
|
16156
|
+
properties:
|
|
16157
|
+
name:
|
|
16158
|
+
type: string
|
|
16159
|
+
model:
|
|
16160
|
+
type: string
|
|
16161
|
+
expireTime:
|
|
16162
|
+
type: string
|
|
16036
16163
|
AgentRunRequest:
|
|
16037
16164
|
type: object
|
|
16038
16165
|
properties:
|
|
@@ -16170,6 +16297,357 @@ components:
|
|
|
16170
16297
|
required:
|
|
16171
16298
|
- tools
|
|
16172
16299
|
- skills
|
|
16300
|
+
WebFetchPageArgs:
|
|
16301
|
+
type: object
|
|
16302
|
+
properties:
|
|
16303
|
+
url:
|
|
16304
|
+
type: object
|
|
16305
|
+
additionalProperties: true
|
|
16306
|
+
required:
|
|
16307
|
+
- url
|
|
16308
|
+
WebExtractSchemaArgs:
|
|
16309
|
+
type: object
|
|
16310
|
+
properties:
|
|
16311
|
+
url:
|
|
16312
|
+
type: object
|
|
16313
|
+
additionalProperties: true
|
|
16314
|
+
required:
|
|
16315
|
+
- url
|
|
16316
|
+
WebScreenshotArgs:
|
|
16317
|
+
type: object
|
|
16318
|
+
properties:
|
|
16319
|
+
url:
|
|
16320
|
+
type: string
|
|
16321
|
+
required:
|
|
16322
|
+
- url
|
|
16323
|
+
WebSearchArgs:
|
|
16324
|
+
type: object
|
|
16325
|
+
properties:
|
|
16326
|
+
query:
|
|
16327
|
+
type: object
|
|
16328
|
+
additionalProperties: true
|
|
16329
|
+
required:
|
|
16330
|
+
- query
|
|
16331
|
+
BrandAssetsArgs:
|
|
16332
|
+
type: object
|
|
16333
|
+
properties:
|
|
16334
|
+
url:
|
|
16335
|
+
type: string
|
|
16336
|
+
required:
|
|
16337
|
+
- url
|
|
16338
|
+
DocumentReadArgs:
|
|
16339
|
+
type: object
|
|
16340
|
+
properties:
|
|
16341
|
+
url:
|
|
16342
|
+
type: object
|
|
16343
|
+
additionalProperties: true
|
|
16344
|
+
required:
|
|
16345
|
+
- url
|
|
16346
|
+
DataExtractArgs:
|
|
16347
|
+
type: object
|
|
16348
|
+
properties:
|
|
16349
|
+
url:
|
|
16350
|
+
type: object
|
|
16351
|
+
additionalProperties: true
|
|
16352
|
+
required:
|
|
16353
|
+
- url
|
|
16354
|
+
ImageDescribeArgs:
|
|
16355
|
+
type: object
|
|
16356
|
+
properties:
|
|
16357
|
+
imageUrl:
|
|
16358
|
+
type: object
|
|
16359
|
+
additionalProperties: true
|
|
16360
|
+
required:
|
|
16361
|
+
- imageUrl
|
|
16362
|
+
ImageGenerateArgs:
|
|
16363
|
+
type: object
|
|
16364
|
+
properties:
|
|
16365
|
+
prompt:
|
|
16366
|
+
type: string
|
|
16367
|
+
enum:
|
|
16368
|
+
- openai
|
|
16369
|
+
- gemini
|
|
16370
|
+
required:
|
|
16371
|
+
- prompt
|
|
16372
|
+
ImageFromReferenceArgs:
|
|
16373
|
+
type: object
|
|
16374
|
+
properties:
|
|
16375
|
+
prompt:
|
|
16376
|
+
type: object
|
|
16377
|
+
additionalProperties: true
|
|
16378
|
+
required:
|
|
16379
|
+
- prompt
|
|
16380
|
+
ImageSearchStockArgs:
|
|
16381
|
+
type: object
|
|
16382
|
+
properties:
|
|
16383
|
+
query:
|
|
16384
|
+
type: string
|
|
16385
|
+
enum:
|
|
16386
|
+
- landscape
|
|
16387
|
+
- portrait
|
|
16388
|
+
- squarish
|
|
16389
|
+
required:
|
|
16390
|
+
- query
|
|
16391
|
+
ImageTransformArgs:
|
|
16392
|
+
type: object
|
|
16393
|
+
properties:
|
|
16394
|
+
imageUrl:
|
|
16395
|
+
type: string
|
|
16396
|
+
resize:
|
|
16397
|
+
type: string
|
|
16398
|
+
enum:
|
|
16399
|
+
- cover
|
|
16400
|
+
- contain
|
|
16401
|
+
- fill
|
|
16402
|
+
- inside
|
|
16403
|
+
- outside
|
|
16404
|
+
crop:
|
|
16405
|
+
type: object
|
|
16406
|
+
additionalProperties: true
|
|
16407
|
+
rotate:
|
|
16408
|
+
type: number
|
|
16409
|
+
flip:
|
|
16410
|
+
type: boolean
|
|
16411
|
+
flop:
|
|
16412
|
+
type: boolean
|
|
16413
|
+
grayscale:
|
|
16414
|
+
type: boolean
|
|
16415
|
+
tint:
|
|
16416
|
+
type: string
|
|
16417
|
+
modulate:
|
|
16418
|
+
type: object
|
|
16419
|
+
additionalProperties: true
|
|
16420
|
+
format:
|
|
16421
|
+
type: string
|
|
16422
|
+
enum:
|
|
16423
|
+
- jpeg
|
|
16424
|
+
- png
|
|
16425
|
+
- webp
|
|
16426
|
+
- avif
|
|
16427
|
+
quality:
|
|
16428
|
+
type: number
|
|
16429
|
+
required:
|
|
16430
|
+
- imageUrl
|
|
16431
|
+
PdfCreateArgs:
|
|
16432
|
+
type: object
|
|
16433
|
+
properties:
|
|
16434
|
+
html:
|
|
16435
|
+
type: object
|
|
16436
|
+
additionalProperties: true
|
|
16437
|
+
required:
|
|
16438
|
+
- html
|
|
16439
|
+
PdfFillArgs:
|
|
16440
|
+
type: object
|
|
16441
|
+
properties:
|
|
16442
|
+
url:
|
|
16443
|
+
type: object
|
|
16444
|
+
additionalProperties: true
|
|
16445
|
+
required:
|
|
16446
|
+
- url
|
|
16447
|
+
PdfMergeArgs:
|
|
16448
|
+
type: object
|
|
16449
|
+
properties:
|
|
16450
|
+
urls:
|
|
16451
|
+
type: array
|
|
16452
|
+
items:
|
|
16453
|
+
type: string
|
|
16454
|
+
required:
|
|
16455
|
+
- urls
|
|
16456
|
+
HttpRequestArgs:
|
|
16457
|
+
type: object
|
|
16458
|
+
properties:
|
|
16459
|
+
url:
|
|
16460
|
+
type: string
|
|
16461
|
+
enum:
|
|
16462
|
+
- GET
|
|
16463
|
+
- POST
|
|
16464
|
+
- PUT
|
|
16465
|
+
- PATCH
|
|
16466
|
+
- DELETE
|
|
16467
|
+
- HEAD
|
|
16468
|
+
required:
|
|
16469
|
+
- url
|
|
16470
|
+
TranslateArgs:
|
|
16471
|
+
type: object
|
|
16472
|
+
properties:
|
|
16473
|
+
text:
|
|
16474
|
+
type: object
|
|
16475
|
+
additionalProperties: true
|
|
16476
|
+
required:
|
|
16477
|
+
- text
|
|
16478
|
+
AiToolArgsMap:
|
|
16479
|
+
type: object
|
|
16480
|
+
properties:
|
|
16481
|
+
web.fetchPage:
|
|
16482
|
+
$ref: "#/components/schemas/WebFetchPageArgs"
|
|
16483
|
+
web.extractSchema:
|
|
16484
|
+
$ref: "#/components/schemas/WebExtractSchemaArgs"
|
|
16485
|
+
web.screenshot:
|
|
16486
|
+
$ref: "#/components/schemas/WebScreenshotArgs"
|
|
16487
|
+
web.search:
|
|
16488
|
+
$ref: "#/components/schemas/WebSearchArgs"
|
|
16489
|
+
brand.assets:
|
|
16490
|
+
$ref: "#/components/schemas/BrandAssetsArgs"
|
|
16491
|
+
document.read:
|
|
16492
|
+
$ref: "#/components/schemas/DocumentReadArgs"
|
|
16493
|
+
data.extract:
|
|
16494
|
+
$ref: "#/components/schemas/DataExtractArgs"
|
|
16495
|
+
image.describe:
|
|
16496
|
+
$ref: "#/components/schemas/ImageDescribeArgs"
|
|
16497
|
+
image.generate:
|
|
16498
|
+
$ref: "#/components/schemas/ImageGenerateArgs"
|
|
16499
|
+
image.fromReference:
|
|
16500
|
+
$ref: "#/components/schemas/ImageFromReferenceArgs"
|
|
16501
|
+
image.searchStock:
|
|
16502
|
+
$ref: "#/components/schemas/ImageSearchStockArgs"
|
|
16503
|
+
image.transform:
|
|
16504
|
+
$ref: "#/components/schemas/ImageTransformArgs"
|
|
16505
|
+
pdf.create:
|
|
16506
|
+
$ref: "#/components/schemas/PdfCreateArgs"
|
|
16507
|
+
pdf.fill:
|
|
16508
|
+
$ref: "#/components/schemas/PdfFillArgs"
|
|
16509
|
+
pdf.merge:
|
|
16510
|
+
$ref: "#/components/schemas/PdfMergeArgs"
|
|
16511
|
+
http.request:
|
|
16512
|
+
$ref: "#/components/schemas/HttpRequestArgs"
|
|
16513
|
+
translate:
|
|
16514
|
+
$ref: "#/components/schemas/TranslateArgs"
|
|
16515
|
+
required:
|
|
16516
|
+
- web.fetchPage
|
|
16517
|
+
- web.extractSchema
|
|
16518
|
+
- web.screenshot
|
|
16519
|
+
- web.search
|
|
16520
|
+
- brand.assets
|
|
16521
|
+
- document.read
|
|
16522
|
+
- data.extract
|
|
16523
|
+
- image.describe
|
|
16524
|
+
- image.generate
|
|
16525
|
+
- image.fromReference
|
|
16526
|
+
- image.searchStock
|
|
16527
|
+
- image.transform
|
|
16528
|
+
- pdf.create
|
|
16529
|
+
- pdf.fill
|
|
16530
|
+
- pdf.merge
|
|
16531
|
+
- http.request
|
|
16532
|
+
- translate
|
|
16533
|
+
WebSearchResultItem:
|
|
16534
|
+
type: object
|
|
16535
|
+
properties:
|
|
16536
|
+
url:
|
|
16537
|
+
type: object
|
|
16538
|
+
additionalProperties: true
|
|
16539
|
+
required:
|
|
16540
|
+
- url
|
|
16541
|
+
WebSearchResult:
|
|
16542
|
+
type: object
|
|
16543
|
+
properties:
|
|
16544
|
+
query:
|
|
16545
|
+
type: array
|
|
16546
|
+
items:
|
|
16547
|
+
type: object
|
|
16548
|
+
additionalProperties: true
|
|
16549
|
+
required:
|
|
16550
|
+
- query
|
|
16551
|
+
DocumentReadResult:
|
|
16552
|
+
type: object
|
|
16553
|
+
properties:
|
|
16554
|
+
url:
|
|
16555
|
+
type: object
|
|
16556
|
+
additionalProperties: true
|
|
16557
|
+
required:
|
|
16558
|
+
- url
|
|
16559
|
+
DataExtractResult:
|
|
16560
|
+
type: object
|
|
16561
|
+
properties:
|
|
16562
|
+
url:
|
|
16563
|
+
type: object
|
|
16564
|
+
additionalProperties: true
|
|
16565
|
+
required:
|
|
16566
|
+
- url
|
|
16567
|
+
WebFetchPageResult:
|
|
16568
|
+
type: object
|
|
16569
|
+
properties:
|
|
16570
|
+
url:
|
|
16571
|
+
type: object
|
|
16572
|
+
additionalProperties: true
|
|
16573
|
+
required:
|
|
16574
|
+
- url
|
|
16575
|
+
ImageDescribeResult:
|
|
16576
|
+
type: object
|
|
16577
|
+
properties:
|
|
16578
|
+
imageUrl:
|
|
16579
|
+
type: object
|
|
16580
|
+
additionalProperties: true
|
|
16581
|
+
required:
|
|
16582
|
+
- imageUrl
|
|
16583
|
+
HostedAssetResult:
|
|
16584
|
+
type: object
|
|
16585
|
+
properties:
|
|
16586
|
+
hostedUrl:
|
|
16587
|
+
type: object
|
|
16588
|
+
additionalProperties: true
|
|
16589
|
+
required:
|
|
16590
|
+
- hostedUrl
|
|
16591
|
+
HttpRequestResult:
|
|
16592
|
+
type: object
|
|
16593
|
+
properties:
|
|
16594
|
+
status:
|
|
16595
|
+
type: object
|
|
16596
|
+
additionalProperties: true
|
|
16597
|
+
required:
|
|
16598
|
+
- status
|
|
16599
|
+
TranslateResult:
|
|
16600
|
+
type: object
|
|
16601
|
+
properties:
|
|
16602
|
+
translations:
|
|
16603
|
+
type: object
|
|
16604
|
+
additionalProperties: true
|
|
16605
|
+
required:
|
|
16606
|
+
- translations
|
|
16607
|
+
ResponsesAgentTrace:
|
|
16608
|
+
type: object
|
|
16609
|
+
properties:
|
|
16610
|
+
steps:
|
|
16611
|
+
type: number
|
|
16612
|
+
maxStepsReached:
|
|
16613
|
+
type: boolean
|
|
16614
|
+
toolResults:
|
|
16615
|
+
type: array
|
|
16616
|
+
items:
|
|
16617
|
+
$ref: "#/components/schemas/AgentToolResult"
|
|
16618
|
+
availableTools:
|
|
16619
|
+
type: array
|
|
16620
|
+
items:
|
|
16621
|
+
type: string
|
|
16622
|
+
required:
|
|
16623
|
+
- steps
|
|
16624
|
+
- maxStepsReached
|
|
16625
|
+
- toolResults
|
|
16626
|
+
- availableTools
|
|
16627
|
+
AgentToolCallEvent:
|
|
16628
|
+
type: object
|
|
16629
|
+
properties:
|
|
16630
|
+
type:
|
|
16631
|
+
type: object
|
|
16632
|
+
additionalProperties: true
|
|
16633
|
+
required:
|
|
16634
|
+
- type
|
|
16635
|
+
AgentToolResultEvent:
|
|
16636
|
+
type: object
|
|
16637
|
+
properties:
|
|
16638
|
+
type:
|
|
16639
|
+
type: object
|
|
16640
|
+
additionalProperties: true
|
|
16641
|
+
required:
|
|
16642
|
+
- type
|
|
16643
|
+
AgentResponseCompletedEvent:
|
|
16644
|
+
type: object
|
|
16645
|
+
properties:
|
|
16646
|
+
type:
|
|
16647
|
+
type: object
|
|
16648
|
+
additionalProperties: true
|
|
16649
|
+
required:
|
|
16650
|
+
- type
|
|
16173
16651
|
AnalyticsLocation:
|
|
16174
16652
|
type: object
|
|
16175
16653
|
properties:
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/** Current contract revision. Bumped when the entry list or host versions change. */
|
|
2
|
-
export declare const SHARED_DEPENDENCY_CONTRACT_VERSION: "
|
|
2
|
+
export declare const SHARED_DEPENDENCY_CONTRACT_VERSION: "v6";
|
|
3
3
|
export interface SharedDependency {
|
|
4
4
|
/** Bare import specifier the app writes, e.g. `react-dom/client`. */
|
|
5
5
|
specifier: string;
|
|
@@ -13,8 +13,8 @@ export interface SharedDependency {
|
|
|
13
13
|
/**
|
|
14
14
|
* Canonical import-map path for a specifier: drop the leading `@` scope marker and
|
|
15
15
|
* turn every `/` into `-`.
|
|
16
|
-
* 'react-dom/client' -> '/sl-shared/
|
|
17
|
-
* '@radix-ui/react-slot' -> '/sl-shared/
|
|
16
|
+
* 'react-dom/client' -> '/sl-shared/v6/react-dom-client.js'
|
|
17
|
+
* '@radix-ui/react-slot' -> '/sl-shared/v6/radix-ui-react-slot.js'
|
|
18
18
|
* Hosts MUST serve shims at these paths so the map the SDK advertises resolves.
|
|
19
19
|
*/
|
|
20
20
|
export declare function importMapPathFor(specifier: string, version?: string): string;
|
|
@@ -11,21 +11,22 @@
|
|
|
11
11
|
//
|
|
12
12
|
// See docs/host-dependency-contract.md.
|
|
13
13
|
/** Current contract revision. Bumped when the entry list or host versions change. */
|
|
14
|
-
export const SHARED_DEPENDENCY_CONTRACT_VERSION = '
|
|
14
|
+
export const SHARED_DEPENDENCY_CONTRACT_VERSION = 'v6';
|
|
15
15
|
/**
|
|
16
16
|
* Canonical import-map path for a specifier: drop the leading `@` scope marker and
|
|
17
17
|
* turn every `/` into `-`.
|
|
18
|
-
* 'react-dom/client' -> '/sl-shared/
|
|
19
|
-
* '@radix-ui/react-slot' -> '/sl-shared/
|
|
18
|
+
* 'react-dom/client' -> '/sl-shared/v6/react-dom-client.js'
|
|
19
|
+
* '@radix-ui/react-slot' -> '/sl-shared/v6/radix-ui-react-slot.js'
|
|
20
20
|
* Hosts MUST serve shims at these paths so the map the SDK advertises resolves.
|
|
21
21
|
*/
|
|
22
22
|
export function importMapPathFor(specifier, version = SHARED_DEPENDENCY_CONTRACT_VERSION) {
|
|
23
23
|
const slug = specifier.replace(/^@/, '').replace(/\//g, '-');
|
|
24
24
|
return `/sl-shared/${version}/${slug}.js`;
|
|
25
25
|
}
|
|
26
|
-
// The
|
|
27
|
-
//
|
|
28
|
-
//
|
|
26
|
+
// The 26-entry v6 contract: the v5 set plus `marked` (host-provided markdown
|
|
27
|
+
// renderer, so apps stop bundling their own ~30KB copy — portal & hub render it in
|
|
28
|
+
// the container). minVersion follows the R5 host baseline (React 19, Router 7.18.4
|
|
29
|
+
// security floor, LiquidJS 10.27+, current Radix majors).
|
|
29
30
|
const CONTRACT = [
|
|
30
31
|
{ specifier: 'react', globalName: 'React', minVersion: '19.0.0' },
|
|
31
32
|
{ specifier: 'react-dom', globalName: 'ReactDOM', minVersion: '19.0.0' },
|
|
@@ -39,6 +40,7 @@ const CONTRACT = [
|
|
|
39
40
|
{ specifier: 'lucide-react', globalName: 'LucideReact', minVersion: '1.0.0' },
|
|
40
41
|
{ specifier: 'date-fns', globalName: 'dateFns', minVersion: '4.0.0' },
|
|
41
42
|
{ specifier: 'liquidjs', globalName: 'LiquidJS', minVersion: '10.27.0' },
|
|
43
|
+
{ specifier: 'marked', globalName: 'marked', minVersion: '12.0.0' },
|
|
42
44
|
{ specifier: 'class-variance-authority', globalName: 'CVA', minVersion: '0.7.0' },
|
|
43
45
|
{ specifier: '@radix-ui/react-slot', globalName: 'RadixSlot', minVersion: '1.2.0' },
|
|
44
46
|
{ specifier: '@radix-ui/react-dialog', globalName: 'RadixDialog', minVersion: '1.1.0' },
|