@microsoft/teamsfx-core 3.1.0 → 3.1.2-alpha.31d08fb48a.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.
Files changed (973) hide show
  1. package/build/client/aadAppClient.d.ts +0 -6
  2. package/build/client/aadAppClient.d.ts.map +1 -1
  3. package/build/client/aadAppClient.js +8 -6
  4. package/build/client/aadAppClient.js.map +1 -1
  5. package/build/client/graphClient.d.ts +4 -4
  6. package/build/client/graphClient.d.ts.map +1 -1
  7. package/build/client/graphClient.js +91 -23
  8. package/build/client/graphClient.js.map +1 -1
  9. package/build/client/teamsDevPortalClient.d.ts +3 -7
  10. package/build/client/teamsDevPortalClient.d.ts.map +1 -1
  11. package/build/client/teamsDevPortalClient.js +101 -122
  12. package/build/client/teamsDevPortalClient.js.map +1 -1
  13. package/build/client/teamsGraphClient.d.ts +20 -0
  14. package/build/client/teamsGraphClient.d.ts.map +1 -0
  15. package/build/client/teamsGraphClient.js +152 -0
  16. package/build/client/teamsGraphClient.js.map +1 -0
  17. package/build/common/accountUtils.d.ts +3 -2
  18. package/build/common/accountUtils.d.ts.map +1 -1
  19. package/build/common/accountUtils.js +7 -2
  20. package/build/common/accountUtils.js.map +1 -1
  21. package/build/common/cancellation.d.ts +5 -0
  22. package/build/common/cancellation.d.ts.map +1 -0
  23. package/build/common/cancellation.js +17 -0
  24. package/build/common/cancellation.js.map +1 -0
  25. package/build/common/constants.d.ts +5 -1
  26. package/build/common/constants.d.ts.map +1 -1
  27. package/build/common/constants.js +20 -5
  28. package/build/common/constants.js.map +1 -1
  29. package/build/common/daSpecParser.d.ts +2 -1
  30. package/build/common/daSpecParser.d.ts.map +1 -1
  31. package/build/common/daSpecParser.js +214 -21
  32. package/build/common/daSpecParser.js.map +1 -1
  33. package/build/common/featureFlags.d.ts +22 -5
  34. package/build/common/featureFlags.d.ts.map +1 -1
  35. package/build/common/featureFlags.js +40 -9
  36. package/build/common/featureFlags.js.map +1 -1
  37. package/build/common/fetchHelper.d.ts.map +1 -1
  38. package/build/common/fetchHelper.js +41 -3
  39. package/build/common/fetchHelper.js.map +1 -1
  40. package/build/common/globalVars.d.ts +1 -1
  41. package/build/common/globalVars.d.ts.map +1 -1
  42. package/build/common/globalVars.js.map +1 -1
  43. package/build/common/httpProxy.d.ts +21 -0
  44. package/build/common/httpProxy.d.ts.map +1 -0
  45. package/build/common/httpProxy.js +117 -0
  46. package/build/common/httpProxy.js.map +1 -0
  47. package/build/common/kiotaClient.d.ts +3 -3
  48. package/build/common/kiotaClient.d.ts.map +1 -1
  49. package/build/common/kiotaClient.js +10 -10
  50. package/build/common/kiotaClient.js.map +1 -1
  51. package/build/common/mcpToolFetcher.d.ts +90 -0
  52. package/build/common/mcpToolFetcher.d.ts.map +1 -0
  53. package/build/common/mcpToolFetcher.js +424 -0
  54. package/build/common/mcpToolFetcher.js.map +1 -0
  55. package/build/common/odrProvider.d.ts +43 -0
  56. package/build/common/odrProvider.d.ts.map +1 -0
  57. package/build/common/odrProvider.js +154 -0
  58. package/build/common/odrProvider.js.map +1 -0
  59. package/build/common/openApiParserOptions.d.ts +3 -0
  60. package/build/common/openApiParserOptions.d.ts.map +1 -0
  61. package/build/common/openApiParserOptions.js +61 -0
  62. package/build/common/openApiParserOptions.js.map +1 -0
  63. package/build/common/permissionInterface.d.ts +12 -3
  64. package/build/common/permissionInterface.d.ts.map +1 -1
  65. package/build/common/permissionInterface.js +7 -1
  66. package/build/common/permissionInterface.js.map +1 -1
  67. package/build/common/projectSettingsHelper.d.ts +0 -2
  68. package/build/common/projectSettingsHelper.d.ts.map +1 -1
  69. package/build/common/projectSettingsHelper.js +1 -59
  70. package/build/common/projectSettingsHelper.js.map +1 -1
  71. package/build/common/retryHandler.d.ts +5 -0
  72. package/build/common/retryHandler.d.ts.map +1 -0
  73. package/build/common/retryHandler.js +27 -0
  74. package/build/common/retryHandler.js.map +1 -0
  75. package/build/common/samples.d.ts +1 -1
  76. package/build/common/samples.js +1 -1
  77. package/build/common/secretmasker/dict.d.ts.map +1 -1
  78. package/build/common/secretmasker/dict.js +5 -2
  79. package/build/common/secretmasker/dict.js.map +1 -1
  80. package/build/common/secretmasker/feature.js.map +1 -1
  81. package/build/common/teamsGraphApiNames.d.ts +10 -0
  82. package/build/common/teamsGraphApiNames.d.ts.map +1 -0
  83. package/build/common/teamsGraphApiNames.js +16 -0
  84. package/build/common/teamsGraphApiNames.js.map +1 -0
  85. package/build/common/telemetry.d.ts +6 -15
  86. package/build/common/telemetry.d.ts.map +1 -1
  87. package/build/common/telemetry.js +9 -20
  88. package/build/common/telemetry.js.map +1 -1
  89. package/build/common/templates-config.json +10 -3
  90. package/build/common/tools.d.ts +1 -1
  91. package/build/common/tools.d.ts.map +1 -1
  92. package/build/common/tools.js +6 -6
  93. package/build/common/tools.js.map +1 -1
  94. package/build/common/treatmentVariables.d.ts +5 -0
  95. package/build/common/treatmentVariables.d.ts.map +1 -0
  96. package/build/common/treatmentVariables.js +10 -0
  97. package/build/common/treatmentVariables.js.map +1 -0
  98. package/build/common/wrappedAxiosClient.d.ts +11 -2
  99. package/build/common/wrappedAxiosClient.d.ts.map +1 -1
  100. package/build/common/wrappedAxiosClient.js +147 -59
  101. package/build/common/wrappedAxiosClient.js.map +1 -1
  102. package/build/component/configManager/actionInjector.d.ts +16 -1
  103. package/build/component/configManager/actionInjector.d.ts.map +1 -1
  104. package/build/component/configManager/actionInjector.js +106 -1
  105. package/build/component/configManager/actionInjector.js.map +1 -1
  106. package/build/component/configManager/lifecycle.d.ts +2 -2
  107. package/build/component/configManager/lifecycle.d.ts.map +1 -1
  108. package/build/component/configManager/lifecycle.js +38 -9
  109. package/build/component/configManager/lifecycle.js.map +1 -1
  110. package/build/component/configManager/parser.js.map +1 -1
  111. package/build/component/configManager/validator.d.ts.map +1 -1
  112. package/build/component/configManager/validator.js +2 -0
  113. package/build/component/configManager/validator.js.map +1 -1
  114. package/build/component/coordinator/index.d.ts.map +1 -1
  115. package/build/component/coordinator/index.js +13 -11
  116. package/build/component/coordinator/index.js.map +1 -1
  117. package/build/component/deps-checker/internal/dotnetChecker.js.map +1 -1
  118. package/build/component/deps-checker/internal/funcToolChecker.js +6 -7
  119. package/build/component/deps-checker/internal/funcToolChecker.js.map +1 -1
  120. package/build/component/deps-checker/internal/nodeChecker.js +1 -1
  121. package/build/component/deps-checker/internal/nodeChecker.js.map +1 -1
  122. package/build/component/deps-checker/internal/testToolChecker.js +13 -13
  123. package/build/component/deps-checker/internal/testToolChecker.js.map +1 -1
  124. package/build/component/developerPortalScaffoldUtils.d.ts.map +1 -1
  125. package/build/component/developerPortalScaffoldUtils.js +5 -5
  126. package/build/component/developerPortalScaffoldUtils.js.map +1 -1
  127. package/build/component/driver/aad/utility/aadManifestHelper.d.ts +1 -1
  128. package/build/component/driver/aad/utility/aadManifestHelper.d.ts.map +1 -1
  129. package/build/component/driver/aad/utility/aadManifestHelper.js +7 -4
  130. package/build/component/driver/aad/utility/aadManifestHelper.js.map +1 -1
  131. package/build/component/driver/add/addWebPart.js +3 -3
  132. package/build/component/driver/add/addWebPart.js.map +1 -1
  133. package/build/component/driver/apiKey/create.d.ts.map +1 -1
  134. package/build/component/driver/apiKey/create.js +4 -4
  135. package/build/component/driver/apiKey/create.js.map +1 -1
  136. package/build/component/driver/apiKey/update.d.ts.map +1 -1
  137. package/build/component/driver/apiKey/update.js +4 -4
  138. package/build/component/driver/apiKey/update.js.map +1 -1
  139. package/build/component/driver/arm/util/handleError.js +5 -4
  140. package/build/component/driver/arm/util/handleError.js.map +1 -1
  141. package/build/component/driver/botAadApp/create.js +1 -1
  142. package/build/component/driver/botAadApp/create.js.map +1 -1
  143. package/build/component/driver/copilotAgent/interfaces/PublishArgs.d.ts +14 -0
  144. package/build/component/driver/copilotAgent/interfaces/PublishArgs.d.ts.map +1 -0
  145. package/build/component/driver/copilotAgent/interfaces/PublishArgs.js +5 -0
  146. package/build/component/driver/copilotAgent/interfaces/PublishArgs.js.map +1 -0
  147. package/build/component/driver/copilotAgent/publish.d.ts +16 -0
  148. package/build/component/driver/copilotAgent/publish.d.ts.map +1 -0
  149. package/build/component/driver/copilotAgent/publish.js +175 -0
  150. package/build/component/driver/copilotAgent/publish.js.map +1 -0
  151. package/build/component/driver/dcr/create.d.ts +10 -0
  152. package/build/component/driver/dcr/create.d.ts.map +1 -0
  153. package/build/component/driver/dcr/create.js +142 -0
  154. package/build/component/driver/dcr/create.js.map +1 -0
  155. package/build/component/driver/dcr/error/dcrNameTooLong.d.ts +5 -0
  156. package/build/component/driver/dcr/error/dcrNameTooLong.d.ts.map +1 -0
  157. package/build/component/driver/dcr/error/dcrNameTooLong.js +21 -0
  158. package/build/component/driver/dcr/error/dcrNameTooLong.js.map +1 -0
  159. package/build/component/driver/dcr/error/dcrWellKnownInvalid.d.ts +5 -0
  160. package/build/component/driver/dcr/error/dcrWellKnownInvalid.d.ts.map +1 -0
  161. package/build/component/driver/dcr/error/dcrWellKnownInvalid.js +21 -0
  162. package/build/component/driver/dcr/error/dcrWellKnownInvalid.js.map +1 -0
  163. package/build/component/driver/dcr/interface/createDcrArgs.d.ts +9 -0
  164. package/build/component/driver/dcr/interface/createDcrArgs.d.ts.map +1 -0
  165. package/build/component/driver/dcr/interface/createDcrArgs.js +5 -0
  166. package/build/component/driver/dcr/interface/createDcrArgs.js.map +1 -0
  167. package/build/component/driver/dcr/interface/createDcrOutputs.d.ts +7 -0
  168. package/build/component/driver/dcr/interface/createDcrOutputs.d.ts.map +1 -0
  169. package/build/component/driver/dcr/interface/createDcrOutputs.js +10 -0
  170. package/build/component/driver/dcr/interface/createDcrOutputs.js.map +1 -0
  171. package/build/component/driver/dcr/utility/constants.d.ts +7 -0
  172. package/build/component/driver/dcr/utility/constants.d.ts.map +1 -0
  173. package/build/component/driver/dcr/utility/constants.js +12 -0
  174. package/build/component/driver/dcr/utility/constants.js.map +1 -0
  175. package/build/component/driver/deploy/azure/azureStaticWebAppGetDeploymentTokenDriver.d.ts +3 -1
  176. package/build/component/driver/deploy/azure/azureStaticWebAppGetDeploymentTokenDriver.d.ts.map +1 -1
  177. package/build/component/driver/deploy/azure/azureStaticWebAppGetDeploymentTokenDriver.js +12 -9
  178. package/build/component/driver/deploy/azure/azureStaticWebAppGetDeploymentTokenDriver.js.map +1 -1
  179. package/build/component/driver/deploy/azure/impl/AzureZipDeployImpl.d.ts +3 -0
  180. package/build/component/driver/deploy/azure/impl/AzureZipDeployImpl.d.ts.map +1 -1
  181. package/build/component/driver/deploy/azure/impl/AzureZipDeployImpl.js +39 -4
  182. package/build/component/driver/deploy/azure/impl/AzureZipDeployImpl.js.map +1 -1
  183. package/build/component/driver/deploy/azure/impl/azureDeployImpl.js +2 -2
  184. package/build/component/driver/deploy/azure/impl/azureDeployImpl.js.map +1 -1
  185. package/build/component/driver/devTool/httpClient.d.ts +4 -0
  186. package/build/component/driver/devTool/httpClient.d.ts.map +1 -1
  187. package/build/component/driver/devTool/httpClient.js +6 -3
  188. package/build/component/driver/devTool/httpClient.js.map +1 -1
  189. package/build/component/driver/index.d.ts +2 -0
  190. package/build/component/driver/index.d.ts.map +1 -1
  191. package/build/component/driver/index.js +2 -0
  192. package/build/component/driver/index.js.map +1 -1
  193. package/build/component/driver/interface/buildAndDeployArgs.d.ts +1 -1
  194. package/build/component/driver/interface/buildAndDeployArgs.d.ts.map +1 -1
  195. package/build/component/driver/interface/commonArgs.d.ts +2 -1
  196. package/build/component/driver/interface/commonArgs.d.ts.map +1 -1
  197. package/build/component/driver/m365/acquire.d.ts.map +1 -1
  198. package/build/component/driver/m365/acquire.js +4 -3
  199. package/build/component/driver/m365/acquire.js.map +1 -1
  200. package/build/component/driver/oauth/create.d.ts.map +1 -1
  201. package/build/component/driver/oauth/create.js +5 -4
  202. package/build/component/driver/oauth/create.js.map +1 -1
  203. package/build/component/driver/oauth/update.d.ts.map +1 -1
  204. package/build/component/driver/oauth/update.js +5 -5
  205. package/build/component/driver/oauth/update.js.map +1 -1
  206. package/build/component/driver/script/baseBuildDriver.d.ts +1 -2
  207. package/build/component/driver/script/baseBuildDriver.d.ts.map +1 -1
  208. package/build/component/driver/script/baseBuildDriver.js +0 -2
  209. package/build/component/driver/script/baseBuildDriver.js.map +1 -1
  210. package/build/component/driver/script/scriptDriver.d.ts.map +1 -1
  211. package/build/component/driver/script/scriptDriver.js +3 -2
  212. package/build/component/driver/script/scriptDriver.js.map +1 -1
  213. package/build/component/driver/share/utils.d.ts.map +1 -1
  214. package/build/component/driver/share/utils.js +9 -7
  215. package/build/component/driver/share/utils.js.map +1 -1
  216. package/build/component/driver/teamsApp/appStudio.d.ts.map +1 -1
  217. package/build/component/driver/teamsApp/appStudio.js +1 -1
  218. package/build/component/driver/teamsApp/appStudio.js.map +1 -1
  219. package/build/component/driver/teamsApp/configure.d.ts.map +1 -1
  220. package/build/component/driver/teamsApp/configure.js +7 -0
  221. package/build/component/driver/teamsApp/configure.js.map +1 -1
  222. package/build/component/driver/teamsApp/constants.d.ts +9 -3
  223. package/build/component/driver/teamsApp/constants.d.ts.map +1 -1
  224. package/build/component/driver/teamsApp/constants.js +11 -4
  225. package/build/component/driver/teamsApp/constants.js.map +1 -1
  226. package/build/component/driver/teamsApp/create.d.ts.map +1 -1
  227. package/build/component/driver/teamsApp/create.js +19 -1
  228. package/build/component/driver/teamsApp/create.js.map +1 -1
  229. package/build/component/driver/teamsApp/createAppPackage.d.ts +10 -0
  230. package/build/component/driver/teamsApp/createAppPackage.d.ts.map +1 -1
  231. package/build/component/driver/teamsApp/createAppPackage.js +383 -70
  232. package/build/component/driver/teamsApp/createAppPackage.js.map +1 -1
  233. package/build/component/driver/teamsApp/interfaces/DcrRegistration.d.ts +10 -0
  234. package/build/component/driver/teamsApp/interfaces/DcrRegistration.d.ts.map +1 -0
  235. package/build/component/driver/teamsApp/interfaces/DcrRegistration.js +5 -0
  236. package/build/component/driver/teamsApp/interfaces/DcrRegistration.js.map +1 -0
  237. package/build/component/driver/teamsApp/interfaces/OauthRegistration.d.ts +4 -0
  238. package/build/component/driver/teamsApp/interfaces/OauthRegistration.d.ts.map +1 -1
  239. package/build/component/driver/teamsApp/interfaces/OauthRegistration.js.map +1 -1
  240. package/build/component/driver/teamsApp/interfaces/ValidationResult.d.ts +6 -0
  241. package/build/component/driver/teamsApp/interfaces/ValidationResult.d.ts.map +1 -1
  242. package/build/component/driver/teamsApp/publishAppPackage.d.ts +0 -2
  243. package/build/component/driver/teamsApp/publishAppPackage.d.ts.map +1 -1
  244. package/build/component/driver/teamsApp/publishAppPackage.js +19 -60
  245. package/build/component/driver/teamsApp/publishAppPackage.js.map +1 -1
  246. package/build/component/driver/teamsApp/syncManifest.d.ts +3 -3
  247. package/build/component/driver/teamsApp/syncManifest.d.ts.map +1 -1
  248. package/build/component/driver/teamsApp/syncManifest.js +8 -8
  249. package/build/component/driver/teamsApp/syncManifest.js.map +1 -1
  250. package/build/component/driver/teamsApp/teamsappMgr.d.ts +6 -0
  251. package/build/component/driver/teamsApp/teamsappMgr.d.ts.map +1 -1
  252. package/build/component/driver/teamsApp/teamsappMgr.js +38 -3
  253. package/build/component/driver/teamsApp/teamsappMgr.js.map +1 -1
  254. package/build/component/driver/teamsApp/utils/CopilotGptManifestUtils.d.ts +2 -0
  255. package/build/component/driver/teamsApp/utils/CopilotGptManifestUtils.d.ts.map +1 -1
  256. package/build/component/driver/teamsApp/utils/CopilotGptManifestUtils.js +120 -5
  257. package/build/component/driver/teamsApp/utils/CopilotGptManifestUtils.js.map +1 -1
  258. package/build/component/driver/teamsApp/utils/ManifestUtils.d.ts +1 -1
  259. package/build/component/driver/teamsApp/utils/ManifestUtils.d.ts.map +1 -1
  260. package/build/component/driver/teamsApp/utils/ManifestUtils.js +10 -2
  261. package/build/component/driver/teamsApp/utils/ManifestUtils.js.map +1 -1
  262. package/build/component/driver/teamsApp/utils/McpCertVerification.d.ts +17 -0
  263. package/build/component/driver/teamsApp/utils/McpCertVerification.d.ts.map +1 -0
  264. package/build/component/driver/teamsApp/utils/McpCertVerification.js +72 -0
  265. package/build/component/driver/teamsApp/utils/McpCertVerification.js.map +1 -0
  266. package/build/component/driver/teamsApp/utils/PluginManifestUtils.d.ts.map +1 -1
  267. package/build/component/driver/teamsApp/utils/PluginManifestUtils.js +1 -1
  268. package/build/component/driver/teamsApp/utils/PluginManifestUtils.js.map +1 -1
  269. package/build/component/driver/teamsApp/utils/telemetry.d.ts +1 -0
  270. package/build/component/driver/teamsApp/utils/telemetry.d.ts.map +1 -1
  271. package/build/component/driver/teamsApp/utils/telemetry.js +1 -0
  272. package/build/component/driver/teamsApp/utils/telemetry.js.map +1 -1
  273. package/build/component/driver/teamsApp/utils/utils.d.ts +1 -4
  274. package/build/component/driver/teamsApp/utils/utils.d.ts.map +1 -1
  275. package/build/component/driver/teamsApp/utils/utils.js +3 -25
  276. package/build/component/driver/teamsApp/utils/utils.js.map +1 -1
  277. package/build/component/driver/teamsApp/validate.d.ts.map +1 -1
  278. package/build/component/driver/teamsApp/validate.js +16 -5
  279. package/build/component/driver/teamsApp/validate.js.map +1 -1
  280. package/build/component/driver/teamsApp/validateAppPackage.d.ts +13 -0
  281. package/build/component/driver/teamsApp/validateAppPackage.d.ts.map +1 -1
  282. package/build/component/driver/teamsApp/validateAppPackage.js +58 -1
  283. package/build/component/driver/teamsApp/validateAppPackage.js.map +1 -1
  284. package/build/component/driver/teamsApp/validateTestCases.d.ts.map +1 -1
  285. package/build/component/driver/typeSpec/compile.d.ts.map +1 -1
  286. package/build/component/driver/typeSpec/compile.js +23 -7
  287. package/build/component/driver/typeSpec/compile.js.map +1 -1
  288. package/build/component/driver/typeSpec/error/typeSpecCompileError.d.ts +5 -0
  289. package/build/component/driver/typeSpec/error/typeSpecCompileError.d.ts.map +1 -0
  290. package/build/component/driver/typeSpec/error/typeSpecCompileError.js +21 -0
  291. package/build/component/driver/typeSpec/error/typeSpecCompileError.js.map +1 -0
  292. package/build/component/driver/util/utils.d.ts.map +1 -1
  293. package/build/component/driver/util/utils.js +1 -0
  294. package/build/component/driver/util/utils.js.map +1 -1
  295. package/build/component/feature/sso.js +2 -2
  296. package/build/component/feature/sso.js.map +1 -1
  297. package/build/component/generator/combinedProject/generator.d.ts.map +1 -1
  298. package/build/component/generator/combinedProject/generator.js +9 -1
  299. package/build/component/generator/combinedProject/generator.js.map +1 -1
  300. package/build/component/generator/configFiles/configGenerator.js +1 -1
  301. package/build/component/generator/configFiles/configGenerator.js.map +1 -1
  302. package/build/component/generator/declarativeAgent/generator.d.ts +7 -0
  303. package/build/component/generator/declarativeAgent/generator.d.ts.map +1 -1
  304. package/build/component/generator/declarativeAgent/generator.js +23 -15
  305. package/build/component/generator/declarativeAgent/generator.js.map +1 -1
  306. package/build/component/generator/declarativeAgent/helper.d.ts +52 -0
  307. package/build/component/generator/declarativeAgent/helper.d.ts.map +1 -1
  308. package/build/component/generator/declarativeAgent/helper.js +469 -63
  309. package/build/component/generator/declarativeAgent/helper.js.map +1 -1
  310. package/build/component/generator/defaultGenerator.d.ts.map +1 -1
  311. package/build/component/generator/defaultGenerator.js +17 -1
  312. package/build/component/generator/defaultGenerator.js.map +1 -1
  313. package/build/component/generator/error.d.ts +3 -0
  314. package/build/component/generator/error.d.ts.map +1 -1
  315. package/build/component/generator/error.js +7 -1
  316. package/build/component/generator/error.js.map +1 -1
  317. package/build/component/generator/generatorAction.d.ts +12 -1
  318. package/build/component/generator/generatorAction.d.ts.map +1 -1
  319. package/build/component/generator/generatorAction.js +16 -8
  320. package/build/component/generator/generatorAction.js.map +1 -1
  321. package/build/component/generator/officeAddin/generator.d.ts +13 -0
  322. package/build/component/generator/officeAddin/generator.d.ts.map +1 -1
  323. package/build/component/generator/officeAddin/generator.js +159 -35
  324. package/build/component/generator/officeAddin/generator.js.map +1 -1
  325. package/build/component/generator/officeAddin/helperMethods.d.ts +4 -0
  326. package/build/component/generator/officeAddin/helperMethods.d.ts.map +1 -1
  327. package/build/component/generator/officeAddin/helperMethods.js +6 -3
  328. package/build/component/generator/officeAddin/helperMethods.js.map +1 -1
  329. package/build/component/generator/openApiSpec/common.js +1 -1
  330. package/build/component/generator/openApiSpec/common.js.map +1 -1
  331. package/build/component/generator/openApiSpec/customEngineAgentGenerator.d.ts +8 -0
  332. package/build/component/generator/openApiSpec/customEngineAgentGenerator.d.ts.map +1 -1
  333. package/build/component/generator/openApiSpec/customEngineAgentGenerator.js +9 -4
  334. package/build/component/generator/openApiSpec/customEngineAgentGenerator.js.map +1 -1
  335. package/build/component/generator/openApiSpec/helper.d.ts +2 -3
  336. package/build/component/generator/openApiSpec/helper.d.ts.map +1 -1
  337. package/build/component/generator/openApiSpec/helper.js +22 -60
  338. package/build/component/generator/openApiSpec/helper.js.map +1 -1
  339. package/build/component/generator/openPlugin/authorParser.d.ts +8 -0
  340. package/build/component/generator/openPlugin/authorParser.d.ts.map +1 -0
  341. package/build/component/generator/openPlugin/authorParser.js +49 -0
  342. package/build/component/generator/openPlugin/authorParser.js.map +1 -0
  343. package/build/component/generator/openPlugin/deterministicId.d.ts +6 -0
  344. package/build/component/generator/openPlugin/deterministicId.d.ts.map +1 -0
  345. package/build/component/generator/openPlugin/deterministicId.js +31 -0
  346. package/build/component/generator/openPlugin/deterministicId.js.map +1 -0
  347. package/build/component/generator/openPlugin/exporter.d.ts +18 -0
  348. package/build/component/generator/openPlugin/exporter.d.ts.map +1 -0
  349. package/build/component/generator/openPlugin/exporter.js +233 -0
  350. package/build/component/generator/openPlugin/exporter.js.map +1 -0
  351. package/build/component/generator/openPlugin/iconStrategy.d.ts +8 -0
  352. package/build/component/generator/openPlugin/iconStrategy.d.ts.map +1 -0
  353. package/build/component/generator/openPlugin/iconStrategy.js +62 -0
  354. package/build/component/generator/openPlugin/iconStrategy.js.map +1 -0
  355. package/build/component/generator/openPlugin/importer.d.ts +25 -0
  356. package/build/component/generator/openPlugin/importer.d.ts.map +1 -0
  357. package/build/component/generator/openPlugin/importer.js +140 -0
  358. package/build/component/generator/openPlugin/importer.js.map +1 -0
  359. package/build/component/generator/openPlugin/mapper.d.ts +6 -0
  360. package/build/component/generator/openPlugin/mapper.d.ts.map +1 -0
  361. package/build/component/generator/openPlugin/mapper.js +141 -0
  362. package/build/component/generator/openPlugin/mapper.js.map +1 -0
  363. package/build/component/generator/openPlugin/parser.d.ts +3 -0
  364. package/build/component/generator/openPlugin/parser.d.ts.map +1 -0
  365. package/build/component/generator/openPlugin/parser.js +153 -0
  366. package/build/component/generator/openPlugin/parser.js.map +1 -0
  367. package/build/component/generator/openPlugin/placeholderPng.d.ts +6 -0
  368. package/build/component/generator/openPlugin/placeholderPng.d.ts.map +1 -0
  369. package/build/component/generator/openPlugin/placeholderPng.js +71 -0
  370. package/build/component/generator/openPlugin/placeholderPng.js.map +1 -0
  371. package/build/component/generator/openPlugin/textUtils.d.ts +12 -0
  372. package/build/component/generator/openPlugin/textUtils.d.ts.map +1 -0
  373. package/build/component/generator/openPlugin/textUtils.js +43 -0
  374. package/build/component/generator/openPlugin/textUtils.js.map +1 -0
  375. package/build/component/generator/openPlugin/types.d.ts +128 -0
  376. package/build/component/generator/openPlugin/types.d.ts.map +1 -0
  377. package/build/component/generator/openPlugin/types.js.map +1 -0
  378. package/build/component/generator/other/tdpGenerator.d.ts +1 -0
  379. package/build/component/generator/other/tdpGenerator.d.ts.map +1 -1
  380. package/build/component/generator/other/tdpGenerator.js +24 -2
  381. package/build/component/generator/other/tdpGenerator.js.map +1 -1
  382. package/build/component/generator/spfx/spfxGenerator.js +5 -5
  383. package/build/component/generator/spfx/spfxGenerator.js.map +1 -1
  384. package/build/component/generator/spfx/utils/constants.d.ts +1 -1
  385. package/build/component/generator/spfx/utils/constants.js +1 -1
  386. package/build/component/generator/spfx/utils/utils.js +1 -1
  387. package/build/component/generator/spfx/utils/utils.js.map +1 -1
  388. package/build/component/generator/templateHelper.d.ts +17 -2
  389. package/build/component/generator/templateHelper.d.ts.map +1 -1
  390. package/build/component/generator/templateHelper.js +36 -3
  391. package/build/component/generator/templateHelper.js.map +1 -1
  392. package/build/component/generator/templates/metadata/index.d.ts +15 -0
  393. package/build/component/generator/templates/metadata/index.d.ts.map +1 -1
  394. package/build/component/generator/templates/metadata/index.js +51 -5
  395. package/build/component/generator/templates/metadata/index.js.map +1 -1
  396. package/build/component/generator/templates/templateNames.d.ts +6 -3
  397. package/build/component/generator/templates/templateNames.d.ts.map +1 -1
  398. package/build/component/generator/templates/templateNames.js +7 -2
  399. package/build/component/generator/templates/templateNames.js.map +1 -1
  400. package/build/component/generator/templates/templateReplaceMap.d.ts.map +1 -1
  401. package/build/component/generator/templates/templateReplaceMap.js +4 -1
  402. package/build/component/generator/templates/templateReplaceMap.js.map +1 -1
  403. package/build/component/generator/utils.d.ts.map +1 -1
  404. package/build/component/generator/utils.js +14 -8
  405. package/build/component/generator/utils.js.map +1 -1
  406. package/build/component/generator/v4MetadataSource.d.ts +16 -0
  407. package/build/component/generator/v4MetadataSource.d.ts.map +1 -0
  408. package/build/component/generator/v4MetadataSource.js +35 -0
  409. package/build/component/generator/v4MetadataSource.js.map +1 -0
  410. package/build/component/generator/v4TemplateBridge.d.ts +55 -0
  411. package/build/component/generator/v4TemplateBridge.d.ts.map +1 -0
  412. package/build/component/generator/v4TemplateBridge.js +224 -0
  413. package/build/component/generator/v4TemplateBridge.js.map +1 -0
  414. package/build/component/local/localCertificateManager.d.ts +16 -1
  415. package/build/component/local/localCertificateManager.d.ts.map +1 -1
  416. package/build/component/local/localCertificateManager.js +47 -31
  417. package/build/component/local/localCertificateManager.js.map +1 -1
  418. package/build/component/m365/constants.d.ts +2 -1
  419. package/build/component/m365/constants.d.ts.map +1 -1
  420. package/build/component/m365/constants.js +1 -0
  421. package/build/component/m365/constants.js.map +1 -1
  422. package/build/component/m365/errors.d.ts +7 -0
  423. package/build/component/m365/errors.d.ts.map +1 -1
  424. package/build/component/m365/errors.js +16 -1
  425. package/build/component/m365/errors.js.map +1 -1
  426. package/build/component/m365/launchHelper.d.ts.map +1 -1
  427. package/build/component/m365/launchHelper.js +7 -2
  428. package/build/component/m365/launchHelper.js.map +1 -1
  429. package/build/component/m365/packageService.d.ts +11 -5
  430. package/build/component/m365/packageService.d.ts.map +1 -1
  431. package/build/component/m365/packageService.js +132 -109
  432. package/build/component/m365/packageService.js.map +1 -1
  433. package/build/component/m365/serviceConstant.d.ts.map +1 -1
  434. package/build/component/m365/serviceConstant.js +24 -14
  435. package/build/component/m365/serviceConstant.js.map +1 -1
  436. package/build/component/middleware/envMW.d.ts.map +1 -1
  437. package/build/component/middleware/envMW.js +5 -0
  438. package/build/component/middleware/envMW.js.map +1 -1
  439. package/build/component/middleware/questionMW.d.ts.map +1 -1
  440. package/build/component/middleware/questionMW.js +3 -0
  441. package/build/component/middleware/questionMW.js.map +1 -1
  442. package/build/component/provisionUtils.d.ts.map +1 -1
  443. package/build/component/provisionUtils.js +5 -2
  444. package/build/component/provisionUtils.js.map +1 -1
  445. package/build/component/utils/ResourceGroupHelper.d.ts +4 -0
  446. package/build/component/utils/ResourceGroupHelper.d.ts.map +1 -1
  447. package/build/component/utils/ResourceGroupHelper.js +8 -4
  448. package/build/component/utils/ResourceGroupHelper.js.map +1 -1
  449. package/build/component/utils/charsetUtils.js +3 -3
  450. package/build/component/utils/charsetUtils.js.map +1 -1
  451. package/build/component/utils/envFunctionUtils.js +77 -22
  452. package/build/component/utils/envFunctionUtils.js.map +1 -1
  453. package/build/component/utils/envUtil.d.ts.map +1 -1
  454. package/build/component/utils/envUtil.js +2 -2
  455. package/build/component/utils/envUtil.js.map +1 -1
  456. package/build/component/utils/fileOperation.d.ts +9 -0
  457. package/build/component/utils/fileOperation.d.ts.map +1 -1
  458. package/build/component/utils/fileOperation.js +31 -17
  459. package/build/component/utils/fileOperation.js.map +1 -1
  460. package/build/component/utils/mcpAuthScaffolder.d.ts +137 -0
  461. package/build/component/utils/mcpAuthScaffolder.d.ts.map +1 -0
  462. package/build/component/utils/mcpAuthScaffolder.js +200 -0
  463. package/build/component/utils/mcpAuthScaffolder.js.map +1 -0
  464. package/build/component/utils/mcpToolFetcher.d.ts +2 -0
  465. package/build/component/utils/mcpToolFetcher.d.ts.map +1 -0
  466. package/build/component/utils/mcpToolFetcher.js +7 -0
  467. package/build/component/utils/mcpToolFetcher.js.map +1 -0
  468. package/build/component/utils/metadataGraphPermssion.d.ts +4 -0
  469. package/build/component/utils/metadataGraphPermssion.d.ts.map +1 -1
  470. package/build/component/utils/metadataGraphPermssion.js +7 -4
  471. package/build/component/utils/metadataGraphPermssion.js.map +1 -1
  472. package/build/component/utils/odrProvider.d.ts +1 -48
  473. package/build/component/utils/odrProvider.d.ts.map +1 -1
  474. package/build/component/utils/odrProvider.js +2 -94
  475. package/build/component/utils/odrProvider.js.map +1 -1
  476. package/build/core/FxCore.d.ts +49 -16
  477. package/build/core/FxCore.d.ts.map +1 -1
  478. package/build/core/FxCore.declarativeAgent.d.ts +45 -1
  479. package/build/core/FxCore.declarativeAgent.d.ts.map +1 -1
  480. package/build/core/FxCore.declarativeAgent.js +754 -56
  481. package/build/core/FxCore.declarativeAgent.js.map +1 -1
  482. package/build/core/FxCore.js +515 -325
  483. package/build/core/FxCore.js.map +1 -1
  484. package/build/core/FxCore.openPlugin.d.ts +23 -0
  485. package/build/core/FxCore.openPlugin.d.ts.map +1 -0
  486. package/build/core/FxCore.openPlugin.js +131 -0
  487. package/build/core/FxCore.openPlugin.js.map +1 -0
  488. package/build/core/FxCoreClient.d.ts +96 -0
  489. package/build/core/FxCoreClient.d.ts.map +1 -0
  490. package/build/core/FxCoreClient.js +159 -0
  491. package/build/core/FxCoreClient.js.map +1 -0
  492. package/build/core/collaborator.d.ts +1 -0
  493. package/build/core/collaborator.d.ts.map +1 -1
  494. package/build/core/collaborator.js +37 -0
  495. package/build/core/collaborator.js.map +1 -1
  496. package/build/core/createFrontDoorAdapters.d.ts +39 -0
  497. package/build/core/createFrontDoorAdapters.d.ts.map +1 -0
  498. package/build/core/createFrontDoorAdapters.js +244 -0
  499. package/build/core/createFrontDoorAdapters.js.map +1 -0
  500. package/build/core/createProjectFrontDoor.d.ts +49 -0
  501. package/build/core/createProjectFrontDoor.d.ts.map +1 -0
  502. package/build/core/createProjectFrontDoor.js +316 -0
  503. package/build/core/createProjectFrontDoor.js.map +1 -0
  504. package/build/core/middleware/concurrentLocker.d.ts.map +1 -1
  505. package/build/core/middleware/concurrentLocker.js +7 -10
  506. package/build/core/middleware/concurrentLocker.js.map +1 -1
  507. package/build/core/middleware/errorHandler.d.ts.map +1 -1
  508. package/build/core/middleware/errorHandler.js +9 -0
  509. package/build/core/middleware/errorHandler.js.map +1 -1
  510. package/build/core/middleware/fileLocker.js +6 -6
  511. package/build/core/middleware/fileLocker.js.map +1 -1
  512. package/build/core/middleware/utils/v3MigrationUtils.d.ts +1 -34
  513. package/build/core/middleware/utils/v3MigrationUtils.d.ts.map +1 -1
  514. package/build/core/middleware/utils/v3MigrationUtils.js +6 -245
  515. package/build/core/middleware/utils/v3MigrationUtils.js.map +1 -1
  516. package/build/core/modifyProjectFrontDoor.d.ts +27 -0
  517. package/build/core/modifyProjectFrontDoor.d.ts.map +1 -0
  518. package/build/core/modifyProjectFrontDoor.js +148 -0
  519. package/build/core/modifyProjectFrontDoor.js.map +1 -0
  520. package/build/core/v4ArtifactSnapshot.d.ts +5 -0
  521. package/build/core/v4ArtifactSnapshot.d.ts.map +1 -0
  522. package/build/core/v4ArtifactSnapshot.js +23 -0
  523. package/build/core/v4ArtifactSnapshot.js.map +1 -0
  524. package/build/error/common.d.ts.map +1 -1
  525. package/build/error/common.js +3 -0
  526. package/build/error/common.js.map +1 -1
  527. package/build/error/teamsApp.d.ts +7 -1
  528. package/build/error/teamsApp.d.ts.map +1 -1
  529. package/build/error/teamsApp.js +34 -4
  530. package/build/error/teamsApp.js.map +1 -1
  531. package/build/error/teamsGraph.d.ts +5 -0
  532. package/build/error/teamsGraph.d.ts.map +1 -0
  533. package/build/error/teamsGraph.js +24 -0
  534. package/build/error/teamsGraph.js.map +1 -0
  535. package/build/index.d.ts +8 -4
  536. package/build/index.d.ts.map +1 -1
  537. package/build/index.js +21 -7
  538. package/build/index.js.map +1 -1
  539. package/build/question/constants.d.ts +1 -0
  540. package/build/question/constants.d.ts.map +1 -1
  541. package/build/question/constants.js +15 -8
  542. package/build/question/constants.js.map +1 -1
  543. package/build/question/create.d.ts +18 -0
  544. package/build/question/create.d.ts.map +1 -1
  545. package/build/question/create.js +121 -14
  546. package/build/question/create.js.map +1 -1
  547. package/build/question/index.d.ts +1 -1
  548. package/build/question/index.d.ts.map +1 -1
  549. package/build/question/index.js +4 -4
  550. package/build/question/index.js.map +1 -1
  551. package/build/question/inputs/AddKnowledgeInputs.d.ts.map +1 -1
  552. package/build/question/inputs/AddPluginInputs.d.ts +17 -5
  553. package/build/question/inputs/AddPluginInputs.d.ts.map +1 -1
  554. package/build/question/inputs/AddSkillInputs.d.ts +10 -0
  555. package/build/question/inputs/AddSkillInputs.d.ts.map +1 -0
  556. package/build/question/inputs/AddSkillInputs.js +5 -0
  557. package/build/question/inputs/AddSkillInputs.js.map +1 -0
  558. package/build/question/inputs/CreateProjectInputs.d.ts +19 -1
  559. package/build/question/inputs/CreateProjectInputs.d.ts.map +1 -1
  560. package/build/question/inputs/ExportOpenPluginInputs.d.ts +10 -0
  561. package/build/question/inputs/ExportOpenPluginInputs.d.ts.map +1 -0
  562. package/build/question/inputs/ExportOpenPluginInputs.js +5 -0
  563. package/build/question/inputs/ExportOpenPluginInputs.js.map +1 -0
  564. package/build/question/inputs/ImportOpenPluginInputs.d.ts +28 -0
  565. package/build/question/inputs/ImportOpenPluginInputs.d.ts.map +1 -0
  566. package/build/question/inputs/ImportOpenPluginInputs.js +5 -0
  567. package/build/question/inputs/ImportOpenPluginInputs.js.map +1 -0
  568. package/build/question/inputs/index.d.ts +4 -1
  569. package/build/question/inputs/index.d.ts.map +1 -1
  570. package/build/question/inputs/index.js +4 -1
  571. package/build/question/inputs/index.js.map +1 -1
  572. package/build/question/options/AddPluginOptions.d.ts.map +1 -1
  573. package/build/question/options/AddPluginOptions.js +38 -6
  574. package/build/question/options/AddPluginOptions.js.map +1 -1
  575. package/build/question/options/AddSkillOptions.d.ts +4 -0
  576. package/build/question/options/AddSkillOptions.d.ts.map +1 -0
  577. package/build/question/options/AddSkillOptions.js +47 -0
  578. package/build/question/options/AddSkillOptions.js.map +1 -0
  579. package/build/question/options/CreateProjectOptions.d.ts.map +1 -1
  580. package/build/question/options/CreateProjectOptions.js +53 -1
  581. package/build/question/options/CreateProjectOptions.js.map +1 -1
  582. package/build/question/options/ExportOpenPluginOptions.d.ts +4 -0
  583. package/build/question/options/ExportOpenPluginOptions.d.ts.map +1 -0
  584. package/build/question/options/ExportOpenPluginOptions.js +29 -0
  585. package/build/question/options/ExportOpenPluginOptions.js.map +1 -0
  586. package/build/question/options/ImportOpenPluginOptions.d.ts +4 -0
  587. package/build/question/options/ImportOpenPluginOptions.d.ts.map +1 -0
  588. package/build/question/options/ImportOpenPluginOptions.js +54 -0
  589. package/build/question/options/ImportOpenPluginOptions.js.map +1 -0
  590. package/build/question/options/index.d.ts +3 -0
  591. package/build/question/options/index.d.ts.map +1 -1
  592. package/build/question/options/index.js +3 -0
  593. package/build/question/options/index.js.map +1 -1
  594. package/build/question/other.d.ts +1 -1
  595. package/build/question/other.d.ts.map +1 -1
  596. package/build/question/other.js +198 -17
  597. package/build/question/other.js.map +1 -1
  598. package/build/question/questionNames.d.ts +14 -1
  599. package/build/question/questionNames.d.ts.map +1 -1
  600. package/build/question/questionNames.js +13 -0
  601. package/build/question/questionNames.js.map +1 -1
  602. package/build/question/scaffold/commonNodes.d.ts.map +1 -1
  603. package/build/question/scaffold/commonNodes.js +14 -2
  604. package/build/question/scaffold/commonNodes.js.map +1 -1
  605. package/build/question/scaffold/constructNode.d.ts +3 -1
  606. package/build/question/scaffold/constructNode.d.ts.map +1 -1
  607. package/build/question/scaffold/constructNode.js +55 -2
  608. package/build/question/scaffold/constructNode.js.map +1 -1
  609. package/build/question/scaffold/vsc/CapabilityOptions.d.ts +3 -5
  610. package/build/question/scaffold/vsc/CapabilityOptions.d.ts.map +1 -1
  611. package/build/question/scaffold/vsc/CapabilityOptions.js +46 -46
  612. package/build/question/scaffold/vsc/CapabilityOptions.js.map +1 -1
  613. package/build/question/scaffold/vsc/ProjectTypeOptions.d.ts +2 -0
  614. package/build/question/scaffold/vsc/ProjectTypeOptions.d.ts.map +1 -1
  615. package/build/question/scaffold/vsc/ProjectTypeOptions.js +9 -0
  616. package/build/question/scaffold/vsc/ProjectTypeOptions.js.map +1 -1
  617. package/build/question/scaffold/vsc/createRootNode.d.ts.map +1 -1
  618. package/build/question/scaffold/vsc/createRootNode.js +3 -0
  619. package/build/question/scaffold/vsc/createRootNode.js.map +1 -1
  620. package/build/question/scaffold/vsc/daProjectTypeNode.d.ts.map +1 -1
  621. package/build/question/scaffold/vsc/daProjectTypeNode.js +1 -6
  622. package/build/question/scaffold/vsc/daProjectTypeNode.js.map +1 -1
  623. package/build/question/scaffold/vsc/rootNode.d.ts.map +1 -1
  624. package/build/question/scaffold/vsc/rootNode.js +17 -4
  625. package/build/question/scaffold/vsc/rootNode.js.map +1 -1
  626. package/build/question/scaffold/vsc/teamsProjectTypeNode.d.ts +66 -0
  627. package/build/question/scaffold/vsc/teamsProjectTypeNode.d.ts.map +1 -1
  628. package/build/question/scaffold/vsc/teamsProjectTypeNode.js +408 -21
  629. package/build/question/scaffold/vsc/teamsProjectTypeNode.js.map +1 -1
  630. package/build/question/share.js +3 -2
  631. package/build/question/share.js.map +1 -1
  632. package/build/ui/visitor.d.ts.map +1 -1
  633. package/build/ui/visitor.js +10 -0
  634. package/build/ui/visitor.js.map +1 -1
  635. package/build/v4/buildTarget/parseSelector.d.ts +35 -0
  636. package/build/v4/buildTarget/parseSelector.d.ts.map +1 -0
  637. package/build/v4/buildTarget/parseSelector.js +222 -0
  638. package/build/v4/buildTarget/parseSelector.js.map +1 -0
  639. package/build/v4/buildTarget/resolveBuildTarget.d.ts +82 -0
  640. package/build/v4/buildTarget/resolveBuildTarget.d.ts.map +1 -0
  641. package/build/v4/buildTarget/resolveBuildTarget.js +243 -0
  642. package/build/v4/buildTarget/resolveBuildTarget.js.map +1 -0
  643. package/build/v4/collectInputs/collectInputs.d.ts +151 -0
  644. package/build/v4/collectInputs/collectInputs.d.ts.map +1 -0
  645. package/build/v4/collectInputs/collectInputs.js +533 -0
  646. package/build/v4/collectInputs/collectInputs.js.map +1 -0
  647. package/build/v4/distribution/bundledFloor.d.ts +11 -0
  648. package/build/v4/distribution/bundledFloor.d.ts.map +1 -0
  649. package/build/v4/distribution/bundledFloor.js +114 -0
  650. package/build/v4/distribution/bundledFloor.js.map +1 -0
  651. package/build/v4/distribution/createQuestions.d.ts +6 -0
  652. package/build/v4/distribution/createQuestions.d.ts.map +1 -0
  653. package/build/v4/distribution/createQuestions.js +61 -0
  654. package/build/v4/distribution/createQuestions.js.map +1 -0
  655. package/build/v4/distribution/createSelector.d.ts +15 -0
  656. package/build/v4/distribution/createSelector.d.ts.map +1 -0
  657. package/build/v4/distribution/createSelector.js +115 -0
  658. package/build/v4/distribution/createSelector.js.map +1 -0
  659. package/build/v4/distribution/declarativePackage.d.ts +14 -0
  660. package/build/v4/distribution/declarativePackage.d.ts.map +1 -0
  661. package/build/v4/distribution/declarativePackage.js +165 -0
  662. package/build/v4/distribution/declarativePackage.js.map +1 -0
  663. package/build/v4/distribution/packageDir.d.ts +15 -0
  664. package/build/v4/distribution/packageDir.d.ts.map +1 -0
  665. package/build/v4/distribution/packageDir.js +101 -0
  666. package/build/v4/distribution/packageDir.js.map +1 -0
  667. package/build/v4/distribution/questionFragments.d.ts +11 -0
  668. package/build/v4/distribution/questionFragments.d.ts.map +1 -0
  669. package/build/v4/distribution/questionFragments.js +130 -0
  670. package/build/v4/distribution/questionFragments.js.map +1 -0
  671. package/build/v4/distribution/templateArtifacts.d.ts +61 -0
  672. package/build/v4/distribution/templateArtifacts.d.ts.map +1 -0
  673. package/build/v4/distribution/templateArtifacts.js +459 -0
  674. package/build/v4/distribution/templateArtifacts.js.map +1 -0
  675. package/build/v4/distribution/templateConfig.d.ts +43 -0
  676. package/build/v4/distribution/templateConfig.d.ts.map +1 -0
  677. package/build/v4/distribution/templateConfig.js +70 -0
  678. package/build/v4/distribution/templateConfig.js.map +1 -0
  679. package/build/v4/distribution/templatePackage.d.ts +6 -0
  680. package/build/v4/distribution/templatePackage.d.ts.map +1 -0
  681. package/build/v4/distribution/templatePackage.js +63 -0
  682. package/build/v4/distribution/templatePackage.js.map +1 -0
  683. package/build/v4/distribution/templateSource.d.ts +66 -0
  684. package/build/v4/distribution/templateSource.d.ts.map +1 -0
  685. package/build/v4/distribution/templateSource.js +233 -0
  686. package/build/v4/distribution/templateSource.js.map +1 -0
  687. package/build/v4/distribution/templateSourcePort.d.ts +27 -0
  688. package/build/v4/distribution/templateSourcePort.d.ts.map +1 -0
  689. package/build/v4/distribution/templateSourcePort.js +175 -0
  690. package/build/v4/distribution/templateSourcePort.js.map +1 -0
  691. package/build/v4/engineVersion.d.ts +7 -0
  692. package/build/v4/engineVersion.d.ts.map +1 -0
  693. package/build/v4/engineVersion.js +12 -0
  694. package/build/v4/engineVersion.js.map +1 -0
  695. package/build/v4/expression/evaluateExpression.d.ts +55 -0
  696. package/build/v4/expression/evaluateExpression.d.ts.map +1 -0
  697. package/build/v4/expression/evaluateExpression.js +338 -0
  698. package/build/v4/expression/evaluateExpression.js.map +1 -0
  699. package/build/v4/index.d.ts +41 -0
  700. package/build/v4/index.d.ts.map +1 -0
  701. package/build/v4/index.js +46 -0
  702. package/build/v4/index.js.map +1 -0
  703. package/build/v4/inspection/scaffoldCatalog.d.ts +28 -0
  704. package/build/v4/inspection/scaffoldCatalog.d.ts.map +1 -0
  705. package/build/v4/inspection/scaffoldCatalog.js +66 -0
  706. package/build/v4/inspection/scaffoldCatalog.js.map +1 -0
  707. package/build/v4/inspection/scaffoldMetadataSource.d.ts +6 -0
  708. package/build/v4/inspection/scaffoldMetadataSource.d.ts.map +1 -0
  709. package/build/v4/inspection/scaffoldMetadataSource.js +78 -0
  710. package/build/v4/inspection/scaffoldMetadataSource.js.map +1 -0
  711. package/build/v4/mcp/mcpAuthAction.d.ts +36 -0
  712. package/build/v4/mcp/mcpAuthAction.d.ts.map +1 -0
  713. package/build/v4/mcp/mcpAuthAction.js +177 -0
  714. package/build/v4/mcp/mcpAuthAction.js.map +1 -0
  715. package/build/v4/mcp/mcpAuthScaffold.d.ts +37 -0
  716. package/build/v4/mcp/mcpAuthScaffold.d.ts.map +1 -0
  717. package/build/v4/mcp/mcpAuthScaffold.js +162 -0
  718. package/build/v4/mcp/mcpAuthScaffold.js.map +1 -0
  719. package/build/v4/mcp/mcpStaticTools.d.ts +17 -0
  720. package/build/v4/mcp/mcpStaticTools.d.ts.map +1 -0
  721. package/build/v4/mcp/mcpStaticTools.js +70 -0
  722. package/build/v4/mcp/mcpStaticTools.js.map +1 -0
  723. package/build/v4/model/dataModel.d.ts +27 -0
  724. package/build/v4/model/dataModel.d.ts.map +1 -0
  725. package/build/v4/model/dataModel.js +5 -0
  726. package/build/v4/model/dataModel.js.map +1 -0
  727. package/build/v4/pipeline/runScaffoldPipeline.d.ts +101 -0
  728. package/build/v4/pipeline/runScaffoldPipeline.d.ts.map +1 -0
  729. package/build/v4/pipeline/runScaffoldPipeline.js +212 -0
  730. package/build/v4/pipeline/runScaffoldPipeline.js.map +1 -0
  731. package/build/v4/providers/createOptionsProviders.d.ts +11 -0
  732. package/build/v4/providers/createOptionsProviders.d.ts.map +1 -0
  733. package/build/v4/providers/createOptionsProviders.js +268 -0
  734. package/build/v4/providers/createOptionsProviders.js.map +1 -0
  735. package/build/v4/renderContext/buildRenderContext.d.ts +24 -0
  736. package/build/v4/renderContext/buildRenderContext.d.ts.map +1 -0
  737. package/build/v4/renderContext/buildRenderContext.js +75 -0
  738. package/build/v4/renderContext/buildRenderContext.js.map +1 -0
  739. package/build/v4/runtime/generalSensitivityLabel.d.ts +5 -0
  740. package/build/v4/runtime/generalSensitivityLabel.d.ts.map +1 -0
  741. package/build/v4/runtime/generalSensitivityLabel.js +36 -0
  742. package/build/v4/runtime/generalSensitivityLabel.js.map +1 -0
  743. package/build/v4/runtime/inMemoryRuntime.d.ts +21 -0
  744. package/build/v4/runtime/inMemoryRuntime.d.ts.map +1 -0
  745. package/build/v4/runtime/inMemoryRuntime.js +43 -0
  746. package/build/v4/runtime/inMemoryRuntime.js.map +1 -0
  747. package/build/v4/runtime/packageParse.d.ts +13 -0
  748. package/build/v4/runtime/packageParse.d.ts.map +1 -0
  749. package/build/v4/runtime/packageParse.js +235 -0
  750. package/build/v4/runtime/packageParse.js.map +1 -0
  751. package/build/v4/runtime/realRuntime.d.ts +11 -0
  752. package/build/v4/runtime/realRuntime.d.ts.map +1 -0
  753. package/build/v4/runtime/realRuntime.js +64 -0
  754. package/build/v4/runtime/realRuntime.js.map +1 -0
  755. package/build/v4/runtime/renderMustache.d.ts +7 -0
  756. package/build/v4/runtime/renderMustache.d.ts.map +1 -0
  757. package/build/v4/runtime/renderMustache.js +54 -0
  758. package/build/v4/runtime/renderMustache.js.map +1 -0
  759. package/build/v4/runtime/runtimeRegistry.d.ts +28 -0
  760. package/build/v4/runtime/runtimeRegistry.d.ts.map +1 -0
  761. package/build/v4/runtime/runtimeRegistry.js +165 -0
  762. package/build/v4/runtime/runtimeRegistry.js.map +1 -0
  763. package/build/v4/runtime/scaffold.d.ts +31 -0
  764. package/build/v4/runtime/scaffold.d.ts.map +1 -0
  765. package/build/v4/runtime/scaffold.js +34 -0
  766. package/build/v4/runtime/scaffold.js.map +1 -0
  767. package/build/v4/runtime/scaffoldFromPackageDir.d.ts +7 -0
  768. package/build/v4/runtime/scaffoldFromPackageDir.d.ts.map +1 -0
  769. package/build/v4/runtime/scaffoldFromPackageDir.js +43 -0
  770. package/build/v4/runtime/scaffoldFromPackageDir.js.map +1 -0
  771. package/build/v4/runtime/selectLanguageContent.d.ts +7 -0
  772. package/build/v4/runtime/selectLanguageContent.d.ts.map +1 -0
  773. package/build/v4/runtime/selectLanguageContent.js +39 -0
  774. package/build/v4/runtime/selectLanguageContent.js.map +1 -0
  775. package/build/v4/runtime/steps/daAction.d.ts +6 -0
  776. package/build/v4/runtime/steps/daAction.d.ts.map +1 -0
  777. package/build/v4/runtime/steps/daAction.js +41 -0
  778. package/build/v4/runtime/steps/daAction.js.map +1 -0
  779. package/build/v4/runtime/steps/daSensitivity.d.ts +14 -0
  780. package/build/v4/runtime/steps/daSensitivity.d.ts.map +1 -0
  781. package/build/v4/runtime/steps/daSensitivity.js +50 -0
  782. package/build/v4/runtime/steps/daSensitivity.js.map +1 -0
  783. package/build/v4/runtime/steps/mcpAuth.d.ts +13 -0
  784. package/build/v4/runtime/steps/mcpAuth.d.ts.map +1 -0
  785. package/build/v4/runtime/steps/mcpAuth.js +90 -0
  786. package/build/v4/runtime/steps/mcpAuth.js.map +1 -0
  787. package/build/v4/runtime/steps/mcpLocal.d.ts +6 -0
  788. package/build/v4/runtime/steps/mcpLocal.d.ts.map +1 -0
  789. package/build/v4/runtime/steps/mcpLocal.js +93 -0
  790. package/build/v4/runtime/steps/mcpLocal.js.map +1 -0
  791. package/build/v4/runtime/steps/mcpStatic.d.ts +10 -0
  792. package/build/v4/runtime/steps/mcpStatic.d.ts.map +1 -0
  793. package/build/v4/runtime/steps/mcpStatic.js +182 -0
  794. package/build/v4/runtime/steps/mcpStatic.js.map +1 -0
  795. package/build/v4/runtime/steps/metaOs.d.ts +10 -0
  796. package/build/v4/runtime/steps/metaOs.d.ts.map +1 -0
  797. package/build/v4/runtime/steps/metaOs.js +422 -0
  798. package/build/v4/runtime/steps/metaOs.js.map +1 -0
  799. package/build/v4/runtime/steps/officeAddin.d.ts +4 -0
  800. package/build/v4/runtime/steps/officeAddin.d.ts.map +1 -0
  801. package/build/v4/runtime/steps/officeAddin.js +168 -0
  802. package/build/v4/runtime/steps/officeAddin.js.map +1 -0
  803. package/build/v4/runtime/steps/openApi.d.ts +6 -0
  804. package/build/v4/runtime/steps/openApi.d.ts.map +1 -0
  805. package/build/v4/runtime/steps/openApi.js +389 -0
  806. package/build/v4/runtime/steps/openApi.js.map +1 -0
  807. package/build/v4/runtime/steps/openApiCustomApi.d.ts +5 -0
  808. package/build/v4/runtime/steps/openApiCustomApi.d.ts.map +1 -0
  809. package/build/v4/runtime/steps/openApiCustomApi.js +385 -0
  810. package/build/v4/runtime/steps/openApiCustomApi.js.map +1 -0
  811. package/build/v4/runtime/whitelist.d.ts +41 -0
  812. package/build/v4/runtime/whitelist.d.ts.map +1 -0
  813. package/build/v4/runtime/whitelist.js +211 -0
  814. package/build/v4/runtime/whitelist.js.map +1 -0
  815. package/build/v4/runtime/withTempDirectory.d.ts +10 -0
  816. package/build/v4/runtime/withTempDirectory.d.ts.map +1 -0
  817. package/build/v4/runtime/withTempDirectory.js +41 -0
  818. package/build/v4/runtime/withTempDirectory.js.map +1 -0
  819. package/build/v4/surface/createFloorTail.d.ts +12 -0
  820. package/build/v4/surface/createFloorTail.d.ts.map +1 -0
  821. package/build/v4/surface/createFloorTail.js +138 -0
  822. package/build/v4/surface/createFloorTail.js.map +1 -0
  823. package/build/v4/surface/createInputs.d.ts +51 -0
  824. package/build/v4/surface/createInputs.d.ts.map +1 -0
  825. package/build/v4/surface/createInputs.js +153 -0
  826. package/build/v4/surface/createInputs.js.map +1 -0
  827. package/build/v4/surface/createSelectorWalk.d.ts +26 -0
  828. package/build/v4/surface/createSelectorWalk.d.ts.map +1 -0
  829. package/build/v4/surface/createSelectorWalk.js +140 -0
  830. package/build/v4/surface/createSelectorWalk.js.map +1 -0
  831. package/build/v4/surface/deriveCreateOptions.d.ts +5 -0
  832. package/build/v4/surface/deriveCreateOptions.d.ts.map +1 -0
  833. package/build/v4/surface/deriveCreateOptions.js +212 -0
  834. package/build/v4/surface/deriveCreateOptions.js.map +1 -0
  835. package/build/v4/surface/localizePrompt.d.ts +11 -0
  836. package/build/v4/surface/localizePrompt.d.ts.map +1 -0
  837. package/build/v4/surface/localizePrompt.js +32 -0
  838. package/build/v4/surface/localizePrompt.js.map +1 -0
  839. package/build/v4/surface/modifySelectorWalk.d.ts +12 -0
  840. package/build/v4/surface/modifySelectorWalk.d.ts.map +1 -0
  841. package/build/v4/surface/modifySelectorWalk.js +112 -0
  842. package/build/v4/surface/modifySelectorWalk.js.map +1 -0
  843. package/build/v4/surface/uiPromptUI.d.ts +5 -0
  844. package/build/v4/surface/uiPromptUI.d.ts.map +1 -0
  845. package/build/v4/surface/uiPromptUI.js +220 -0
  846. package/build/v4/surface/uiPromptUI.js.map +1 -0
  847. package/build/v4/validation/capabilityCatalog.d.ts +8 -0
  848. package/build/v4/validation/capabilityCatalog.d.ts.map +1 -0
  849. package/build/v4/validation/capabilityCatalog.js +62 -0
  850. package/build/v4/validation/capabilityCatalog.js.map +1 -0
  851. package/build/v4/validation/templateArchiveValidation.d.ts +15 -0
  852. package/build/v4/validation/templateArchiveValidation.d.ts.map +1 -0
  853. package/build/v4/validation/templateArchiveValidation.js +297 -0
  854. package/build/v4/validation/templateArchiveValidation.js.map +1 -0
  855. package/build/v4/validation/validateTemplatePackage.d.ts +83 -0
  856. package/build/v4/validation/validateTemplatePackage.d.ts.map +1 -0
  857. package/build/v4/validation/validateTemplatePackage.js +313 -0
  858. package/build/v4/validation/validateTemplatePackage.js.map +1 -0
  859. package/build/v4/validators/createInputValidators.d.ts +7 -0
  860. package/build/v4/validators/createInputValidators.d.ts.map +1 -0
  861. package/build/v4/validators/createInputValidators.js +77 -0
  862. package/build/v4/validators/createInputValidators.js.map +1 -0
  863. package/build/v4/validators/mcpCredentialValidators.d.ts +5 -0
  864. package/build/v4/validators/mcpCredentialValidators.d.ts.map +1 -0
  865. package/build/v4/validators/mcpCredentialValidators.js +13 -0
  866. package/build/v4/validators/mcpCredentialValidators.js.map +1 -0
  867. package/build/v4/validators/mcpServerUrlValidator.d.ts +9 -0
  868. package/build/v4/validators/mcpServerUrlValidator.d.ts.map +1 -0
  869. package/build/v4/validators/mcpServerUrlValidator.js +15 -0
  870. package/build/v4/validators/mcpServerUrlValidator.js.map +1 -0
  871. package/package.json +49 -100
  872. package/resource/package.nls.cs.json +1181 -1095
  873. package/resource/package.nls.de.json +1181 -1095
  874. package/resource/package.nls.es.json +1181 -1095
  875. package/resource/package.nls.fr.json +1181 -1095
  876. package/resource/package.nls.it.json +1181 -1095
  877. package/resource/package.nls.ja.json +1181 -1095
  878. package/resource/package.nls.json +125 -29
  879. package/resource/package.nls.ko.json +1181 -1095
  880. package/resource/package.nls.pl.json +1181 -1095
  881. package/resource/package.nls.pt-BR.json +1181 -1095
  882. package/resource/package.nls.ru.json +1181 -1095
  883. package/resource/package.nls.tr.json +1181 -1095
  884. package/resource/package.nls.zh-Hans.json +1181 -1095
  885. package/resource/package.nls.zh-Hant.json +1181 -1095
  886. package/resource/templates/package.nls.cs.json +39 -24
  887. package/resource/templates/package.nls.de.json +37 -22
  888. package/resource/templates/package.nls.es.json +35 -20
  889. package/resource/templates/package.nls.fr.json +45 -30
  890. package/resource/templates/package.nls.it.json +42 -27
  891. package/resource/templates/package.nls.ja.json +35 -20
  892. package/resource/templates/package.nls.json +27 -12
  893. package/resource/templates/package.nls.ko.json +33 -18
  894. package/resource/templates/package.nls.pl.json +38 -23
  895. package/resource/templates/package.nls.pt-BR.json +34 -19
  896. package/resource/templates/package.nls.ru.json +33 -18
  897. package/resource/templates/package.nls.tr.json +38 -23
  898. package/resource/templates/package.nls.zh-Hans.json +44 -29
  899. package/resource/templates/package.nls.zh-Hant.json +45 -30
  900. package/resource/templates/package.nls.zh-cn.json +7 -8
  901. package/resource/templates/package.nls.zh-tw.json +7 -8
  902. package/resource/yaml-schema/v1.11/yaml.schema.json +3 -0
  903. package/resource/yaml-schema/v1.12/yaml.schema.json +2132 -0
  904. package/resource/yaml-schema/v1.13/yaml.schema.json +2193 -0
  905. package/resource/yaml-schema/yaml.schema.json +128 -3
  906. package/templates/configs/playground/typescript/.vscode/tasks.json +1 -1
  907. package/templates/configs/remote/python/env/.env.dev +2 -1
  908. package/templates/configs/remote/python/m365agents.yml.tpl +1 -0
  909. package/templates/configs/remote/typescript/env/.env.dev +2 -1
  910. package/templates/configs/remote/typescript/m365agents.yml.tpl +1 -0
  911. package/templates/fallback/common.zip +0 -0
  912. package/templates/fallback/csharp.zip +0 -0
  913. package/templates/fallback/js.zip +0 -0
  914. package/templates/fallback/python.zip +0 -0
  915. package/templates/fallback/ts.zip +0 -0
  916. package/templates/metadata/allTemplates.json +32 -16
  917. package/templates/metadata/defaultGeneratorTemplates.json +8 -0
  918. package/templates/metadata.zip +0 -0
  919. package/templates/ui/ceaNode.json +30 -0
  920. package/templates/ui/tdpNode.json +13 -14
  921. package/templates/ui/teamsNode.json +124 -0
  922. package/templates/ui/wizardNode.json +56 -46
  923. package/templates/v4/create-selector.json +392 -0
  924. package/templates/v4/floor.json +3 -0
  925. package/templates/v4/modify-selector.json +78 -0
  926. package/templates/v4/templates-metadata.zip +0 -0
  927. package/templates/v4/templates.zip +0 -0
  928. package/build/core/middleware/projectMigratorV3.d.ts +0 -39
  929. package/build/core/middleware/projectMigratorV3.d.ts.map +0 -1
  930. package/build/core/middleware/projectMigratorV3.js +0 -694
  931. package/build/core/middleware/projectMigratorV3.js.map +0 -1
  932. package/build/core/middleware/projectVersionChecker.d.ts +0 -3
  933. package/build/core/middleware/projectVersionChecker.d.ts.map +0 -1
  934. package/build/core/middleware/projectVersionChecker.js +0 -60
  935. package/build/core/middleware/projectVersionChecker.js.map +0 -1
  936. package/build/core/middleware/types.d.ts +0 -9
  937. package/build/core/middleware/types.d.ts.map +0 -1
  938. package/build/core/middleware/types.js.map +0 -1
  939. package/build/core/middleware/utils/MigrationUtils.d.ts +0 -13
  940. package/build/core/middleware/utils/MigrationUtils.d.ts.map +0 -1
  941. package/build/core/middleware/utils/MigrationUtils.js +0 -212
  942. package/build/core/middleware/utils/MigrationUtils.js.map +0 -1
  943. package/build/core/middleware/utils/appYmlGenerator.d.ts +0 -34
  944. package/build/core/middleware/utils/appYmlGenerator.d.ts.map +0 -1
  945. package/build/core/middleware/utils/appYmlGenerator.js +0 -158
  946. package/build/core/middleware/utils/appYmlGenerator.js.map +0 -1
  947. package/build/core/middleware/utils/debug/appLocalYmlGenerator.d.ts +0 -65
  948. package/build/core/middleware/utils/debug/appLocalYmlGenerator.d.ts.map +0 -1
  949. package/build/core/middleware/utils/debug/appLocalYmlGenerator.js +0 -61
  950. package/build/core/middleware/utils/debug/appLocalYmlGenerator.js.map +0 -1
  951. package/build/core/middleware/utils/debug/constants.d.ts +0 -20
  952. package/build/core/middleware/utils/debug/constants.d.ts.map +0 -1
  953. package/build/core/middleware/utils/debug/constants.js +0 -28
  954. package/build/core/middleware/utils/debug/constants.js.map +0 -1
  955. package/build/core/middleware/utils/debug/debugMigrationContext.d.ts +0 -14
  956. package/build/core/middleware/utils/debug/debugMigrationContext.d.ts.map +0 -1
  957. package/build/core/middleware/utils/debug/debugMigrationContext.js +0 -23
  958. package/build/core/middleware/utils/debug/debugMigrationContext.js.map +0 -1
  959. package/build/core/middleware/utils/debug/debugV3MigrationUtils.d.ts +0 -37
  960. package/build/core/middleware/utils/debug/debugV3MigrationUtils.d.ts.map +0 -1
  961. package/build/core/middleware/utils/debug/debugV3MigrationUtils.js +0 -291
  962. package/build/core/middleware/utils/debug/debugV3MigrationUtils.js.map +0 -1
  963. package/build/core/middleware/utils/debug/taskMigrator.d.ts +0 -22
  964. package/build/core/middleware/utils/debug/taskMigrator.d.ts.map +0 -1
  965. package/build/core/middleware/utils/debug/taskMigrator.js +0 -935
  966. package/build/core/middleware/utils/debug/taskMigrator.js.map +0 -1
  967. package/build/core/middleware/utils/migrationContext.d.ts +0 -32
  968. package/build/core/middleware/utils/migrationContext.d.ts.map +0 -1
  969. package/build/core/middleware/utils/migrationContext.js +0 -104
  970. package/build/core/middleware/utils/migrationContext.js.map +0 -1
  971. package/templates/configs/local/typescript/.gitignore +0 -1
  972. package/templates/configs/playground/typescript/.gitignore +0 -4
  973. /package/build/{core/middleware → component/generator/openPlugin}/types.js +0 -0
