@plasius/mcp-admin-contracts 0.5.0 → 0.5.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/CHANGELOG.md CHANGED
@@ -14,6 +14,33 @@
14
14
  - **Security**
15
15
  - (placeholder)
16
16
 
17
+ ## [0.5.1] - 2026-08-20
18
+
19
+ - **Added**
20
+ - Added public-safe discovery and schema metadata for all eight canonical
21
+ snake_case model-resolution tools, their authenticated `mcp://models/...`
22
+ resources, JSON-RPC `tools/call` execution, en-GB descriptions, and model
23
+ contract context with bounded verification notes.
24
+
25
+ - **Changed**
26
+ - Advanced the additive MCP Admin registry contract to `2026-08-20.v7` and
27
+ pinned `@plasius/asset-mcp 0.1.6` plus `@plasius/asset-contracts 0.3.1` as
28
+ the canonical model tool and schema sources.
29
+
30
+ - **Fixed**
31
+ - Completed the model-family OAuth discovery registry with the retained
32
+ review and source-management scopes and added the canonical top-level
33
+ catalog-confirm capability export.
34
+ - Deep-froze shared model verification notes and the context schema so one
35
+ consumer cannot mutate later discovery responses.
36
+
37
+ - **Security**
38
+ - Preserved exact canonical OAuth scopes, capabilities, annotations, parent
39
+ and conditional rollout flags without adding runtime access or flag
40
+ evaluation to the public contract package.
41
+ - Kept per-tool authorization metadata unchanged while ensuring issuer and
42
+ protected-resource consumers can advertise every model capability scope.
43
+
17
44
  ## [0.5.0] - 2026-08-13
18
45
 
19
46
  - **Added**
@@ -216,3 +243,4 @@
216
243
  [0.3.1]: https://github.com/Plasius-LTD/mcp-admin-contracts/releases/tag/v0.3.1
217
244
  [0.4.0]: https://github.com/Plasius-LTD/mcp-admin-contracts/releases/tag/v0.4.0
218
245
  [0.5.0]: https://github.com/Plasius-LTD/mcp-admin-contracts/releases/tag/v0.5.0
246
+ [0.5.1]: https://github.com/Plasius-LTD/mcp-admin-contracts/releases/tag/v0.5.1
package/README.md CHANGED
@@ -62,9 +62,69 @@ The exported registry currently covers:
62
62
  spend-trend descriptors
63
63
  - governed asset catalog, source-intake, pipeline, and review descriptors for
64
64
  the hosted `plasius-ltd-site` MCP backend
65
+ - canonical model-resolution discovery sourced from `@plasius/asset-mcp`,
66
+ including its authenticated `mcp://models/...` resource templates
65
67
  - owner-only Token finance descriptors for bounded wallet/activity reads and
66
68
  dual-approved credit or compensating-reversal workflows
67
69
 