@@ -1 +1 @@
1
- {"version":3,"file":"helper.d.ts","sourceRoot":"","sources":["../../../../src/component/generator/declarativeAgent/helper.ts"],"names":[],"mappings":"AAEA,OAAO,EAEL,OAAO,EAIP,OAAO,EACP,eAAe,EACf,MAAM,EAEN,oBAAoB,EACpB,MAAM,EAEN,SAAS,EACT,OAAO,EACR,MAAM,wBAAwB,CAAC;AAgBhC,OAAO,EAKL,YAAY,EACb,MAAM,6BAA6B,CAAC;AASrC,MAAM,WAAW,uBAAuB;IACtC,QAAQ,EAAE,OAAO,EAAE,CAAC;IACpB,6BAA6B,EAAE,MAAM,CAAC;CACvC;AAMD,wBAAsB,iBAAiB,CACrC,8BAA8B,EAAE,MAAM,EACtC,sBAAsB,EAAE,MAAM,EAC9B,eAAe,EAAE,MAAM,EACvB,QAAQ,EAAE,MAAM,EAChB,OAAO,EAAE,OAAO,EAChB,MAAM,EAAE,MAAM,GACb,OAAO,CAAC,MAAM,CAAC,uBAAuB,EAAE,OAAO,CAAC,CAAC,CAiGnD;AAED,wBAAgB,4BAA4B,CAC1C,QAAQ,EAAE,oBAAoB,EAC9B,MAAM,EAAE,MAAM,GACb,MAAM,CAAC,SAAS,EAAE,SAAS,CAAC,CA6E9B;AAED,wBAAsB,eAAe,CACnC,OAAO,EAAE,OAAO,EAChB,OAAO,EAAE,MAAM,GAAG,SAAS,GAC1B,OAAO,CAAC,MAAM,CAAC,YAAY,EAAE,EAAE,SAAS,CAAC,CAAC,CAgE5C;AAED,MAAM,WAAW,MAAM;IACrB,EAAE,EAAE,MAAM,CAAC;IACX,KAAK,EAAE,MAAM,CAAC;CACf;AACD,wBAAsB,kBAAkB,IAAI,OAAO,CAAC,MAAM,EAAE,CAAC,CAuC5D;AAED,wBAAsB,mBAAmB,CACvC,eAAe,EAAE,MAAM,EACvB,MAAM,EAAE,MAAM,GACb,OAAO,CAAC,MAAM,CAAC,eAAe,EAAE,OAAO,CAAC,CAAC,CAiG3C"}
1
+ {"version":3,"file":"helper.d.ts","sourceRoot":"","sources":["../../../../src/component/generator/declarativeAgent/helper.ts"],"names":[],"mappings":"AAEA,OAAO,EAEL,OAAO,EAIP,OAAO,EACP,eAAe,EACf,MAAM,EAEN,oBAAoB,EACpB,MAAM,EAEN,SAAS,EACT,OAAO,EACR,MAAM,wBAAwB,CAAC;AA4BhC,OAAO,KAAK,yBAAyB,MAAM,6BAA6B,CAAC;AACzE,OAAO,EAAE,YAAY,EAAE,MAAM,6BAA6B,CAAC;AAY3D;;;;;;;GAOG;AACH,wBAAgB,0BAA0B,CAAC,YAAY,EAAE,MAAM,GAAG,SAAS,GAAG,MAAM,CAWnF;AAED;;;;;;GAMG;AACH,wBAAgB,8BAA8B,CAAC,YAAY,EAAE,MAAM,GAAG,SAAS,GAAG,MAAM,CAEvF;AAED;;;;;;;;GAQG;AACH,wBAAgB,yBAAyB,CAAC,YAAY,EAAE,MAAM,GAAG,SAAS,GAAG,MAAM,CAElF;AAED;;;;;;;;;;;;;;GAcG;AACH,wBAAsB,6BAA6B,CACjD,WAAW,EAAE,MAAM,EACnB,eAAe,EAAE,MAAM,EACvB,4BAA4B,EAAE,MAAM,GACnC,OAAO,CAAC,MAAM,CAAC;IAAE,kBAAkB,EAAE,MAAM,CAAC;IAAC,QAAQ,EAAE,MAAM,CAAA;CAAE,EAAE,OAAO,CAAC,CAAC,CA6C5E;AAED,MAAM,WAAW,uBAAuB;IACtC,QAAQ,EAAE,OAAO,EAAE,CAAC;IACpB,6BAA6B,EAAE,MAAM,CAAC;CACvC;AAMD,wBAAsB,iBAAiB,CACrC,8BAA8B,EAAE,MAAM,EACtC,sBAAsB,EAAE,MAAM,EAC9B,eAAe,EAAE,MAAM,EACvB,QAAQ,EAAE,MAAM,EAChB,OAAO,EAAE,OAAO,EAChB,MAAM,EAAE,MAAM,GACb,OAAO,CAAC,MAAM,CAAC,uBAAuB,EAAE,OAAO,CAAC,CAAC,CAiGnD;AAED,wBAAgB,4BAA4B,CAC1C,QAAQ,EAAE,oBAAoB,EAC9B,MAAM,EAAE,MAAM,GACb,MAAM,CAAC,SAAS,EAAE,SAAS,CAAC,CA6E9B;AAED,wBAAsB,0BAA0B,CAC9C,OAAO,EAAE,OAAO,EAChB,YAAY,EAAE,MAAM,GACnB,OAAO,CAAC,IAAI,CAAC,CAEf;AAED,wBAAsB,0BAA0B,CAAC,OAAO,EAAE,OAAO,2DAEhE;AAED,wBAAsB,+BAA+B,CAAC,WAAW,EAAE,GAAG,EAAE,OAAO,EAAE,MAAM,oEAEtF;AAED,wBAAgB,mBAAmB,CAAC,OAAO,EAAE,MAAM,GAAG,MAAM,CAE3D;AAED,wBAAsB,gBAAgB,CAAC,WAAW,EAAE,GAAG,EAAE,UAAU,EAAE,MAAM,mDAE1E;AAED,wBAAsB,eAAe,CACnC,OAAO,EAAE,OAAO,EAChB,OAAO,EAAE,MAAM,GAAG,SAAS,GAC1B,OAAO,CAAC,MAAM,CAAC,YAAY,EAAE,EAAE,SAAS,CAAC,CAAC,CAmE5C;AAED,MAAM,WAAW,MAAM;IACrB,EAAE,EAAE,MAAM,CAAC;IACX,KAAK,EAAE,MAAM,CAAC;CACf;AACD,wBAAsB,kBAAkB,IAAI,OAAO,CAAC,MAAM,EAAE,CAAC,CAuC5D;AAED,wBAAsB,mBAAmB,CACvC,eAAe,EAAE,MAAM,EACvB,MAAM,EAAE,MAAM,GACb,OAAO,CAAC,MAAM,CAAC,eAAe,EAAE,OAAO,CAAC,CAAC,CAqP3C"}
@@ -1,7 +1,16 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.deriveMCPServerNameFromUrl = deriveMCPServerNameFromUrl;
4
+ exports.deriveMCPRegistrationIdFromUrl = deriveMCPRegistrationIdFromUrl;
5
+ exports.deriveMCPNamespaceFromUrl = deriveMCPNamespaceFromUrl;
6
+ exports.createNewActionPluginManifest = createNewActionPluginManifest;
3
7
  exports.addExistingPlugin = addExistingPlugin;
4
8
  exports.validateSourcePluginManifest = validateSourcePluginManifest;
9
+ exports.setGeneralSensitivityLabel = setGeneralSensitivityLabel;
10
+ exports.createGraphClientWithToken = createGraphClientWithToken;
11
+ exports.getSharePointSiteByRelativePath = getSharePointSiteByRelativePath;
12
+ exports.encodeSharePointUrl = encodeSharePointUrl;
13
+ exports.getDriveItemInfo = getDriveItemInfo;
5
14
  exports.getODSPItemInfo = getODSPItemInfo;
6
15
  exports.getGraphConnectors = getGraphConnectors;
7
16
  exports.generateForMCPForDA = generateForMCPForDA;
@@ -9,24 +18,114 @@ const tslib_1 = require("tslib");
9
18
  // Copyright (c) Microsoft Corporation.
10
19
  // Licensed under the MIT license.
11
20
  const teamsfx_api_1 = require("@microsoft/teamsfx-api");
12
- const CopilotGptManifestUtils_1 = require("../../driver/teamsApp/utils/CopilotGptManifestUtils");
13
- const PluginManifestUtils_1 = require("../../driver/teamsApp/utils/PluginManifestUtils");
14
- const path_1 = tslib_1.__importDefault(require("path"));
21
+ const axios_1 = tslib_1.__importStar(require("axios"));
15
22
  const fs_extra_1 = tslib_1.__importDefault(require("fs-extra"));