70
+ ### Canonical model resolution
71
+
72
+ The additive `modelTools` discovery family advertises the eight exact MCP
73
+ tool names owned by `@plasius/asset-mcp 0.1.6`:
74
+
75
+ - `list_model_search_rankers`
76
+ - `search_model_catalog`
77
+ - `resolve_model_request`
78
+ - `get_model_resolution`
79
+ - `confirm_model_candidate`
80
+ - `retry_model_resolution`
81
+ - `cancel_model_resolution`
82
+ - `rebuild_model_catalog_index`
83
+
84
+ These are JSON-RPC 2.0 tools executed with `tools/call` over `POST /api/mcp`.
85
+ They are deliberately separate from the existing REST-backed `actions` array;
86
+ all legacy descriptors and exports remain source-compatible. The schema
87
+ response references the canonical input/output schema objects, annotations,
88
+ OAuth security schemes, capabilities, review-result metadata, and rollout
89
+ metadata directly from `@plasius/asset-mcp` rather than maintaining local
90
+ copies. Each wrapper also carries bounded verification notes identifying the
91
+ canonical result or follow-up tool used to confirm an operation.
92
+
93
+ Every model tool requires the parent
94
+ `asset.pipeline.unified-ai-assets.enabled` flag. Provider acquisition and the
95
+ future generator additionally carry the conditional, fail-closed
96
+ `asset.pipeline.external-model-harvest.enabled` and
97
+ `asset.pipeline.ai-model-generation.enabled` flags only on the tools that may
98
+ attempt those fallbacks. Installing this package does not evaluate any flag or
99
+ make a hosted tool callable; the consuming runtime owns fail-closed rollout,
100
+ OAuth, capability, ownership, and audit enforcement.
101
+
102
+ Tool scopes and capabilities are preserved exactly, including distinct
103
+ `asset.catalog.request`, `asset.catalog.confirm`, and operator-only
104
+ `asset.pipeline.mcp.manage` requirements. The wider model capability registry
105
+ also carries `asset.catalog.review` and `asset.source.manage` for coordinated
106
+ host discovery. `MCP_ADMIN_MODEL_OAUTH_SCOPES` is the complete issuer and
107
+ protected-resource scope registry (`mcp:access` plus all five asset capability
108
+ scopes); it does not broaden any individual tool descriptor. Named
109
+ `MCP_ASSET_*_CAPABILITY` exports, including
110
+ `MCP_ASSET_CATALOG_CONFIRM_CAPABILITY`, use the canonical package constants so
111
+ hosts do not need to hardcode those identifiers. Authenticated
112
+ model-resolution records, processing manifests,
113
+ 1024-pixel originals, and promoted manifests are advertised through the five
114
+ canonical `mcp://models/...` resource templates. Inline 512-pixel four-view
115
+ image results remain part of the canonical tool result contract, not this
116
+ admin wrapper.
117
+
118
+ Shared verification-note arrays and the exported context schema are deeply
119
+ frozen. A consumer therefore cannot mutate one discovery or schema result and
120
+ silently change later calls in the same process.
121
+
122
+ Package-owned en-GB keys provide stable descriptions for every canonical tool.
123
+ When discovery is built, description drift between those translations and the
124
+ pinned canonical registry fails closed. `@plasius/asset-contracts 0.3.1`
125
+ supplies the underlying model-resolution contract version; no model schema is
126
+ redeclared here.
127
+
68
128
  Token finance descriptors require the host to enforce the parent
69
129
  `economy.tokens.enabled` flag and the package-published
70
130
  `mcp.admin-economy-adjustments.enabled` flag. They declare the relevant
package/dist/index.cjs CHANGED
@@ -59,6 +59,11 @@ __export(index_exports, {
59
59
  MCP_ADMIN_FOUNDATION_ENV_VAR: () => MCP_ADMIN_FOUNDATION_ENV_VAR,
60
60
  MCP_ADMIN_FOUNDATION_FLAG_ID: () => MCP_ADMIN_FOUNDATION_FLAG_ID,
61
61
  MCP_ADMIN_LIVEOPS_FLAG_ID: () => MCP_ADMIN_LIVEOPS_FLAG_ID,
62
+ MCP_ADMIN_MODEL_CAPABILITIES: () => MCP_ADMIN_MODEL_CAPABILITIES,
63
+ MCP_ADMIN_MODEL_OAUTH_SCOPES: () => MCP_ADMIN_MODEL_OAUTH_SCOPES,
64
+ MCP_ADMIN_MODEL_REGISTRY_SOURCE: () => MCP_ADMIN_MODEL_REGISTRY_SOURCE,
65
+ MCP_ADMIN_MODEL_RESOLUTION_CONTRACT_VERSION: () => MCP_ADMIN_MODEL_RESOLUTION_CONTRACT_VERSION,
66
+ MCP_ADMIN_MODEL_TOOL_CONTRACT_VERSION: () => MCP_ADMIN_MODEL_TOOL_CONTRACT_VERSION,
62
67
  MCP_ADMIN_PRODUCTION_READINESS_ENV_VAR: () => MCP_ADMIN_PRODUCTION_READINESS_ENV_VAR,
63
68
  MCP_ADMIN_PRODUCTION_READINESS_FLAG_ID: () => MCP_ADMIN_PRODUCTION_READINESS_FLAG_ID,
64
69
  MCP_ADMIN_REGISTRY_SOURCE: () => MCP_ADMIN_REGISTRY_SOURCE,
@@ -72,6 +77,7 @@ __export(index_exports, {
72
77
  MCP_ADMIN_USER_AGGREGATION_DIMENSIONS: () => MCP_ADMIN_USER_AGGREGATION_DIMENSIONS,
73
78
  MCP_ADMIN_USER_AGGREGATION_METRICS: () => MCP_ADMIN_USER_AGGREGATION_METRICS,
74
79
  MCP_ADMIN_USER_AGGREGATION_PRESETS: () => MCP_ADMIN_USER_AGGREGATION_PRESETS,
80
+ MCP_ASSET_CATALOG_CONFIRM_CAPABILITY: () => MCP_ASSET_CATALOG_CONFIRM_CAPABILITY,
75
81
  MCP_ASSET_CATALOG_REQUEST_CAPABILITY: () => MCP_ASSET_CATALOG_REQUEST_CAPABILITY,
76
82
  MCP_ASSET_CATALOG_REVIEW_CAPABILITY: () => MCP_ASSET_CATALOG_REVIEW_CAPABILITY,
77
83
  MCP_ASSET_EXTERNAL_HARVEST_FLAG_ID: () => MCP_ASSET_EXTERNAL_HARVEST_FLAG_ID,
@@ -92,12 +98,16 @@ __export(index_exports, {
92
98
  buildMcpSurfaceUrls: () => buildMcpSurfaceUrls,
93
99
  getMcpAdminContractDefaultTranslation: () => getMcpAdminContractDefaultTranslation,
94
100
  listMcpActionSummaries: () => listMcpActionSummaries,
101
+ listMcpModelResourceTemplates: () => listMcpModelResourceTemplates,
102
+ listMcpModelToolSummaries: () => listMcpModelToolSummaries,
95
103
  mcpAdminContractDescriptionKeys: () => mcpAdminContractDescriptionKeys,
96
104
  mcpAdminContractsEnGbTranslations: () => mcpAdminContractsEnGbTranslations,
97
105
  mcpAdminContractsTranslations: () => mcpAdminContractsTranslations
98
106
  });
99
107
  module.exports = __toCommonJS(index_exports);
100
108
  var import_schema = require("@plasius/schema");
109
+ var import_asset_contracts = require("@plasius/asset-contracts");
110
+ var import_asset_mcp = require("@plasius/asset-mcp");
101
111
 
102
112
  // src/translations/en-GB.ts
103
113
  var mcpAdminContractsEnGbTranslations = {
@@ -144,6 +154,14 @@ var mcpAdminContractsEnGbTranslations = {
144
154
  "mcpAdminContracts.action.promoteAsset.description": "Promote an approved asset candidate to an immutable runtime manifest reference.",
145
155
  "mcpAdminContracts.action.rollbackAsset.description": "Rollback an asset runtime channel to a previous promoted manifest version.",
146
156
  "mcpAdminContracts.action.getAssetJobStatus.description": "Read governed asset job status, planned processing work, and evidence references.",
157
+ "mcpAdminContracts.action.listModelSearchRankers.description": "List allowlisted, calibrated model-search rankers and their current readiness without selecting a substitute.",
158
+ "mcpAdminContracts.action.searchModelCatalog.description": "Search promoted model catalog versions using hard constraints and one exact calibrated ranker selection.",
159
+ "mcpAdminContracts.action.resolveModelRequest.description": "Search the catalog and idempotently create asynchronous provider or generator fallback work when needed.",
160
+ "mcpAdminContracts.action.getModelResolution.description": "Read an owned immutable model-resolution revision, progress, questions, and review evidence.",
161
+ "mcpAdminContracts.action.confirmModelCandidate.description": "Confirm one exact four-view candidate; low assurance additionally requires explicit semantic-risk acceptance.",
162
+ "mcpAdminContracts.action.retryModelResolution.description": "Create the next immutable request revision from bounded refinement answers and candidate exclusions.",
163
+ "mcpAdminContracts.action.cancelModelResolution.description": "Idempotently cancel unfinished work owned by the requester.",
164
+ "mcpAdminContracts.action.rebuildModelCatalogIndex.description": "Run an operator-only idempotent full, backfill, or repair rebuild of the promoted model catalog index.",
147
165
  "mcpAdminContracts.action.getUserTokenWallet.description": "Read an account's server-resolved Token wallet summary without exposing provider or payment data.",
148
166
  "mcpAdminContracts.action.listUserTokenActivity.description": "Read a bounded, cursor-paginated Token activity history for one account.",
149
167
  "mcpAdminContracts.action.listTokenAdjustments.description": "List audited Token adjustment proposals and their approval state.",
@@ -206,6 +224,14 @@ var mcpAdminContractDescriptionKeys = {
206
224
  actionPromoteAsset: "mcpAdminContracts.action.promoteAsset.description",
207
225
  actionRollbackAsset: "mcpAdminContracts.action.rollbackAsset.description",
208
226
  actionGetAssetJobStatus: "mcpAdminContracts.action.getAssetJobStatus.description",
227
+ actionListModelSearchRankers: "mcpAdminContracts.action.listModelSearchRankers.description",
228
+ actionSearchModelCatalog: "mcpAdminContracts.action.searchModelCatalog.description",
229
+ actionResolveModelRequest: "mcpAdminContracts.action.resolveModelRequest.description",
230
+ actionGetModelResolution: "mcpAdminContracts.action.getModelResolution.description",
231
+ actionConfirmModelCandidate: "mcpAdminContracts.action.confirmModelCandidate.description",
232
+ actionRetryModelResolution: "mcpAdminContracts.action.retryModelResolution.description",
233
+ actionCancelModelResolution: "mcpAdminContracts.action.cancelModelResolution.description",
234
+ actionRebuildModelCatalogIndex: "mcpAdminContracts.action.rebuildModelCatalogIndex.description",
209
235
  actionGetUserTokenWallet: "mcpAdminContracts.action.getUserTokenWallet.description",
210
236
  actionListUserTokenActivity: "mcpAdminContracts.action.listUserTokenActivity.description",
211
237
  actionListTokenAdjustments: "mcpAdminContracts.action.listTokenAdjustments.description",
@@ -230,7 +256,7 @@ function getMcpAdminContractDefaultTranslation(key) {
230
256
  }
231
257
 
232
258
  // src/index.ts
233
- var MCP_ADMIN_CONTRACT_VERSION = "2026-08-11.v6";
259
+ var MCP_ADMIN_CONTRACT_VERSION = "2026-08-20.v7";
234
260
  var MCP_ADMIN_REGISTRY_SOURCE = "@plasius/mcp-admin-contracts";
235
261
  var MCP_ADMIN_FOUNDATION_FLAG_ID = "mcp.admin.foundation.enabled";
236
262
  var MCP_ACCESS_SCOPE = "mcp:access";
@@ -246,10 +272,30 @@ var MCP_ADMIN_PRODUCTION_READINESS_FLAG_ID = "mcp.admin.production-readiness.ena
246
272
  var MCP_ADMIN_PRODUCTION_READINESS_ENV_VAR = "MCP_ADMIN_PRODUCTION_READINESS_ENABLED";
247
273
  var MCP_ASSET_PIPELINE_FLAG_ID = "asset.pipeline.unified-ai-assets.enabled";
248
274
  var MCP_ASSET_EXTERNAL_HARVEST_FLAG_ID = "asset.pipeline.external-model-harvest.enabled";
249
- var MCP_ASSET_CATALOG_REQUEST_CAPABILITY = "asset.catalog.request";
250
- var MCP_ASSET_PIPELINE_MANAGE_CAPABILITY = "asset.pipeline.mcp.manage";
251
- var MCP_ASSET_SOURCE_MANAGE_CAPABILITY = "asset.source.manage";
252
- var MCP_ASSET_CATALOG_REVIEW_CAPABILITY = "asset.catalog.review";
275
+ var MCP_ASSET_CATALOG_REQUEST_CAPABILITY = import_asset_mcp.MODEL_MCP_CATALOG_REQUEST_CAPABILITY;
276
+ var MCP_ASSET_CATALOG_CONFIRM_CAPABILITY = import_asset_mcp.MODEL_MCP_CATALOG_CONFIRM_CAPABILITY;
277
+ var MCP_ASSET_PIPELINE_MANAGE_CAPABILITY = import_asset_mcp.MODEL_MCP_PIPELINE_MANAGE_CAPABILITY;
278
+ var MCP_ASSET_SOURCE_MANAGE_CAPABILITY = import_asset_mcp.MODEL_MCP_SOURCE_MANAGE_CAPABILITY;
279
+ var MCP_ASSET_CATALOG_REVIEW_CAPABILITY = import_asset_mcp.MODEL_MCP_CATALOG_REVIEW_CAPABILITY;
280
+ var MCP_ADMIN_MODEL_TOOL_CONTRACT_VERSION = import_asset_mcp.MODEL_MCP_CONTRACT_VERSION;
281
+ var MCP_ADMIN_MODEL_REGISTRY_SOURCE = import_asset_mcp.ASSET_MCP_PACKAGE;
282
+ var MCP_ADMIN_MODEL_RESOLUTION_CONTRACT_VERSION = import_asset_contracts.MODEL_RESOLUTION_CONTRACT_VERSION;
283
+ var MCP_ADMIN_MODEL_CAPABILITIES = Object.freeze({
284
+ catalogRequest: import_asset_mcp.MODEL_MCP_CATALOG_REQUEST_CAPABILITY,
285
+ catalogConfirm: import_asset_mcp.MODEL_MCP_CATALOG_CONFIRM_CAPABILITY,
286
+ catalogReview: import_asset_mcp.MODEL_MCP_CATALOG_REVIEW_CAPABILITY,
287
+ sourceManage: import_asset_mcp.MODEL_MCP_SOURCE_MANAGE_CAPABILITY,
288
+ pipelineManage: import_asset_mcp.MODEL_MCP_PIPELINE_MANAGE_CAPABILITY
289
+ });
290
+ var MCP_ADMIN_MODEL_OAUTH_SCOPES = Object.freeze([
291
+ MCP_ACCESS_SCOPE,
292
+ import_asset_mcp.MODEL_MCP_CATALOG_REQUEST_CAPABILITY,
293
+ import_asset_mcp.MODEL_MCP_CATALOG_CONFIRM_CAPABILITY,
294
+ import_asset_mcp.MODEL_MCP_CATALOG_REVIEW_CAPABILITY,
295
+ import_asset_mcp.MODEL_MCP_SOURCE_MANAGE_CAPABILITY,
296
+ import_asset_mcp.MODEL_MCP_PIPELINE_MANAGE_CAPABILITY
297
+ ]);
298
+ var canonicalModelToolDefinitions = (0, import_asset_mcp.listModelMcpToolDefinitions)();
253
299
  var MCP_ADMIN_FEEDBACK_FLAG_ID = "feedback.mcp.enabled";
254
300
  var MCP_ADMIN_FEEDBACK_READ_CAPABILITY = "admin.feedback.read";
255
301
  var MCP_ADMIN_BASE_OAUTH_SCOPE = MCP_ACCESS_SCOPE;
@@ -3493,6 +3539,100 @@ var MCP_ADMIN_ACTIONS = [
3493
3539
  },
3494
3540
  ...MCP_ADMIN_FEEDBACK_ACTIONS
3495
3541
  ];
3542
+ var modelDescriptionKeys = {
3543
+ list_model_search_rankers: mcpAdminContractDescriptionKeys.actionListModelSearchRankers,
3544
+ search_model_catalog: mcpAdminContractDescriptionKeys.actionSearchModelCatalog,
3545
+ resolve_model_request: mcpAdminContractDescriptionKeys.actionResolveModelRequest,
3546
+ get_model_resolution: mcpAdminContractDescriptionKeys.actionGetModelResolution,
3547
+ confirm_model_candidate: mcpAdminContractDescriptionKeys.actionConfirmModelCandidate,
3548
+ retry_model_resolution: mcpAdminContractDescriptionKeys.actionRetryModelResolution,
3549
+ cancel_model_resolution: mcpAdminContractDescriptionKeys.actionCancelModelResolution,
3550
+ rebuild_model_catalog_index: mcpAdminContractDescriptionKeys.actionRebuildModelCatalogIndex
3551
+ };
3552
+ var modelVerificationNotes = deepFreeze({
3553
+ list_model_search_rankers: [
3554
+ "Validate the returned ranker list and no-substitution policy against the canonical output schema."
3555
+ ],
3556
+ search_model_catalog: [
3557
+ "Validate ranked catalog evidence and any four-view image pack against the canonical structured output schema."
3558
+ ],
3559
+ resolve_model_request: [
3560
+ "Use get_model_resolution with the returned resolution identifier to verify durable progress and candidate evidence."
3561
+ ],
3562
+ get_model_resolution: [
3563
+ "Validate the owned immutable revision, state, questions, and any four-view image pack against the canonical output schema."
3564
+ ],
3565
+ confirm_model_candidate: [
3566
+ "Use get_model_resolution to verify completion and the immutable final asset reference after confirmation."
3567
+ ],
3568
+ retry_model_resolution: [
3569
+ "Use get_model_resolution to verify the newly created immutable request revision and excluded candidates."
3570
+ ],
3571
+ cancel_model_resolution: [
3572
+ "Use get_model_resolution to verify that unfinished requester-owned work reached the cancelled state."
3573
+ ],
3574
+ rebuild_model_catalog_index: [
3575
+ "Validate the idempotent operation identifier and state against the canonical output schema and operator audit record."
3576
+ ]
3577
+ });
3578
+ var modelToolExecution = (toolName) => ({
3579
+ protocol: "json-rpc-2.0",
3580
+ method: "POST",
3581
+ path: "/api/mcp",
3582
+ rpcMethod: "tools/call",
3583
+ toolName
3584
+ });
3585
+ var modelToolTranslation = (definition) => {
3586
+ const translation = translatedDescription(modelDescriptionKeys[definition.name]);
3587
+ if (translation.descriptionDefault !== definition.description) {
3588
+ throw new TypeError("Canonical model tool description translation mismatch.");
3589
+ }
3590
+ return translation;
3591
+ };
3592
+ function listMcpModelToolSummaries() {
3593
+ return canonicalModelToolDefinitions.map((definition) => {
3594
+ const { inputSchema: _inputSchema, outputSchema: _outputSchema, ...summary } = definition;
3595
+ return {
3596
+ ...summary,
3597
+ ...modelToolTranslation(definition),
3598
+ availability: "near-future",
3599
+ execution: modelToolExecution(definition.name),
3600
+ verificationNotes: modelVerificationNotes[definition.name]
3601
+ };
3602
+ });
3603
+ }
3604
+ function listMcpModelResourceTemplates() {
3605
+ return (0, import_asset_mcp.listModelMcpResourceTemplates)();
3606
+ }
3607
+ var buildMcpModelToolSchemaDescriptors = () => Object.fromEntries(
3608
+ canonicalModelToolDefinitions.map((definition) => [
3609
+ definition.name,
3610
+ {
3611
+ ...definition,
3612
+ ...modelToolTranslation(definition),
3613
+ availability: "near-future",
3614
+ execution: modelToolExecution(definition.name),
3615
+ verificationNotes: modelVerificationNotes[definition.name]
3616
+ }
3617
+ ])
3618
+ );
3619
+ var buildMcpModelResolutionContext = () => ({
3620
+ toolContractVersion: import_asset_mcp.MODEL_MCP_CONTRACT_VERSION,
3621
+ sourceOfTruth: import_asset_mcp.ASSET_MCP_PACKAGE,
3622
+ resolutionContractVersion: import_asset_contracts.MODEL_RESOLUTION_CONTRACT_VERSION,
3623
+ endpoint: "/api/mcp",
3624
+ protocol: "json-rpc-2.0",
3625
+ rpcMethod: "tools/call",
3626
+ requiredFeatureFlag: import_asset_mcp.MODEL_MCP_UNIFIED_FEATURE_FLAG_ID,
3627
+ conditionalFeatureFlags: [
3628
+ import_asset_mcp.MODEL_MCP_EXTERNAL_HARVEST_FEATURE_FLAG_ID,
3629
+ import_asset_mcp.MODEL_MCP_GENERATION_FEATURE_FLAG_ID
3630
+ ],
3631
+ tools: [...import_asset_mcp.MODEL_MCP_TOOL_NAMES],
3632
+ resourceTemplates: (0, import_asset_mcp.listModelMcpResourceTemplates)().map(
3633
+ ({ uriTemplate }) => uriTemplate
3634
+ )
3635
+ });
3496
3636
  function listMcpActionSummaries() {
3497
3637
  return MCP_ADMIN_ACTIONS.map((action) => ({
3498
3638
  name: action.name,
@@ -3511,7 +3651,7 @@ function listMcpActionSummaries() {
3511
3651
  access: action.access
3512
3652
  }));
3513
3653
  }
3514
- var MCP_ADMIN_CONTEXT_SHAPE = {
3654
+ var MCP_ADMIN_CONTEXT_SHAPE = deepFreeze({
3515
3655
  contractVersion: stringField("Versioned discovery contract identifier."),
3516
3656
  authenticatedUser: objectField("Authenticated admin session context.", {
3517
3657
  id: stringField("Authenticated user identifier."),
@@ -3537,6 +3677,44 @@ var MCP_ADMIN_CONTEXT_SHAPE = {
3537
3677
  )
3538
3678
  }),
3539
3679
  actionFamilies: arrayField("Approved action families grouped by rollout domain.", "McpActionFamily"),
3680
+ modelResolution: objectField(
3681
+ "Canonical model-resolution JSON-RPC discovery metadata.",
3682
+ {
3683
+ toolContractVersion: stringField(
3684
+ "Contract version imported from @plasius/asset-mcp.",
3685
+ { constValue: import_asset_mcp.MODEL_MCP_CONTRACT_VERSION }
3686
+ ),
3687
+ sourceOfTruth: stringField("Package that owns the canonical tool registry.", {
3688
+ constValue: import_asset_mcp.ASSET_MCP_PACKAGE
3689
+ }),
3690
+ resolutionContractVersion: stringField(
3691
+ "Resolution contract version imported from @plasius/asset-contracts.",
3692
+ { constValue: import_asset_contracts.MODEL_RESOLUTION_CONTRACT_VERSION }
3693
+ ),
3694
+ endpoint: stringField("Hosted MCP JSON-RPC endpoint.", {
3695
+ constValue: "/api/mcp"
3696
+ }),
3697
+ protocol: stringField("MCP transport protocol.", {
3698
+ constValue: "json-rpc-2.0"
3699
+ }),
3700
+ rpcMethod: stringField("JSON-RPC method used to execute a named tool.", {
3701
+ constValue: "tools/call"
3702
+ }),
3703
+ requiredFeatureFlag: stringField(
3704
+ "Parent rollout flag required for every model-resolution tool.",
3705
+ { constValue: import_asset_mcp.MODEL_MCP_UNIFIED_FEATURE_FLAG_ID }
3706
+ ),
3707
+ conditionalFeatureFlags: arrayField(
3708
+ "Provider and generator flags evaluated only when their fallback is attempted.",
3709
+ "string"
3710
+ ),
3711
+ tools: arrayField("Canonical snake_case model-resolution tool names.", "string"),
3712
+ resourceTemplates: arrayField(
3713
+ "Authenticated canonical mcp://models resource templates.",
3714
+ "string"
3715
+ )
3716
+ }
3717
+ ),
3540
3718
  extensionRules: objectField("Rules for extending the registry without changing the discovery shape.", {
3541
3719
  sourceOfTruth: stringField("Package that owns the approved MCP registry."),
3542
3720
  addOnlyWithinV1: booleanField("Whether v1 additions must be additive."),
@@ -3544,7 +3722,7 @@ var MCP_ADMIN_CONTEXT_SHAPE = {
3544
3722
  singleResourceMutations: booleanField("Whether mutations must target one resource at a time."),
3545
3723
  notes: arrayField("Extension notes for future MCP tool families.", "string")
3546
3724
  })
3547
- };
3725
+ });
3548
3726
  var MCP_ADMIN_EXTENSION_RULES = {
3549
3727
  sourceOfTruth: MCP_ADMIN_REGISTRY_SOURCE,
3550
3728
  addOnlyWithinV1: true,
@@ -3600,7 +3778,10 @@ function buildMcpDiscoveryResponse() {
3600
3778
  return {
3601
3779
  contractVersion: MCP_ADMIN_CONTRACT_VERSION,
3602
3780
  sourceOfTruth: MCP_ADMIN_REGISTRY_SOURCE,
3603
- actions: listMcpActionSummaries()
3781
+ actions: listMcpActionSummaries(),
3782
+ modelTools: listMcpModelToolSummaries(),
3783
+ modelResources: listMcpModelResourceTemplates(),
3784
+ modelSourceOfTruth: import_asset_mcp.ASSET_MCP_PACKAGE
3604
3785
  };
3605
3786
  }
3606
3787
  function buildMcpSchemaResponse() {
@@ -3629,7 +3810,10 @@ function buildMcpSchemaResponse() {
3629
3810
  sourceOfTruth: MCP_ADMIN_REGISTRY_SOURCE,
3630
3811
  actions,
3631
3812
  contextShape: MCP_ADMIN_CONTEXT_SHAPE,
3632
- extensionRules: MCP_ADMIN_EXTENSION_RULES
3813
+ extensionRules: MCP_ADMIN_EXTENSION_RULES,
3814
+ modelTools: buildMcpModelToolSchemaDescriptors(),
3815
+ modelResources: listMcpModelResourceTemplates(),
3816
+ modelSourceOfTruth: import_asset_mcp.ASSET_MCP_PACKAGE
3633
3817
  };
3634
3818
  }
3635
3819
  function buildMcpContextResponse(options) {
@@ -3639,7 +3823,8 @@ function buildMcpContextResponse(options) {
3639
3823
  surface: buildMcpSurfaceUrls(options.origin),
3640
3824
  rollout: options.rollout,
3641
3825
  actionFamilies: buildMcpActionFamilies(),
3642
- extensionRules: MCP_ADMIN_EXTENSION_RULES
3826
+ extensionRules: MCP_ADMIN_EXTENSION_RULES,
3827
+ modelResolution: buildMcpModelResolutionContext()
3643
3828
  };
3644
3829
  }
3645
3830
  function buildMcpActionFamilies() {
@@ -3775,6 +3960,11 @@ function normalizeOptionalString(value) {
3775
3960
  MCP_ADMIN_FOUNDATION_ENV_VAR,
3776
3961
  MCP_ADMIN_FOUNDATION_FLAG_ID,
3777
3962
  MCP_ADMIN_LIVEOPS_FLAG_ID,
3963
+ MCP_ADMIN_MODEL_CAPABILITIES,
3964
+ MCP_ADMIN_MODEL_OAUTH_SCOPES,
3965
+ MCP_ADMIN_MODEL_REGISTRY_SOURCE,
3966
+ MCP_ADMIN_MODEL_RESOLUTION_CONTRACT_VERSION,
3967
+ MCP_ADMIN_MODEL_TOOL_CONTRACT_VERSION,
3778
3968
  MCP_ADMIN_PRODUCTION_READINESS_ENV_VAR,
3779
3969
  MCP_ADMIN_PRODUCTION_READINESS_FLAG_ID,
3780
3970
  MCP_ADMIN_REGISTRY_SOURCE,
@@ -3788,6 +3978,7 @@ function normalizeOptionalString(value) {
3788
3978
  MCP_ADMIN_USER_AGGREGATION_DIMENSIONS,
3789
3979
  MCP_ADMIN_USER_AGGREGATION_METRICS,
3790
3980
  MCP_ADMIN_USER_AGGREGATION_PRESETS,
3981
+ MCP_ASSET_CATALOG_CONFIRM_CAPABILITY,
3791
3982
  MCP_ASSET_CATALOG_REQUEST_CAPABILITY,
3792
3983
  MCP_ASSET_CATALOG_REVIEW_CAPABILITY,
3793
3984
  MCP_ASSET_EXTERNAL_HARVEST_FLAG_ID,
@@ -3808,6 +3999,8 @@ function normalizeOptionalString(value) {
3808
3999
  buildMcpSurfaceUrls,
3809
4000
  getMcpAdminContractDefaultTranslation,
3810
4001
  listMcpActionSummaries,
4002
+ listMcpModelResourceTemplates,
4003
+ listMcpModelToolSummaries,
3811
4004
  mcpAdminContractDescriptionKeys,
3812
4005
  mcpAdminContractsEnGbTranslations,
3813
4006
  mcpAdminContractsTranslations