16
- const utils_1 = require("../../driver/teamsApp/utils/utils");
23
+ const path_1 = tslib_1.__importDefault(require("path"));
24
+ const constants_1 = require("../../../common/constants");
25
+ const featureFlags_1 = require("../../../common/featureFlags");
26
+ const globalVars_1 = require("../../../common/globalVars");
17
27
  const localizeUtils_1 = require("../../../common/localizeUtils");
18
- const common_1 = require("../../utils/common");
19
28
  const telemetry_1 = require("../../../common/telemetry");
20
29
  const error_1 = require("../../../error");
21
- const axios_1 = tslib_1.__importStar(require("axios"));
22
- const constants_1 = require("../../../common/constants");
23
- const oneDriveSharePointHandler_1 = require("./oneDriveSharePointHandler");
24
- const globalVars_1 = require("../../../common/globalVars");
25
30
  const questionNames_1 = require("../../../question/questionNames");
31
+ const CopilotGptManifestUtils_1 = require("../../driver/teamsApp/utils/CopilotGptManifestUtils");
32
+ const PluginManifestUtils_1 = require("../../driver/teamsApp/utils/PluginManifestUtils");
33
+ const utils_1 = require("../../driver/teamsApp/utils/utils");
34
+ const common_1 = require("../../utils/common");
35
+ const mcpAuthScaffolder_1 = require("../../utils/mcpAuthScaffolder");
36
+ const mcpToolFetcher = tslib_1.__importStar(require("../../utils/mcpToolFetcher"));
37
+ const pathUtils_1 = require("../../utils/pathUtils");
38
+ const generatorUtils = tslib_1.__importStar(require("../utils"));
39
+ const oneDriveSharePointHandler = tslib_1.__importStar(require("./oneDriveSharePointHandler"));
40
+ // Non-translatable CLI command template used in warning messages
41
+ const mcpAddActionHint = "atk add action --api-plugin-type mcp --mcp-da-server-url <server-url> --mcp-tools-file-path <path-to-tools-json> --interactive false";
26
42
  const logMessageKeys = {
27
43
  failValidateOneDriveSharePointItem: "core.createProjectQuestion.log.fail.validateOneDriveSharePointItem",
28
44
  invalidOneDriveSharePointURL: "core.createProjectQuestion.log.fail.invalidOneDriveSharePointURL",
29
45
  };
46
+ /**
47
+ * Derives a server entry name for an MCP server from its URL. Used by both the
48
+ * "DA with MCP" scaffolding (to render `.vscode/mcp.json.tpl`) and the
49
+ * "Add Action with MCP" flow (to append a new entry into `.vscode/mcp.json`).
50
+ *
51
+ * Strips non-alphanumeric characters from the host and truncates to 10 chars.
52
+ * Falls back to `"mcpServer"` when the URL is missing or invalid.
53
+ */
54
+ function deriveMCPServerNameFromUrl(mcpServerUrl) {
55
+ const fallback = "mcpServer";
56
+ if (!mcpServerUrl) {
57
+ return fallback;
58
+ }
59
+ try {
60
+ const host = new URL(mcpServerUrl).host.replace(/[^a-zA-Z0-9]/g, "").substring(0, 10);
61
+ return host || fallback;
62
+ }
63
+ catch {
64
+ return fallback;
65
+ }
66
+ }
67
+ /**
68
+ * Derives the env-var name that holds the `oauth/register` configurationId for
69
+ * the given MCP server URL. Format: `MCP_DA_AUTH_ID_<UPPERCASED>` where
70
+ * `<UPPERCASED>` is `deriveMCPServerNameFromUrl(url).toUpperCase()`. Reused
71
+ * across multiple actions that target the same MCP server so they share one
72
+ * registration. Used by the Dynamic Tool Discovery (DT) DA-with-MCP flow.
73
+ */
74
+ function deriveMCPRegistrationIdFromUrl(mcpServerUrl) {
75
+ return `MCP_DA_AUTH_ID_${deriveMCPServerNameFromUrl(mcpServerUrl).toUpperCase()}`;
76
+ }
77
+ /**
78
+ * Derives the `ai-plugin.json` `namespace` (and the matching `oauth/register`
79
+ * action `name`) for an MCP-backed action from the MCP server URL. Format:
80
+ * `deriveMCPServerNameFromUrl(url).toLowerCase()` — a schema-valid
81
+ * (alphanumeric, lowercase) token unique per MCP server host. Shared by both
82
+ * the create flow and the add-action flow so actions targeting different MCP
83
+ * servers get distinct namespaces while actions sharing one server stay aligned
84
+ * with the single registration they share.
85
+ */
86
+ function deriveMCPNamespaceFromUrl(mcpServerUrl) {
87
+ return deriveMCPServerNameFromUrl(mcpServerUrl).toLowerCase();
88
+ }
89
+ /**
90
+ * Creates a brand-new empty action plugin manifest (`ai-plugin.json`) under the
91
+ * project's `appPackage` folder and registers it as a new action in the
92
+ * declarative agent manifest.
93
+ *
94
+ * Used by the "Add MCP Action" flow when the user opts to create a new
95
+ * action manifest rather than reuse an existing one.
96
+ *
97
+ * @param projectPath Absolute project root.
98
+ * @param desiredFileName File name (no path) for the new plugin manifest, e.g. "ai-plugin.json".
99
+ * If a file with this name already exists, an incrementing suffix is added.
100
+ * @param declarativeAgentManifestPath Absolute path to the declarative agent manifest file
101
+ * (e.g. `appPackage/declarativeAgent.json`).
102
+ * @returns The absolute path to the newly-created plugin manifest and the action id used to register it.
103
+ */
104
+ async function createNewActionPluginManifest(projectPath, desiredFileName, declarativeAgentManifestPath) {
105
+ const appPackageFolder = path_1.default.join(projectPath, teamsfx_api_1.AppPackageFolderName);
106
+ const fileName = desiredFileName?.trim() || teamsfx_api_1.DefaultPluginManifestFileName;
107
+ const destinationPluginManifestPath = await CopilotGptManifestUtils_1.copilotGptManifestUtils.getDefaultNextAvailablePluginManifestPath(appPackageFolder, fileName);
108
+ const projectName = path_1.default.basename(projectPath);
109
+ const namespace = projectName.toLowerCase().replace(/[^a-z0-9]/g, "") || "actions";
110
+ const skeleton = {
111
+ $schema: "https://developer.microsoft.com/json-schemas/copilot/plugin/v2.4/schema.json",
112
+ schema_version: "v2.4",
113
+ name_for_human: projectName,
114
+ description_for_human: projectName,
115
+ namespace,
116
+ functions: [],
117
+ runtimes: [],
118
+ };
119
+ await fs_extra_1.default.ensureFile(destinationPluginManifestPath);
120
+ await fs_extra_1.default.writeJSON(destinationPluginManifestPath, skeleton, { spaces: 4 });
121
+ const actionId = path_1.default.basename(destinationPluginManifestPath, path_1.default.extname(destinationPluginManifestPath));
122
+ const relativePluginPath = (0, utils_1.normalizePath)(path_1.default.relative(path_1.default.dirname(declarativeAgentManifestPath), destinationPluginManifestPath), true);
123
+ const addActionRes = await CopilotGptManifestUtils_1.copilotGptManifestUtils.addAction(declarativeAgentManifestPath, actionId, relativePluginPath);
124
+ if (addActionRes.isErr()) {
125
+ return (0, teamsfx_api_1.err)(addActionRes.error);
126
+ }
127
+ return (0, teamsfx_api_1.ok)({ pluginManifestPath: destinationPluginManifestPath, actionId });
128
+ }
30
129
  const pluginManifestPlaceholderWarning = "add-exsiting-plugin-manifest-placehoder";
31
130
  const apiSpecPlaceholderWarning = "add-exsiting-plugin-api-spec-placehoder";
32
131
  const readApiSpecErrorTelemetry = "read-api-spec-error";
@@ -120,17 +219,32 @@ function validateSourcePluginManifest(manifest, source) {
120
219
  }
121
220
  return (0, teamsfx_api_1.ok)(undefined);
122
221
  }
222
+ async function setGeneralSensitivityLabel(context, manifestPath) {
223
+ await generatorUtils.setGeneralSensitivityLabel(context, manifestPath);
224
+ }
225
+ async function createGraphClientWithToken(context) {
226
+ return oneDriveSharePointHandler.createGraphClientWithToken(context);
227
+ }
228
+ async function getSharePointSiteByRelativePath(graphClient, itemUrl) {
229
+ return oneDriveSharePointHandler.getSharePointSiteByRelativePath(graphClient, itemUrl);
230
+ }
231
+ function encodeSharePointUrl(itemUrl) {
232
+ return oneDriveSharePointHandler.encodeSharePointUrl(itemUrl);
233
+ }
234
+ async function getDriveItemInfo(graphClient, encodedUrl) {
235
+ return oneDriveSharePointHandler.getDriveItemInfo(graphClient, encodedUrl);
236
+ }
123
237
  async function getODSPItemInfo(context, itemUrl) {
124
238
  if (!itemUrl) {
125
239
  return (0, teamsfx_api_1.err)(new teamsfx_api_1.UserError("validateOneDriveSharePointItem", "InvalidInput", "Item URL is required"));
126
240
  }
127
241
  try {
128
- const graphClientResult = await (0, oneDriveSharePointHandler_1.createGraphClientWithToken)(context);
242
+ const graphClientResult = await oneDriveSharePointHandler.createGraphClientWithToken(context);
129
243
  if (graphClientResult.isErr()) {
130
244
  return (0, teamsfx_api_1.err)(graphClientResult.error);
131
245
  }
132
246
  const graphClient = graphClientResult.value;
133
- const siteResult = await (0, oneDriveSharePointHandler_1.getSharePointSiteByRelativePath)(graphClient, itemUrl);
247
+ const siteResult = await oneDriveSharePointHandler.getSharePointSiteByRelativePath(graphClient, itemUrl);
134
248
  if (siteResult.isOk()) {
135
249
  const site = siteResult.value;
136
250
  return (0, teamsfx_api_1.ok)([
@@ -142,8 +256,8 @@ async function getODSPItemInfo(context, itemUrl) {
142
256
  },
143
257
  ]);
144
258
  }
145
- const encodedUrl = (0, oneDriveSharePointHandler_1.encodeSharePointUrl)(itemUrl);
146
- const driveItem = await (0, oneDriveSharePointHandler_1.getDriveItemInfo)(graphClient, encodedUrl);
259
+ const encodedUrl = oneDriveSharePointHandler.encodeSharePointUrl(itemUrl);
260
+ const driveItem = await oneDriveSharePointHandler.getDriveItemInfo(graphClient, encodedUrl);
147
261
  return (0, teamsfx_api_1.ok)([
148
262
  {
149
263
  id: driveItem.id,
@@ -202,81 +316,373 @@ async function getGraphConnectors() {
202
316
  }
203
317
  }
204
318
  async function generateForMCPForDA(destinationPath, inputs) {
319
+ const mcpServerUrl = inputs[questionNames_1.QuestionNames.MCPForDAServerUrl];
320
+ if (!mcpServerUrl) {
321
+ return (0, teamsfx_api_1.err)(new teamsfx_api_1.UserError({
322
+ source: "Scaffold",
323
+ name: "InputValidationFailed",
324
+ message: "mcpServerUrl is required when --api-plugin-type is mcp.",
325
+ displayMessage: (0, localizeUtils_1.getLocalizedString)("core.MCPForDA.missingServerUrl"),
326
+ }));
327
+ }
205
328
  // 1. Get ai-plugin.json
206
329
  const aiPluginFilePath = path_1.default.join(destinationPath, teamsfx_api_1.AppPackageFolderName, teamsfx_api_1.DefaultPluginManifestFileName);
207
330
  if (!(await fs_extra_1.default.pathExists(aiPluginFilePath))) {
208
331
  const error = new teamsfx_api_1.SystemError("MCPForDAPluginManifestNotFound", "PluginManifestNotFound", (0, localizeUtils_1.getDefaultString)("core.MCPForDA.pluginManifestNotFound", aiPluginFilePath), (0, localizeUtils_1.getLocalizedString)("core.MCPForDA.pluginManifestNotFound", aiPluginFilePath));
209
332
  return (0, teamsfx_api_1.err)(error);
210
333
  }
211
- const mcpServerUrl = inputs[questionNames_1.QuestionNames.MCPForDAServerUrl];
334
+ // Dynamic Tool Discovery flow: skip static tool fetch/selection entirely;
335
+ // the agent host discovers tools at runtime against the MCP server. Per
336
+ // SCN-DA-CREATE-WITH-MCP-SERVER this DT runtime shape is gated behind
337
+ // TEAMSFX_MCP_FOR_DA_DT: when the flag is off the create flow keeps the
338
+ // legacy static-tools behavior (populated `functions` + `mcp-tools-1.json`),
339
+ // matching the add-action flow. We also require the auth-type answer so
340
+ // legacy fixtures that mock inputs without it stay on the static-tools path.
341
+ if (featureFlags_1.featureFlagManager.getBooleanValue(featureFlags_1.FeatureFlags.MCPForDADT) &&
342
+ inputs[questionNames_1.QuestionNames.MCPForDAAuthType]) {
343
+ return generateForMCPForDAWithAuth(destinationPath, aiPluginFilePath, inputs);
344
+ }
212
345
  const serverName = inputs[questionNames_1.QuestionNames.MCPForDAServerName];
213
- const mcpTool = inputs[questionNames_1.QuestionNames.MCPForDATool];
346
+ const warnings = [];
347
+ // If a tools file is provided (CLI flow), load tools from it
348
+ const toolsFilePath = inputs[questionNames_1.QuestionNames.MCPToolsFilePath];
349
+ const existingTools = inputs[questionNames_1.QuestionNames.MCPForDAAvailableTools];
350
+ if (toolsFilePath && (!existingTools || existingTools.length === 0)) {
351
+ try {
352
+ const fileTools = await mcpToolFetcher.readMCPToolsFromFile(toolsFilePath);
353
+ inputs[questionNames_1.QuestionNames.MCPForDAAvailableTools] = fileTools;
354
+ if (!inputs[questionNames_1.QuestionNames.MCPForDAPreFetchTools]) {
355
+ inputs[questionNames_1.QuestionNames.MCPForDAPreFetchTools] = fileTools.map((t) => t.name);
356
+ }
357
+ }
358
+ catch {
359
+ warnings.push({
360
+ type: "mcpToolsFileReadError",
361
+ content: (0, localizeUtils_1.getLocalizedString)("core.MCPForDA.toolsFileReadError", toolsFilePath, mcpAddActionHint),
362
+ });
363
+ }
364
+ }
365
+ // Probe auth if tools were loaded from file but auth not yet detected
366
+ if (inputs[questionNames_1.QuestionNames.MCPForDAAvailableTools]?.length > 0 &&
367
+ !inputs[questionNames_1.QuestionNames.MCPForDAAuth] &&
368
+ mcpServerUrl) {
369
+ try {
370
+ const authProbe = await mcpToolFetcher.probeMCPServerAuth(mcpServerUrl);
371
+ if (authProbe.requiresAuth) {
372
+ inputs[questionNames_1.QuestionNames.MCPForDAAuth] = "OAuthPluginVault";
373
+ if (authProbe.authMetadataUrl) {
374
+ inputs[questionNames_1.QuestionNames.MCPForDAAuthMetadataUrl] = authProbe.authMetadataUrl;
375
+ }
376
+ }
377
+ }
378
+ catch {
379
+ // Auth probe failed — continue without auth
380
+ }
381
+ }
382
+ // Auto-fetch tools from MCP server if no tools loaded yet
383
+ const currentTools = inputs[questionNames_1.QuestionNames.MCPForDAAvailableTools];
384
+ if ((!currentTools || currentTools.length === 0) && mcpServerUrl) {
385
+ try {
386
+ const result = await mcpToolFetcher.fetchMCPTools(mcpServerUrl);
387
+ if (!result.requiresAuth && result.tools.length > 0) {
388
+ inputs[questionNames_1.QuestionNames.MCPForDAAvailableTools] = result.tools;
389
+ if (!inputs[questionNames_1.QuestionNames.MCPForDAPreFetchTools]) {
390
+ inputs[questionNames_1.QuestionNames.MCPForDAPreFetchTools] = result.tools.map((t) => t.name);
391
+ }
392
+ }
393
+ else if (result.requiresAuth) {
394
+ // Store auth metadata for later use
395
+ inputs[questionNames_1.QuestionNames.MCPForDAAuth] = "OAuthPluginVault";
396
+ if (result.authMetadataUrl) {
397
+ inputs[questionNames_1.QuestionNames.MCPForDAAuthMetadataUrl] = result.authMetadataUrl;
398
+ }
399
+ warnings.push({
400
+ type: "mcpAuthRequired",
401
+ content: (0, localizeUtils_1.getLocalizedString)("core.MCPForDA.authRequired", mcpServerUrl, mcpAddActionHint),
402
+ });
403
+ }
404
+ else {
405
+ warnings.push({
406
+ type: "mcpNoToolsFetched",
407
+ content: (0, localizeUtils_1.getLocalizedString)("core.MCPForDA.noToolsFetched", mcpServerUrl, mcpAddActionHint),
408
+ });
409
+ }
410
+ }
411
+ catch {
412
+ warnings.push({
413
+ type: "mcpFetchError",
414
+ content: (0, localizeUtils_1.getLocalizedString)("core.MCPForDA.fetchError", mcpServerUrl, mcpAddActionHint),
415
+ });
416
+ }
417
+ }
214
418
  // 2. Read ai-plugin.json
215
419
  const aiPluginContent = await fs_extra_1.default.readJSON(aiPluginFilePath);
216
- // For dynamic fetch tools, keep the functions empty and add runtime info
217
- if (mcpTool === "dynamic-fetch") {
218
- aiPluginContent.functions = [];
219
- aiPluginContent.runtimes = [
220
- {
221
- type: "RemoteMCPServer",
222
- spec: {
223
- url: mcpServerUrl,
224
- enable_dynamic_discovery: true,
225
- },
226
- },
227
- ];
228
- }
229
- else {
230
- // For pre-fetch tools, add the tool info to ai-plugin.json
231
- const mcpToolsDetail = inputs[questionNames_1.QuestionNames.MCPForDAAvailableTools];
232
- const mcpToolsSelected = inputs[questionNames_1.QuestionNames.MCPForDAPreFetchTools];
420
+ const mcpToolsDetail = inputs[questionNames_1.QuestionNames.MCPForDAAvailableTools];
421
+ const mcpToolsSelected = inputs[questionNames_1.QuestionNames.MCPForDAPreFetchTools];
422
+ if (mcpToolsDetail &&
423
+ mcpToolsDetail.length > 0 &&
424
+ mcpToolsSelected &&
425
+ mcpToolsSelected.length > 0) {
233
426
  const mcpAuth = inputs[questionNames_1.QuestionNames.MCPForDAAuth];
234
- if (!mcpToolsDetail || !mcpToolsSelected) {
235
- const error = new teamsfx_api_1.UserError("MCPForDAPreFetchToolsNotFound", "PreFetchToolsNotFound", (0, localizeUtils_1.getDefaultString)("core.MCPForDA.preFetchToolsNotFound"), (0, localizeUtils_1.getLocalizedString)("core.MCPForDA.preFetchToolsNotFound"));
236
- return (0, teamsfx_api_1.err)(error);
427
+ // Process tools: if serverName exists (VS Code flow), strip the prefix; otherwise use as-is (CLI flow)
428
+ let processedTools;
429
+ if (serverName) {
430
+ processedTools = mcpToolsDetail
431
+ .filter((tool) => tool.name.includes(serverName))
432
+ .map((tool) => {
433
+ const index = tool.name.indexOf(serverName);
434
+ const newName = tool.name.substring(index + serverName.length + 1);
435
+ return {
436
+ ...tool,
437
+ name: newName,
438
+ };
439
+ })
440
+ .filter((tool) => mcpToolsSelected.includes(tool.name));
237
441
  }
238
- aiPluginContent.functions = mcpToolsDetail
239
- .filter((tool) => tool.name.includes(serverName))
240
- .map((tool) => {
241
- const index = tool.name.indexOf(serverName);
242
- const newName = tool.name.substring(index + serverName.length + 1);
243
- return {
244
- name: newName,
245
- description: tool.description,
246
- inputSchema: tool.inputSchema,
247
- tags: tool.tags,
248
- };
249
- })
250
- .filter((tool) => mcpToolsSelected.includes(tool.name))
251
- .map((tool) => {
442
+ else {
443
+ processedTools = mcpToolsDetail.filter((tool) => mcpToolsSelected.includes(tool.name));
444
+ }
445
+ aiPluginContent.functions = processedTools.map((tool) => {
252
446
  return {
253
447
  name: tool.name,
254
- description: tool.description,
255
- parameters: {
256
- type: tool.inputSchema.type || "object",
257
- properties: tool.inputSchema.properties,
258
- required: tool.inputSchema.required || [],
259
- },
448
+ description: tool.description || "",
260
449
  };
261
450
  });
451
+ // Write mcp-tools-1.json with full tool definitions (no field filtering)
452
+ const mcpToolsFileName = "mcp-tools-1.json";
453
+ const mcpToolsOutputPath = path_1.default.join(destinationPath, teamsfx_api_1.AppPackageFolderName, mcpToolsFileName);
454
+ await fs_extra_1.default.writeJSON(mcpToolsOutputPath, { tools: processedTools }, { spaces: 4 });
455
+ const runtimeSpec = {
456
+ url: mcpServerUrl,
457
+ mcp_tool_description: {
458
+ file: mcpToolsFileName,
459
+ },
460
+ };
262
461
  aiPluginContent.runtimes = [
263
462
  {
264
463
  type: "RemoteMCPServer",
265
- spec: {
266
- url: mcpServerUrl,
267
- },
464
+ spec: runtimeSpec,
268
465
  run_for_functions: aiPluginContent.functions.map((func) => func.name),
269
466
  },
270
467
  ];
468
+ // Auth handling
271
469
  if (mcpAuth === "OAuthPluginVault") {
272
- aiPluginContent.runtimes[0].auth = {
273
- type: "OAuthPluginVault",
274
- reference_id: "${{MCP_DA_AUTH_ID}}",
275
- };
470
+ const authType = inputs[questionNames_1.QuestionNames.MCPForDAAuthType];
471
+ if (!authType) {
472
+ return (0, teamsfx_api_1.err)(new teamsfx_api_1.UserError("MCPForDA", "MissingMCPAuthType", (0, localizeUtils_1.getDefaultString)("core.MCPForDA.missingAuthType"), (0, localizeUtils_1.getLocalizedString)("core.MCPForDA.missingAuthType")));
473
+ }
474
+ const registrationId = "MCP_DA_AUTH_ID_ACTION_1";
475
+ const manifestOAuth = (0, mcpAuthScaffolder_1.deriveMCPManifestOAuth)(authType, registrationId);
476
+ if (manifestOAuth) {
477
+ aiPluginContent.runtimes[0].auth = manifestOAuth;
478
+ }
479
+ // Resolve OAuth metadata and inject oauth/register into m365agents.yml
480
+ try {
481
+ const endpoints = await (0, mcpAuthScaffolder_1.resolveMCPAuthEndpoints)(authType, inputs);
482
+ const ymlPath = pathUtils_1.pathUtils.getYmlFilePath(destinationPath);
483
+ if (ymlPath) {
484
+ const injectResult = await (0, mcpAuthScaffolder_1.injectMCPAuthActionToYml)({
485
+ ymlPath,
486
+ authType,
487
+ authName: aiPluginContent.namespace || "action_1",
488
+ registrationId,
489
+ mcpServerUrl,
490
+ endpoints,
491
+ });
492
+ if (injectResult.wellKnownUrlPlaceholderUsed) {
493
+ warnings.push({
494
+ type: "mcpAuthDcrWellKnownUrlPlaceholder",
495
+ content: (0, localizeUtils_1.getLocalizedString)("core.MCPForDA.mcpAuthDcrPlaceholderWarning"),
496
+ });
497
+ }
498
+ if (injectResult.oauthUrlPlaceholderUsed) {
499
+ warnings.push({
500
+ type: "mcpAuthOAuthUrlPlaceholder",
501
+ content: (0, localizeUtils_1.getLocalizedString)("core.MCPForDA.mcpAuthOAuthPlaceholderWarning"),
502
+ });
503
+ }
504
+ }
505
+ }
506
+ catch (error) {
507
+ warnings.push({
508
+ type: "mcpAuthMetadataError",
509
+ content: (0, localizeUtils_1.getLocalizedString)("core.MCPForDA.mcpAuthMetadataMissingError", error.message),
510
+ });
511
+ }
276
512
  }
277
513
  }
514
+ // If no tools available, leave ai-plugin.json with empty functions/runtimes (template default)
278
515
  // 3. Write ai-plugin.json
279
516
  await fs_extra_1.default.writeJSON(aiPluginFilePath, aiPluginContent, { spaces: 4 });
280
- return (0, teamsfx_api_1.ok)([]); // Return empty warnings
517
+ return (0, teamsfx_api_1.ok)({ warnings });
518
+ }
519
+ /**
520
+ * Modern DA-with-MCP scaffolder. Selected by `generateForMCPForDA` only when
521
+ * TEAMSFX_MCP_FOR_DA_DT is on AND the create flow answered `MCPForDAAuthType`.
522
+ * When the flag is off, the dispatcher keeps the legacy static-tools path
523
+ * instead, so this function never runs with the flag off.
524
+ *
525
+ * Emits the Dynamic Tool Discovery runtime shape per
526
+ * SCN-DA-CREATE-WITH-MCP-SERVER: `RemoteMCPServer` with a `spec` that carries
527
+ * only the MCP server `url` (no `mcp_tool_description`) and
528
+ * `run_for_functions: ["*"]`. Per the v2.4 plugin schema, omitting
529
+ * `mcp_tool_description` is what makes the host use dynamic tool discovery — no
530
+ * `mcp-tools-N.json` is written and `functions` stays an empty array
531
+ * (schema-required field; tools are discovered at runtime rather than declared
532
+ * statically). This DT shape is gated behind TEAMSFX_MCP_FOR_DA_DT via the
533
+ * dispatcher; with the flag off the create flow produces the legacy static
534
+ * shape instead.
535
+ *
536
+ * OAuth credentials reach the provisioned `oauth/register` action as
537
+ * `${{MCP_DA_OAUTH_*_<SUFFIX>}}` refs in m365agents.yml, persisted to
538
+ * env/.env.<env>(.user). (The in-process `process.env` bridge below is a
539
+ * defensive fallback for the flag-off path, which the dispatcher no longer
540
+ * routes here.)
541
+ */
542
+ async function generateForMCPForDAWithAuth(destinationPath, aiPluginFilePath, inputs) {
543
+ const mcpServerUrl = inputs[questionNames_1.QuestionNames.MCPForDAServerUrl];
544
+ const warnings = [];
545
+ const aiPluginContent = await fs_extra_1.default.readJSON(aiPluginFilePath);
546
+ aiPluginContent.functions = [];
547
+ // Namespace the action by the MCP server host (shared rule with the
548
+ // add-action flow) instead of the project name, so actions targeting
549
+ // different MCP servers get distinct namespaces and the matching
550
+ // oauth/register `name` derives from the same source.
551
+ if (mcpServerUrl) {
552
+ aiPluginContent.namespace = deriveMCPNamespaceFromUrl(mcpServerUrl);
553
+ }
554
+ const runtime = {
555
+ type: "RemoteMCPServer",
556
+ spec: { url: mcpServerUrl },
557
+ run_for_functions: ["*"],
558
+ };
559
+ if (mcpServerUrl) {
560
+ const authType = inputs[questionNames_1.QuestionNames.MCPForDAAuthType];
561
+ if (authType === "none") {
562
+ runtime.auth = { type: "None" };
563
+ }
564
+ else if (authType) {
565
+ const serverName = deriveMCPServerNameFromUrl(mcpServerUrl).toUpperCase();
566
+ const registrationId = deriveMCPRegistrationIdFromUrl(mcpServerUrl);
567
+ const manifestOAuth = (0, mcpAuthScaffolder_1.deriveMCPManifestOAuth)(authType, registrationId);
568
+ if (manifestOAuth) {
569
+ runtime.auth = manifestOAuth;
570
+ }
571
+ // Probe the MCP server for resource_metadata so `resolveMCPAuthEndpoints`
572
+ // can discover authorization/token URLs. The legacy `generateForMCPForDA`
573
+ // branch populates `MCPForDAAuthMetadataUrl` via fetchMCPTools; the DT
574
+ // branch skips tool fetch, so we need an explicit probe here. Best-effort.
575
+ if (!inputs[questionNames_1.QuestionNames.MCPForDAAuthMetadataUrl]) {
576
+ try {
577
+ const authProbe = await mcpToolFetcher.probeMCPServerAuth(mcpServerUrl);
578
+ if (authProbe.authMetadataUrl) {
579
+ inputs[questionNames_1.QuestionNames.MCPForDAAuthMetadataUrl] = authProbe.authMetadataUrl;
580
+ }
581
+ // This branch never fetches tools, so a mistyped server URL would otherwise leave no
582
+ // trace at all: endpoint discovery falls back to the host and happily returns its
583
+ // authorization server, and the scaffold looks complete. Warns on every `notEndpoint`
584
+ // shape, not just 404 — this is advisory, so it can be broader than the blocking rule
585
+ // applied when the URL is first entered.
586
+ if (authProbe.endpointStatus === "notEndpoint") {
587
+ warnings.push({
588
+ type: "mcpServerUrlNotAnEndpoint",
589
+ content: (0, localizeUtils_1.getLocalizedString)("core.MCPForDA.mcpServerUrlNotAnEndpoint", mcpServerUrl, String(authProbe.responseStatus)),
590
+ });
591
+ }
592
+ }
593
+ catch {
594
+ // Probe failed — continue; endpoint resolution below will best-effort
595
+ // and yml injection will still run with undefined endpoints.
596
+ }
597
+ }
598
+ // Endpoint resolution is best-effort: a failure (server unreachable, no
599
+ // well-known metadata, etc.) must not block credential persistence or
600
+ // yml injection. The OAuth action injector tolerates undefined endpoint
601
+ // URLs; the developer can fill them in later.
602
+ let endpoints = {};
603
+ try {
604
+ endpoints = await (0, mcpAuthScaffolder_1.resolveMCPAuthEndpoints)(authType, inputs);
605
+ }
606
+ catch (error) {
607
+ warnings.push({
608
+ type: "mcpAuthMetadataError",
609
+ content: (0, localizeUtils_1.getLocalizedString)("core.MCPForDA.mcpAuthMetadataMissingError", error.message),
610
+ });
611
+ }
612
+ const dtOn = featureFlags_1.featureFlagManager.getBooleanValue(featureFlags_1.FeatureFlags.MCPForDADT);
613
+ try {
614
+ const ymlPath = pathUtils_1.pathUtils.getYmlFilePath(destinationPath);
615
+ if (ymlPath) {
616
+ const injectResult = await (0, mcpAuthScaffolder_1.injectMCPAuthActionToYml)({
617
+ ymlPath,
618
+ authType,
619
+ authName: aiPluginContent.namespace || "action_1",
620
+ registrationId,
621
+ mcpServerUrl,
622
+ endpoints,
623
+ persistCredentialEnvRefs: dtOn,
624
+ serverName,
625
+ scopes: inputs[questionNames_1.QuestionNames.MCPForDAScopes],
626
+ });
627
+ if (injectResult.wellKnownUrlPlaceholderUsed) {
628
+ warnings.push({
629
+ type: "mcpAuthDcrWellKnownUrlPlaceholder",
630
+ content: (0, localizeUtils_1.getLocalizedString)("core.MCPForDA.mcpAuthDcrPlaceholderWarning"),
631
+ });
632
+ }
633
+ if (injectResult.oauthUrlPlaceholderUsed) {
634
+ warnings.push({
635
+ type: "mcpAuthOAuthUrlPlaceholder",
636
+ content: (0, localizeUtils_1.getLocalizedString)("core.MCPForDA.mcpAuthOAuthPlaceholderWarning"),
637
+ });
638
+ }
639
+ }
640
+ }
641
+ catch (error) {
642
+ warnings.push({
643
+ type: "mcpAuthYmlInjectionError",
644
+ content: (0, localizeUtils_1.getLocalizedString)("core.MCPForDA.mcpAuthMetadataMissingError", error.message),
645
+ });
646
+ }
647
+ if (dtOn) {
648
+ try {
649
+ await (0, mcpAuthScaffolder_1.persistMCPAuthCredentialEnvVars)({
650
+ projectPath: destinationPath,
651
+ authType,
652
+ serverName,
653
+ clientId: inputs[questionNames_1.QuestionNames.MCPForDAClientId],
654
+ clientSecret: inputs[questionNames_1.QuestionNames.MCPForDAClientSecret],
655
+ scopes: inputs[questionNames_1.QuestionNames.MCPForDAScopes],
656
+ });
657
+ }
658
+ catch (error) {
659
+ warnings.push({
660
+ type: "mcpAuthEnvPersistError",
661
+ content: (0, localizeUtils_1.getLocalizedString)("core.MCPForDA.mcpAuthMetadataMissingError", error.message),
662
+ });
663
+ }
664
+ }
665
+ else {
666
+ // Populate the in-process bridge consumed by oauth/create.ts so
667
+ // provision picks up create-time answers without re-prompting via
668
+ // QuestionMW. Only static OAuth and Entra SSO contribute creds.
669
+ const clientId = inputs[questionNames_1.QuestionNames.MCPForDAClientId];
670
+ const clientSecret = inputs[questionNames_1.QuestionNames.MCPForDAClientSecret];
671
+ const scopes = inputs[questionNames_1.QuestionNames.MCPForDAScopes];
672
+ if (clientId) {
673
+ process.env[questionNames_1.QuestionNames.OauthClientId] = clientId;
674
+ }
675
+ if (clientSecret) {
676
+ process.env[questionNames_1.QuestionNames.OauthClientSecret] = clientSecret;
677
+ }
678
+ if (scopes) {
679
+ process.env[questionNames_1.QuestionNames.OAuthScope] = scopes;
680
+ }
681
+ }
682
+ }
683
+ }
684
+ aiPluginContent.runtimes = [runtime];
685
+ await fs_extra_1.default.writeJSON(aiPluginFilePath, aiPluginContent, { spaces: 4 });
686
+ return (0, teamsfx_api_1.ok)({ warnings });
281
687
  }
282
688
  //# sourceMappingURL=helper.js.map