@microsoft/teamsfx-core 1.1.1 → 1.1.2-alpha.30d0724a.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 (447) hide show
  1. package/build/common/armInterface.d.ts +1 -1
  2. package/build/common/armInterface.d.ts.map +1 -1
  3. package/build/common/constants.d.ts +3 -2
  4. package/build/common/constants.d.ts.map +1 -1
  5. package/build/common/constants.js +3 -2
  6. package/build/common/constants.js.map +1 -1
  7. package/build/common/local/localEnvManager.d.ts +17 -0
  8. package/build/common/local/localEnvManager.d.ts.map +1 -0
  9. package/build/common/local/localEnvManager.js +72 -0
  10. package/build/common/local/localEnvManager.js.map +1 -0
  11. package/build/common/localSettingsProvider.d.ts +3 -3
  12. package/build/common/localSettingsProvider.d.ts.map +1 -1
  13. package/build/common/localSettingsProvider.js +11 -6
  14. package/build/common/localSettingsProvider.js.map +1 -1
  15. package/build/common/samples-config.json +14 -0
  16. package/build/common/tools.d.ts +11 -1
  17. package/build/common/tools.d.ts.map +1 -1
  18. package/build/common/tools.js +23 -10
  19. package/build/common/tools.js.map +1 -1
  20. package/build/core/SolutionPluginContainer.d.ts +2 -1
  21. package/build/core/SolutionPluginContainer.d.ts.map +1 -1
  22. package/build/core/SolutionPluginContainer.js +9 -1
  23. package/build/core/SolutionPluginContainer.js.map +1 -1
  24. package/build/core/environment.d.ts +4 -3
  25. package/build/core/environment.d.ts.map +1 -1
  26. package/build/core/environment.js +37 -7
  27. package/build/core/environment.js.map +1 -1
  28. package/build/core/error.d.ts +2 -1
  29. package/build/core/error.d.ts.map +1 -1
  30. package/build/core/error.js +7 -3
  31. package/build/core/error.js.map +1 -1
  32. package/build/core/index.d.ts +52 -14
  33. package/build/core/index.d.ts.map +1 -1
  34. package/build/core/index.js +699 -485
  35. package/build/core/index.js.map +1 -1
  36. package/build/core/middleware/concurrentLocker.d.ts.map +1 -1
  37. package/build/core/middleware/concurrentLocker.js +23 -12
  38. package/build/core/middleware/concurrentLocker.js.map +1 -1
  39. package/build/core/middleware/envInfoLoader.d.ts +5 -1
  40. package/build/core/middleware/envInfoLoader.d.ts.map +1 -1
  41. package/build/core/middleware/envInfoLoader.js +51 -44
  42. package/build/core/middleware/envInfoLoader.js.map +1 -1
  43. package/build/core/middleware/envInfoLoaderV3.d.ts +3 -0
  44. package/build/core/middleware/envInfoLoaderV3.d.ts.map +1 -0
  45. package/build/core/middleware/envInfoLoaderV3.js +64 -0
  46. package/build/core/middleware/envInfoLoaderV3.js.map +1 -0
  47. package/build/core/middleware/envInfoWriter.js +13 -30
  48. package/build/core/middleware/envInfoWriter.js.map +1 -1
  49. package/build/core/middleware/envInfoWriterV3.d.ts +6 -0
  50. package/build/core/middleware/envInfoWriterV3.d.ts.map +1 -0
  51. package/build/core/middleware/envInfoWriterV3.js +63 -0
  52. package/build/core/middleware/envInfoWriterV3.js.map +1 -0
  53. package/build/core/middleware/errorHandler.d.ts.map +1 -1
  54. package/build/core/middleware/errorHandler.js +3 -5
  55. package/build/core/middleware/errorHandler.js.map +1 -1
  56. package/build/core/middleware/localSettingsLoader.js.map +1 -1
  57. package/build/core/middleware/localSettingsWriter.d.ts.map +1 -1
  58. package/build/core/middleware/localSettingsWriter.js +6 -16
  59. package/build/core/middleware/localSettingsWriter.js.map +1 -1
  60. package/build/core/middleware/projectMigrator.d.ts.map +1 -1
  61. package/build/core/middleware/projectMigrator.js +22 -54
  62. package/build/core/middleware/projectMigrator.js.map +1 -1
  63. package/build/core/middleware/projectSettingsLoader.d.ts.map +1 -1
  64. package/build/core/middleware/projectSettingsLoader.js +2 -4
  65. package/build/core/middleware/projectSettingsLoader.js.map +1 -1
  66. package/build/core/middleware/projectSettingsLoaderV3.d.ts +4 -0
  67. package/build/core/middleware/projectSettingsLoaderV3.d.ts.map +1 -0
  68. package/build/core/middleware/projectSettingsLoaderV3.js +49 -0
  69. package/build/core/middleware/projectSettingsLoaderV3.js.map +1 -0
  70. package/build/core/middleware/projectSettingsWriter.d.ts.map +1 -1
  71. package/build/core/middleware/projectSettingsWriter.js +2 -2
  72. package/build/core/middleware/projectSettingsWriter.js.map +1 -1
  73. package/build/core/middleware/questionModel.d.ts +14 -1
  74. package/build/core/middleware/questionModel.d.ts.map +1 -1
  75. package/build/core/middleware/questionModel.js +319 -23
  76. package/build/core/middleware/questionModel.js.map +1 -1
  77. package/build/core/middleware/solutionLoader.d.ts +3 -2
  78. package/build/core/middleware/solutionLoader.d.ts.map +1 -1
  79. package/build/core/middleware/solutionLoader.js +21 -23
  80. package/build/core/middleware/solutionLoader.js.map +1 -1
  81. package/build/core/middleware/solutionLoaderV3.d.ts +4 -0
  82. package/build/core/middleware/solutionLoaderV3.d.ts.map +1 -0
  83. package/build/core/middleware/solutionLoaderV3.js +19 -0
  84. package/build/core/middleware/solutionLoaderV3.js.map +1 -0
  85. package/build/core/question.d.ts +9 -1
  86. package/build/core/question.d.ts.map +1 -1
  87. package/build/core/question.js +113 -3
  88. package/build/core/question.js.map +1 -1
  89. package/build/core/tools.d.ts +2 -1
  90. package/build/core/tools.d.ts.map +1 -1
  91. package/build/core/tools.js +15 -1
  92. package/build/core/tools.js.map +1 -1
  93. package/build/plugins/resource/aad/plugin.d.ts.map +1 -1
  94. package/build/plugins/resource/aad/plugin.js +1 -10
  95. package/build/plugins/resource/aad/plugin.js.map +1 -1
  96. package/build/plugins/resource/apim/managers/apimManager.d.ts.map +1 -1
  97. package/build/plugins/resource/apim/managers/apimManager.js +5 -7
  98. package/build/plugins/resource/apim/managers/apimManager.js.map +1 -1
  99. package/build/plugins/resource/appstudio/appStudio.d.ts +1 -1
  100. package/build/plugins/resource/appstudio/appStudio.d.ts.map +1 -1
  101. package/build/plugins/resource/appstudio/appStudio.js +106 -85
  102. package/build/plugins/resource/appstudio/appStudio.js.map +1 -1
  103. package/build/plugins/resource/appstudio/constants.d.ts +6 -1
  104. package/build/plugins/resource/appstudio/constants.d.ts.map +1 -1
  105. package/build/plugins/resource/appstudio/constants.js +6 -1
  106. package/build/plugins/resource/appstudio/constants.js.map +1 -1
  107. package/build/plugins/resource/appstudio/errors.d.ts +1 -1
  108. package/build/plugins/resource/appstudio/errors.d.ts.map +1 -1
  109. package/build/plugins/resource/appstudio/errors.js +2 -1
  110. package/build/plugins/resource/appstudio/errors.js.map +1 -1
  111. package/build/plugins/resource/appstudio/index.d.ts.map +1 -1
  112. package/build/plugins/resource/appstudio/index.js +10 -2
  113. package/build/plugins/resource/appstudio/index.js.map +1 -1
  114. package/build/plugins/resource/appstudio/plugin.d.ts +2 -3
  115. package/build/plugins/resource/appstudio/plugin.d.ts.map +1 -1
  116. package/build/plugins/resource/appstudio/plugin.js +93 -119
  117. package/build/plugins/resource/appstudio/plugin.js.map +1 -1
  118. package/build/plugins/resource/bot/index.d.ts.map +1 -1
  119. package/build/plugins/resource/bot/index.js +5 -1
  120. package/build/plugins/resource/bot/index.js.map +1 -1
  121. package/build/plugins/resource/bot/plugin.d.ts.map +1 -1
  122. package/build/plugins/resource/bot/plugin.js +9 -11
  123. package/build/plugins/resource/bot/plugin.js.map +1 -1
  124. package/build/plugins/resource/frontend/constants.d.ts +1 -7
  125. package/build/plugins/resource/frontend/constants.d.ts.map +1 -1
  126. package/build/plugins/resource/frontend/constants.js +2 -9
  127. package/build/plugins/resource/frontend/constants.js.map +1 -1
  128. package/build/plugins/resource/frontend/env.d.ts +21 -0
  129. package/build/plugins/resource/frontend/env.d.ts.map +1 -0
  130. package/build/plugins/resource/frontend/env.js +82 -0
  131. package/build/plugins/resource/frontend/env.js.map +1 -0
  132. package/build/plugins/resource/frontend/ops/deploy.d.ts +2 -1
  133. package/build/plugins/resource/frontend/ops/deploy.d.ts.map +1 -1
  134. package/build/plugins/resource/frontend/ops/deploy.js +2 -2
  135. package/build/plugins/resource/frontend/ops/deploy.js.map +1 -1
  136. package/build/plugins/resource/frontend/plugin.d.ts +2 -0
  137. package/build/plugins/resource/frontend/plugin.d.ts.map +1 -1
  138. package/build/plugins/resource/frontend/plugin.js +28 -16
  139. package/build/plugins/resource/frontend/plugin.js.map +1 -1
  140. package/build/plugins/resource/frontend/utils/environment-utils.d.ts.map +1 -1
  141. package/build/plugins/resource/frontend/utils/environment-utils.js +4 -2
  142. package/build/plugins/resource/frontend/utils/environment-utils.js.map +1 -1
  143. package/build/plugins/resource/frontend/utils.d.ts +6 -1
  144. package/build/plugins/resource/frontend/utils.d.ts.map +1 -1
  145. package/build/plugins/resource/frontend/utils.js +17 -6
  146. package/build/plugins/resource/frontend/utils.js.map +1 -1
  147. package/build/plugins/resource/function/plugin.d.ts.map +1 -1
  148. package/build/plugins/resource/function/plugin.js +7 -9
  149. package/build/plugins/resource/function/plugin.js.map +1 -1
  150. package/build/plugins/resource/function/utils/depsChecker/checker.d.ts +0 -1
  151. package/build/plugins/resource/function/utils/depsChecker/checker.d.ts.map +1 -1
  152. package/build/plugins/resource/function/utils/depsChecker/checker.js +2 -2
  153. package/build/plugins/resource/function/utils/depsChecker/checker.js.map +1 -1
  154. package/build/plugins/resource/function/utils/depsChecker/common.d.ts +2 -2
  155. package/build/plugins/resource/function/utils/depsChecker/common.d.ts.map +1 -1
  156. package/build/plugins/resource/function/utils/depsChecker/common.js +6 -6
  157. package/build/plugins/resource/function/utils/depsChecker/common.js.map +1 -1
  158. package/build/plugins/resource/function/utils/depsChecker/dotnetChecker.d.ts +3 -2
  159. package/build/plugins/resource/function/utils/depsChecker/dotnetChecker.d.ts.map +1 -1
  160. package/build/plugins/resource/function/utils/depsChecker/dotnetChecker.js +3 -2
  161. package/build/plugins/resource/function/utils/depsChecker/dotnetChecker.js.map +1 -1
  162. package/build/plugins/resource/function/utils/depsChecker/funcPluginAdapter.d.ts +0 -1
  163. package/build/plugins/resource/function/utils/depsChecker/funcPluginAdapter.d.ts.map +1 -1
  164. package/build/plugins/resource/function/utils/depsChecker/funcPluginAdapter.js +1 -23
  165. package/build/plugins/resource/function/utils/depsChecker/funcPluginAdapter.js.map +1 -1
  166. package/build/plugins/resource/identity/index.d.ts.map +1 -1
  167. package/build/plugins/resource/identity/index.js +11 -13
  168. package/build/plugins/resource/identity/index.js.map +1 -1
  169. package/build/plugins/resource/keyvault/plugin.d.ts.map +1 -1
  170. package/build/plugins/resource/keyvault/plugin.js +7 -9
  171. package/build/plugins/resource/keyvault/plugin.js.map +1 -1
  172. package/build/plugins/resource/localdebug/certificate.js +3 -3
  173. package/build/plugins/resource/localdebug/certificate.js.map +1 -1
  174. package/build/plugins/resource/localdebug/index.d.ts +0 -1
  175. package/build/plugins/resource/localdebug/index.d.ts.map +1 -1
  176. package/build/plugins/resource/localdebug/index.js +3 -280
  177. package/build/plugins/resource/localdebug/index.js.map +1 -1
  178. package/build/plugins/resource/localdebug/util/error.d.ts.map +1 -1
  179. package/build/plugins/resource/localdebug/util/error.js +1 -1
  180. package/build/plugins/resource/localdebug/util/error.js.map +1 -1
  181. package/build/plugins/resource/localdebug/v2/index.d.ts.map +1 -1
  182. package/build/plugins/resource/localdebug/v2/index.js +34 -1
  183. package/build/plugins/resource/localdebug/v2/index.js.map +1 -1
  184. package/build/plugins/resource/simpleauth/plugin.d.ts.map +1 -1
  185. package/build/plugins/resource/simpleauth/plugin.js +7 -9
  186. package/build/plugins/resource/simpleauth/plugin.js.map +1 -1
  187. package/build/plugins/resource/simpleauth/utils/common.d.ts.map +1 -1
  188. package/build/plugins/resource/simpleauth/utils/common.js +3 -1
  189. package/build/plugins/resource/simpleauth/utils/common.js.map +1 -1
  190. package/build/plugins/resource/sql/config.d.ts +0 -1
  191. package/build/plugins/resource/sql/config.d.ts.map +1 -1
  192. package/build/plugins/resource/sql/config.js +0 -1
  193. package/build/plugins/resource/sql/config.js.map +1 -1
  194. package/build/plugins/resource/sql/constants.d.ts +1 -0
  195. package/build/plugins/resource/sql/constants.d.ts.map +1 -1
  196. package/build/plugins/resource/sql/constants.js +1 -0
  197. package/build/plugins/resource/sql/constants.js.map +1 -1
  198. package/build/plugins/resource/sql/errors.d.ts +1 -0
  199. package/build/plugins/resource/sql/errors.d.ts.map +1 -1
  200. package/build/plugins/resource/sql/errors.js +1 -0
  201. package/build/plugins/resource/sql/errors.js.map +1 -1
  202. package/build/plugins/resource/sql/managementClient.d.ts +3 -1
  203. package/build/plugins/resource/sql/managementClient.d.ts.map +1 -1
  204. package/build/plugins/resource/sql/managementClient.js +11 -2
  205. package/build/plugins/resource/sql/managementClient.js.map +1 -1
  206. package/build/plugins/resource/sql/plugin.d.ts +3 -0
  207. package/build/plugins/resource/sql/plugin.d.ts.map +1 -1
  208. package/build/plugins/resource/sql/plugin.js +37 -27
  209. package/build/plugins/resource/sql/plugin.js.map +1 -1
  210. package/build/plugins/resource/sql/sqlClient.d.ts +1 -1
  211. package/build/plugins/resource/sql/sqlClient.d.ts.map +1 -1
  212. package/build/plugins/resource/sql/sqlClient.js +15 -24
  213. package/build/plugins/resource/sql/sqlClient.js.map +1 -1
  214. package/build/plugins/resource/sql/utils/checkInput.js +2 -2
  215. package/build/plugins/resource/sql/utils/checkInput.js.map +1 -1
  216. package/build/plugins/resource/sql/utils/message.d.ts +0 -1
  217. package/build/plugins/resource/sql/utils/message.d.ts.map +1 -1
  218. package/build/plugins/resource/sql/utils/message.js +0 -1
  219. package/build/plugins/resource/sql/utils/message.js.map +1 -1
  220. package/build/plugins/solution/fx-solution/arm.d.ts +18 -11
  221. package/build/plugins/solution/fx-solution/arm.d.ts.map +1 -1
  222. package/build/plugins/solution/fx-solution/arm.js +387 -120
  223. package/build/plugins/solution/fx-solution/arm.js.map +1 -1
  224. package/build/plugins/solution/fx-solution/commonQuestions.d.ts +13 -2
  225. package/build/plugins/solution/fx-solution/commonQuestions.d.ts.map +1 -1
  226. package/build/plugins/solution/fx-solution/commonQuestions.js +24 -26
  227. package/build/plugins/solution/fx-solution/commonQuestions.js.map +1 -1
  228. package/build/plugins/solution/fx-solution/debug/constants.d.ts +9 -0
  229. package/build/plugins/solution/fx-solution/debug/constants.d.ts.map +1 -0
  230. package/build/plugins/solution/fx-solution/debug/constants.js +16 -0
  231. package/build/plugins/solution/fx-solution/debug/constants.js.map +1 -0
  232. package/build/plugins/solution/fx-solution/debug/error.d.ts +7 -0
  233. package/build/plugins/solution/fx-solution/debug/error.d.ts.map +1 -0
  234. package/build/plugins/solution/fx-solution/debug/error.js +28 -0
  235. package/build/plugins/solution/fx-solution/debug/error.js.map +1 -0
  236. package/build/plugins/solution/fx-solution/debug/provisionLocal.d.ts +3 -0
  237. package/build/plugins/solution/fx-solution/debug/provisionLocal.d.ts.map +1 -0
  238. package/build/plugins/solution/fx-solution/debug/provisionLocal.js +107 -0
  239. package/build/plugins/solution/fx-solution/debug/provisionLocal.js.map +1 -0
  240. package/build/plugins/solution/fx-solution/debug/scaffolding.d.ts +3 -0
  241. package/build/plugins/solution/fx-solution/debug/scaffolding.d.ts.map +1 -0
  242. package/build/plugins/solution/fx-solution/debug/scaffolding.js +153 -0
  243. package/build/plugins/solution/fx-solution/debug/scaffolding.js.map +1 -0
  244. package/build/plugins/{resource/localdebug → solution/fx-solution/debug}/util/codespace.d.ts +0 -0
  245. package/build/plugins/solution/fx-solution/debug/util/codespace.d.ts.map +1 -0
  246. package/build/plugins/{resource/localdebug → solution/fx-solution/debug}/util/codespace.js +0 -0
  247. package/build/plugins/solution/fx-solution/debug/util/codespace.js.map +1 -0
  248. package/build/plugins/solution/fx-solution/debug/util/contextHelper.d.ts +10 -0
  249. package/build/plugins/solution/fx-solution/debug/util/contextHelper.d.ts.map +1 -0
  250. package/build/plugins/solution/fx-solution/debug/util/contextHelper.js +34 -0
  251. package/build/plugins/solution/fx-solution/debug/util/contextHelper.js.map +1 -0
  252. package/build/plugins/{resource/localdebug → solution/fx-solution/debug/util}/launch.d.ts +0 -0
  253. package/build/plugins/solution/fx-solution/debug/util/launch.d.ts.map +1 -0
  254. package/build/plugins/{resource/localdebug → solution/fx-solution/debug/util}/launch.js +1 -1
  255. package/build/plugins/solution/fx-solution/debug/util/launch.js.map +1 -0
  256. package/build/plugins/{resource/localdebug → solution/fx-solution/debug}/util/ngrok.d.ts +0 -0
  257. package/build/plugins/solution/fx-solution/debug/util/ngrok.d.ts.map +1 -0
  258. package/build/plugins/{resource/localdebug → solution/fx-solution/debug}/util/ngrok.js +2 -2
  259. package/build/plugins/solution/fx-solution/debug/util/ngrok.js.map +1 -0
  260. package/build/plugins/solution/fx-solution/debug/util/settings.d.ts +2 -0
  261. package/build/plugins/solution/fx-solution/debug/util/settings.d.ts.map +1 -0
  262. package/build/plugins/solution/fx-solution/debug/util/settings.js +22 -0
  263. package/build/plugins/solution/fx-solution/debug/util/settings.js.map +1 -0
  264. package/build/plugins/{resource/localdebug → solution/fx-solution/debug/util}/tasks.d.ts +0 -0
  265. package/build/plugins/solution/fx-solution/debug/util/tasks.d.ts.map +1 -0
  266. package/build/plugins/{resource/localdebug → solution/fx-solution/debug/util}/tasks.js +6 -6
  267. package/build/plugins/solution/fx-solution/debug/util/tasks.js.map +1 -0
  268. package/build/plugins/solution/fx-solution/debug/util/telemetry.d.ts +27 -0
  269. package/build/plugins/solution/fx-solution/debug/util/telemetry.d.ts.map +1 -0
  270. package/build/plugins/solution/fx-solution/debug/util/telemetry.js +81 -0
  271. package/build/plugins/solution/fx-solution/debug/util/telemetry.js.map +1 -0
  272. package/build/plugins/solution/fx-solution/index.d.ts +1 -0
  273. package/build/plugins/solution/fx-solution/index.d.ts.map +1 -1
  274. package/build/plugins/solution/fx-solution/index.js +1 -0
  275. package/build/plugins/solution/fx-solution/index.js.map +1 -1
  276. package/build/plugins/solution/fx-solution/question.d.ts +2 -2
  277. package/build/plugins/solution/fx-solution/question.d.ts.map +1 -1
  278. package/build/plugins/solution/fx-solution/question.js +2 -32
  279. package/build/plugins/solution/fx-solution/question.js.map +1 -1
  280. package/build/plugins/solution/fx-solution/solution.d.ts.map +1 -1
  281. package/build/plugins/solution/fx-solution/solution.js +9 -5
  282. package/build/plugins/solution/fx-solution/solution.js.map +1 -1
  283. package/build/plugins/solution/fx-solution/utils/depsChecker/bicepChecker.d.ts +2 -2
  284. package/build/plugins/solution/fx-solution/utils/depsChecker/bicepChecker.d.ts.map +1 -1
  285. package/build/plugins/solution/fx-solution/utils/depsChecker/bicepChecker.js +13 -14
  286. package/build/plugins/solution/fx-solution/utils/depsChecker/bicepChecker.js.map +1 -1
  287. package/build/plugins/solution/fx-solution/utils/progressHelper.d.ts +2 -2
  288. package/build/plugins/solution/fx-solution/utils/progressHelper.d.ts.map +1 -1
  289. package/build/plugins/solution/fx-solution/utils/progressHelper.js +4 -4
  290. package/build/plugins/solution/fx-solution/utils/progressHelper.js.map +1 -1
  291. package/build/plugins/solution/fx-solution/v2/constants.d.ts +2 -0
  292. package/build/plugins/solution/fx-solution/v2/constants.d.ts.map +1 -0
  293. package/build/plugins/solution/fx-solution/v2/constants.js +7 -0
  294. package/build/plugins/solution/fx-solution/v2/constants.js.map +1 -0
  295. package/build/plugins/solution/fx-solution/v2/createEnv.d.ts.map +1 -1
  296. package/build/plugins/solution/fx-solution/v2/createEnv.js +1 -1
  297. package/build/plugins/solution/fx-solution/v2/createEnv.js.map +1 -1
  298. package/build/plugins/solution/fx-solution/v2/executeUserTask.d.ts.map +1 -1
  299. package/build/plugins/solution/fx-solution/v2/executeUserTask.js +7 -4
  300. package/build/plugins/solution/fx-solution/v2/executeUserTask.js.map +1 -1
  301. package/build/plugins/solution/fx-solution/v2/getQuestions.d.ts.map +1 -1
  302. package/build/plugins/solution/fx-solution/v2/getQuestions.js +67 -25
  303. package/build/plugins/solution/fx-solution/v2/getQuestions.js.map +1 -1
  304. package/build/plugins/solution/fx-solution/v2/listAllCollaborators.js.map +1 -1
  305. package/build/plugins/solution/fx-solution/v2/provision.d.ts.map +1 -1
  306. package/build/plugins/solution/fx-solution/v2/provision.js +9 -1
  307. package/build/plugins/solution/fx-solution/v2/provision.js.map +1 -1
  308. package/build/plugins/solution/fx-solution/v2/provisionLocal.d.ts.map +1 -1
  309. package/build/plugins/solution/fx-solution/v2/provisionLocal.js +5 -0
  310. package/build/plugins/solution/fx-solution/v2/provisionLocal.js.map +1 -1
  311. package/build/plugins/solution/fx-solution/v2/scaffolding.d.ts.map +1 -1
  312. package/build/plugins/solution/fx-solution/v2/scaffolding.js +5 -0
  313. package/build/plugins/solution/fx-solution/v2/scaffolding.js.map +1 -1
  314. package/build/plugins/solution/fx-solution/v2/solution.d.ts.map +1 -1
  315. package/build/plugins/solution/fx-solution/v2/solution.js +2 -1
  316. package/build/plugins/solution/fx-solution/v2/solution.js.map +1 -1
  317. package/build/plugins/solution/fx-solution/v3/addModule.d.ts +6 -0
  318. package/build/plugins/solution/fx-solution/v3/addModule.d.ts.map +1 -0
  319. package/build/plugins/solution/fx-solution/v3/addModule.js +35 -0
  320. package/build/plugins/solution/fx-solution/v3/addModule.js.map +1 -0
  321. package/build/plugins/solution/fx-solution/v3/addResource.d.ts +37 -0
  322. package/build/plugins/solution/fx-solution/v3/addResource.d.ts.map +1 -0
  323. package/build/plugins/solution/fx-solution/v3/addResource.js +260 -0
  324. package/build/plugins/solution/fx-solution/v3/addResource.js.map +1 -0
  325. package/build/plugins/solution/fx-solution/v3/constants.d.ts +20 -0
  326. package/build/plugins/solution/fx-solution/v3/constants.d.ts.map +1 -0
  327. package/build/plugins/solution/fx-solution/v3/constants.js +25 -0
  328. package/build/plugins/solution/fx-solution/v3/constants.js.map +1 -0
  329. package/build/plugins/solution/fx-solution/v3/deploy.d.ts +6 -0
  330. package/build/plugins/solution/fx-solution/v3/deploy.d.ts.map +1 -0
  331. package/build/plugins/solution/fx-solution/v3/deploy.js +78 -0
  332. package/build/plugins/solution/fx-solution/v3/deploy.js.map +1 -0
  333. package/build/plugins/solution/fx-solution/v3/error.d.ts +11 -0
  334. package/build/plugins/solution/fx-solution/v3/error.d.ts.map +1 -0
  335. package/build/plugins/solution/fx-solution/v3/error.js +23 -0
  336. package/build/plugins/solution/fx-solution/v3/error.js.map +1 -0
  337. package/build/plugins/solution/fx-solution/v3/init.d.ts +4 -0
  338. package/build/plugins/solution/fx-solution/v3/init.d.ts.map +1 -0
  339. package/build/plugins/solution/fx-solution/v3/init.js +35 -0
  340. package/build/plugins/solution/fx-solution/v3/init.js.map +1 -0
  341. package/build/plugins/solution/fx-solution/v3/provision.d.ts +4 -0
  342. package/build/plugins/solution/fx-solution/v3/provision.d.ts.map +1 -0
  343. package/build/plugins/solution/fx-solution/v3/provision.js +124 -0
  344. package/build/plugins/solution/fx-solution/v3/provision.js.map +1 -0
  345. package/build/plugins/solution/fx-solution/v3/provisionLocal.d.ts +4 -0
  346. package/build/plugins/solution/fx-solution/v3/provisionLocal.d.ts.map +1 -0
  347. package/build/plugins/solution/fx-solution/v3/provisionLocal.js +13 -0
  348. package/build/plugins/solution/fx-solution/v3/provisionLocal.js.map +1 -0
  349. package/build/plugins/solution/fx-solution/v3/publish.d.ts +4 -0
  350. package/build/plugins/solution/fx-solution/v3/publish.d.ts.map +1 -0
  351. package/build/plugins/solution/fx-solution/v3/publish.js +15 -0
  352. package/build/plugins/solution/fx-solution/v3/publish.js.map +1 -0
  353. package/build/plugins/solution/fx-solution/v3/questions.d.ts +16 -0
  354. package/build/plugins/solution/fx-solution/v3/questions.d.ts.map +1 -0
  355. package/build/plugins/solution/fx-solution/v3/questions.js +86 -0
  356. package/build/plugins/solution/fx-solution/v3/questions.js.map +1 -0
  357. package/build/plugins/solution/fx-solution/v3/scaffold.d.ts +27 -0
  358. package/build/plugins/solution/fx-solution/v3/scaffold.d.ts.map +1 -0
  359. package/build/plugins/solution/fx-solution/v3/scaffold.js +241 -0
  360. package/build/plugins/solution/fx-solution/v3/scaffold.js.map +1 -0
  361. package/build/plugins/solution/fx-solution/v3/solution.d.ts +32 -0
  362. package/build/plugins/solution/fx-solution/v3/solution.d.ts.map +1 -0
  363. package/build/plugins/solution/fx-solution/v3/solution.js +45 -0
  364. package/build/plugins/solution/fx-solution/v3/solution.js.map +1 -0
  365. package/build/plugins/solution/fx-solution/v3/userTask.d.ts +4 -0
  366. package/build/plugins/solution/fx-solution/v3/userTask.d.ts.map +1 -0
  367. package/build/plugins/solution/fx-solution/v3/userTask.js +15 -0
  368. package/build/plugins/solution/fx-solution/v3/userTask.js.map +1 -0
  369. package/build/plugins/solution/fx-solution/v3/utils.d.ts +3 -0
  370. package/build/plugins/solution/fx-solution/v3/utils.d.ts.map +1 -0
  371. package/build/plugins/solution/fx-solution/v3/utils.js +16 -0
  372. package/build/plugins/solution/fx-solution/v3/utils.js.map +1 -0
  373. package/build/plugins/solution/index.d.ts +1 -0
  374. package/build/plugins/solution/index.d.ts.map +1 -1
  375. package/build/plugins/solution/index.js +1 -0
  376. package/build/plugins/solution/index.js.map +1 -1
  377. package/build/plugins/solution/spfx-solution/constants.d.ts +2 -0
  378. package/build/plugins/solution/spfx-solution/constants.d.ts.map +1 -0
  379. package/build/plugins/solution/spfx-solution/constants.js +7 -0
  380. package/build/plugins/solution/spfx-solution/constants.js.map +1 -0
  381. package/build/plugins/solution/spfx-solution/index.d.ts +2 -0
  382. package/build/plugins/solution/spfx-solution/index.d.ts.map +1 -0
  383. package/build/plugins/solution/spfx-solution/index.js +5 -0
  384. package/build/plugins/solution/spfx-solution/index.js.map +1 -0
  385. package/build/plugins/solution/spfx-solution/init.d.ts +3 -0
  386. package/build/plugins/solution/spfx-solution/init.d.ts.map +1 -0
  387. package/build/plugins/solution/spfx-solution/init.js +20 -0
  388. package/build/plugins/solution/spfx-solution/init.js.map +1 -0
  389. package/build/plugins/solution/spfx-solution/questions.d.ts +6 -0
  390. package/build/plugins/solution/spfx-solution/questions.d.ts.map +1 -0
  391. package/build/plugins/solution/spfx-solution/questions.js +36 -0
  392. package/build/plugins/solution/spfx-solution/questions.js.map +1 -0
  393. package/build/plugins/solution/spfx-solution/scaffolding.d.ts +17 -0
  394. package/build/plugins/solution/spfx-solution/scaffolding.d.ts.map +1 -0
  395. package/build/plugins/solution/spfx-solution/scaffolding.js +29 -0
  396. package/build/plugins/solution/spfx-solution/scaffolding.js.map +1 -0
  397. package/build/plugins/solution/spfx-solution/solution.d.ts +23 -0
  398. package/build/plugins/solution/spfx-solution/solution.d.ts.map +1 -0
  399. package/build/plugins/solution/spfx-solution/solution.js +29 -0
  400. package/build/plugins/solution/spfx-solution/solution.js.map +1 -0
  401. package/package.json +9 -4
  402. package/resource/strings.json +0 -1
  403. package/templates/plugins/resource/apim/bicep/apimConfiguration.bicep +16 -16
  404. package/templates/plugins/resource/apim/bicep/config.template.bicep +1 -1
  405. package/templates/plugins/resource/apim/bicep/provision.template.bicep +1 -1
  406. package/templates/plugins/resource/bot/bicep/botConfiguration.template.bicep +28 -29
  407. package/templates/plugins/resource/bot/bicep/config.template.bicep +1 -1
  408. package/templates/plugins/resource/bot/bicep/provision.template.bicep +2 -2
  409. package/templates/plugins/resource/frontend/bicep/provision.template.bicep +1 -1
  410. package/templates/plugins/resource/function/bicep/config.template.bicep +1 -1
  411. package/templates/plugins/resource/function/bicep/functionConfiguration.template.bicep +33 -31
  412. package/templates/plugins/resource/function/bicep/provision.template.bicep +2 -2
  413. package/templates/plugins/resource/identity/bicep/provision.template.bicep +1 -1
  414. package/templates/plugins/resource/keyvault/bicep/provision.template.bicep +3 -2
  415. package/templates/plugins/resource/simpleauth/bicep/config.template.bicep +1 -1
  416. package/templates/plugins/resource/simpleauth/bicep/provision.template.bicep +2 -2
  417. package/templates/plugins/resource/simpleauth/bicep/simpleAuthConfiguration.template.bicep +20 -24
  418. package/templates/plugins/resource/simpleauth/version.txt +2 -1
  419. package/templates/plugins/resource/sql/bicep/provision.template.bicep +1 -1
  420. package/build/plugins/resource/localdebug/launch.d.ts.map +0 -1
  421. package/build/plugins/resource/localdebug/launch.js.map +0 -1
  422. package/build/plugins/resource/localdebug/legacyPlugin.d.ts +0 -6
  423. package/build/plugins/resource/localdebug/legacyPlugin.d.ts.map +0 -1
  424. package/build/plugins/resource/localdebug/legacyPlugin.js +0 -208
  425. package/build/plugins/resource/localdebug/legacyPlugin.js.map +0 -1
  426. package/build/plugins/resource/localdebug/settings.d.ts +0 -2
  427. package/build/plugins/resource/localdebug/settings.d.ts.map +0 -1
  428. package/build/plugins/resource/localdebug/settings.js +0 -18
  429. package/build/plugins/resource/localdebug/settings.js.map +0 -1
  430. package/build/plugins/resource/localdebug/tasks.d.ts.map +0 -1
  431. package/build/plugins/resource/localdebug/tasks.js.map +0 -1
  432. package/build/plugins/resource/localdebug/util/codespace.d.ts.map +0 -1
  433. package/build/plugins/resource/localdebug/util/codespace.js.map +0 -1
  434. package/build/plugins/resource/localdebug/util/ngrok.d.ts.map +0 -1
  435. package/build/plugins/resource/localdebug/util/ngrok.js.map +0 -1
  436. package/templates/azure/config.bicep +0 -25
  437. package/templates/azure/main.bicep +0 -20
  438. package/templates/azure/provision/azureSql.bicep +0 -39
  439. package/templates/azure/provision/frontendHosting.bicep +0 -23
  440. package/templates/azure/provision/function.bicep +0 -79
  441. package/templates/azure/provision/simpleAuth.bicep +0 -44
  442. package/templates/azure/provision.bicep +0 -58
  443. package/templates/azure/teamsFx/bot.bicep +0 -34
  444. package/templates/azure/teamsFx/function.bicep +0 -71
  445. package/templates/azure/teamsFx/simpleAuth.bicep +0 -40
  446. package/templates/plugins/resource/aad/bicep/param.template.bicep +0 -6
  447. package/templates/plugins/resource/aad/bicep/variables.template.bicep +0 -13
@@ -13,10 +13,9 @@ export declare class AppStudioPluginImpl {
13
13
  * @returns
14
14
  */
15
15
  createV1Manifest(ctx: PluginContext): Promise<TeamsAppManifest>;
16
- reloadManifestAndCheckRequiredFields(manifestPath: string): Promise<Result<TeamsAppManifest, FxError>>;
17
16
  provision(ctx: PluginContext): Promise<Result<string, FxError>>;
18
17
  postProvision(ctx: PluginContext): Promise<Result<string, FxError>>;
19
- validateManifest(ctx: PluginContext): Promise<Result<string[], FxError>>;
18
+ validateManifest(ctx: PluginContext, isLocalDebug: boolean): Promise<Result<string[], FxError>>;
20
19
  updateManifest(ctx: PluginContext, isLocalDebug: boolean): Promise<Result<string, FxError>>;
21
20
  migrateV1Project(ctx: PluginContext): Promise<{
22
21
  enableAuth: boolean;
@@ -33,7 +32,6 @@ export declare class AppStudioPluginImpl {
33
32
  listCollaborator(ctx: PluginContext): Promise<TeamsAppAdmin[]>;
34
33
  grantPermission(ctx: PluginContext, userInfo: IUserList): Promise<ResourcePermission[]>;
35
34
  private beforePublish;
36
- private checkFileExist;
37
35
  private replaceExistingValueToPlaceholder;
38
36
  private convertToAppDefinitionMessagingExtensions;
39
37
  private convertToAppDefinitionBots;
@@ -54,6 +52,7 @@ export declare class AppStudioPluginImpl {
54
52
  private createApp;
55
53
  private updateApp;
56
54
  private getAppDefinitionAndManifest;
55
+ private getSPFxManifest;
57
56
  getManifestTemplatePath(projectRoot: string, isLocalDebug?: boolean): Promise<string>;
58
57
  }
59
58
  export declare function createLocalManifest(appName: string, hasFrontend: boolean, hasBot: boolean, hasMessageExtension: boolean, isSPFx: boolean, migrateFromV1: boolean): Promise<TeamsAppManifest>;
@@ -1 +1 @@
1
- {"version":3,"file":"plugin.d.ts","sourceRoot":"","sources":["../../../../src/plugins/resource/appstudio/plugin.ts"],"names":[],"mappings":"AAGA,OAAO,EAKL,OAAO,EACP,MAAM,EACN,aAAa,EACb,gBAAgB,EASjB,MAAM,wBAAwB,CAAC;AAEhC,OAAO,EAOL,SAAS,EAEV,MAAM,6BAA6B,CAAC;AAuErC,OAAO,EAAE,kBAAkB,EAAE,aAAa,EAAE,MAAM,qCAAqC,CAAC;AAYxF,qBAAa,mBAAmB;IACvB,gBAAgB,EAAE;QAAE,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,CAAA;KAAE,CAAM;IAE3C,yBAAyB,CACpC,GAAG,EAAE,aAAa,EAClB,YAAY,EAAE,OAAO,EACrB,QAAQ,EAAE,gBAAgB,GACzB,OAAO,CAAC,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;YA2DrB,uCAAuC;IAuErD;;;;OAIG;IACU,gBAAgB,CAAC,GAAG,EAAE,aAAa,GAAG,OAAO,CAAC,gBAAgB,CAAC;IA6C/D,oCAAoC,CAC/C,YAAY,EAAE,MAAM,GACn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AM,EAAE,OAAO,EACf,aAAa,EAAE,OAAO,GACrB,OAAO,CAAC,gBAAgB,GAAG,SAAS,CAAC,CAkCvC"}
@@ -129,7 +129,7 @@ class AppStudioPluginImpl {
129
129
  async createV1Manifest(ctx) {
130
130
  var _a, _b;
131
131
  const archiveManifestPath = path_1.default.join(ctx.root, teamsfx_api_1.ArchiveFolderName, teamsfx_api_1.AppPackageFolderName, teamsfx_api_1.V1ManifestFileName);
132
- const manifestSourceRes = await this.reloadManifestAndCheckRequiredFields(archiveManifestPath);
132
+ const manifestSourceRes = await this.reloadManifest(archiveManifestPath);
133
133
  if (manifestSourceRes.isErr()) {
134
134
  throw manifestSourceRes.error;
135
135
  }
@@ -158,17 +158,6 @@ class AppStudioPluginImpl {
158
158
  }
159
159
  return manifest;
160
160
  }
161
- async reloadManifestAndCheckRequiredFields(manifestPath) {
162
- const result = await this.reloadManifest(manifestPath);
163
- return result.andThen((manifest) => {
164
- if (manifest === undefined ||
165
- manifest.name.short === undefined ||
166
- manifest.name.short.length === 0) {
167
- return teamsfx_api_1.err(results_1.AppStudioResultFactory.SystemError(errors_1.AppStudioError.ManifestLoadFailedError.name, errors_1.AppStudioError.ManifestLoadFailedError.message("Name is missing")));
168
- }
169
- return teamsfx_api_1.ok(manifest);
170
- });
171
- }
172
161
  async provision(ctx) {
173
162
  var _a, _b, _c;
174
163
  let remoteTeamsAppId = await this.getTeamsAppId(ctx, false);
@@ -193,9 +182,7 @@ class AppStudioPluginImpl {
193
182
  remoteTeamsAppId = result.value.teamsAppId;
194
183
  (_b = ctx.logProvider) === null || _b === void 0 ? void 0 : _b.info(`Teams app created ${remoteTeamsAppId}`);
195
184
  }
196
- if (common_1.isMultiEnvEnabled() || __1.isV2()) {
197
- (_c = ctx.envInfo.state.get(constants_1.PluginNames.APPST)) === null || _c === void 0 ? void 0 : _c.set(constants_2.Constants.TEAMS_APP_ID, remoteTeamsAppId);
198
- }
185
+ (_c = ctx.envInfo.state.get(constants_1.PluginNames.APPST)) === null || _c === void 0 ? void 0 : _c.set(constants_2.Constants.TEAMS_APP_ID, remoteTeamsAppId);
199
186
  return teamsfx_api_1.ok(remoteTeamsAppId);
200
187
  }
201
188
  async postProvision(ctx) {
@@ -204,7 +191,7 @@ class AppStudioPluginImpl {
204
191
  let manifestString;
205
192
  const appDirectory = await common_1.getAppDirectory(ctx.root);
206
193
  const manifestPath = await this.getManifestTemplatePath(ctx.root);
207
- const manifestResult = await this.reloadManifestAndCheckRequiredFields(manifestPath);
194
+ const manifestResult = await this.reloadManifest(manifestPath);
208
195
  if (manifestResult.isErr()) {
209
196
  return teamsfx_api_1.err(manifestResult.error);
210
197
  }
@@ -213,17 +200,7 @@ class AppStudioPluginImpl {
213
200
  }
214
201
  let appDefinition;
215
202
  if (common_1.isSPFxProject(ctx.projectSettings)) {
216
- if (common_1.isMultiEnvEnabled()) {
217
- const view = {
218
- config: ctx.envInfo.config,
219
- state: {
220
- "fx-resource-appstudio": {
221
- teamsAppId: remoteTeamsAppId,
222
- },
223
- },
224
- };
225
- manifestString = mustache_1.default.render(manifestString, view);
226
- }
203
+ manifestString = await this.getSPFxManifest(ctx, false);
227
204
  const appDefinitionRes = await this.convertToAppDefinition(ctx, JSON.parse(manifestString), false);
228
205
  if (appDefinitionRes.isErr()) {
229
206
  return teamsfx_api_1.err(appDefinitionRes.error);
@@ -245,22 +222,13 @@ class AppStudioPluginImpl {
245
222
  (_b = ctx.logProvider) === null || _b === void 0 ? void 0 : _b.info(`Teams app updated: ${result.value}`);
246
223
  return teamsfx_api_1.ok(remoteTeamsAppId);
247
224
  }
248
- async validateManifest(ctx) {
249
- var _a, _b, _c;
225
+ async validateManifest(ctx, isLocalDebug) {
226
+ var _a, _b;
250
227
  const appStudioToken = await ((_a = ctx === null || ctx === void 0 ? void 0 : ctx.appStudioToken) === null || _a === void 0 ? void 0 : _a.getAccessToken());
251
228
  let manifestString = undefined;
252
229
  if (common_1.isSPFxProject(ctx.projectSettings)) {
253
- manifestString = (await fs.readFile(await this.getManifestTemplatePath(ctx.root))).toString();
230
+ manifestString = await this.getSPFxManifest(ctx, isLocalDebug);
254
231
  if (common_1.isMultiEnvEnabled()) {
255
- const view = {
256
- config: ctx.envInfo.config,
257
- state: {
258
- "fx-resource-appstudio": {
259
- teamsAppId: this.getTeamsAppId(ctx, false),
260
- },
261
- },
262
- };
263
- manifestString = mustache_1.default.render(manifestString, view);
264
232
  const manifest = JSON.parse(manifestString);
265
233
  if (!isUUID_1.default(manifest.id)) {
266
234
  manifest.id = uuid_1.v4();
@@ -269,18 +237,10 @@ class AppStudioPluginImpl {
269
237
  }
270
238
  }
271
239
  else {
272
- const appDefinitionAndManifest = await this.getAppDefinitionAndManifest(ctx, false);
240
+ const appDefinitionAndManifest = await this.getAppDefinitionAndManifest(ctx, isLocalDebug);
273
241
  if (appDefinitionAndManifest.isErr()) {
274
242
  (_b = ctx.logProvider) === null || _b === void 0 ? void 0 : _b.error("[Teams Toolkit] Manifest Validation failed!");
275
- const isProvisionSucceeded = !!((_c = ctx.envInfo.state
276
- .get("solution")) === null || _c === void 0 ? void 0 : _c.get(constants_1.SOLUTION_PROVISION_SUCCEEDED));
277
- if (appDefinitionAndManifest.error.name === errors_1.AppStudioError.GetRemoteConfigError.name &&
278
- !isProvisionSucceeded) {
279
- return teamsfx_api_1.err(results_1.AppStudioResultFactory.UserError(errors_1.AppStudioError.GetRemoteConfigError.name, errors_1.AppStudioError.GetRemoteConfigError.message("Manifest validation failed"), constants_3.HelpLinks.WhyNeedProvision));
280
- }
281
- else {
282
- return teamsfx_api_1.err(appDefinitionAndManifest.error);
283
- }
243
+ return teamsfx_api_1.err(appDefinitionAndManifest.error);
284
244
  }
285
245
  else {
286
246
  manifestString = JSON.stringify(appDefinitionAndManifest.value[1]);
@@ -316,13 +276,13 @@ class AppStudioPluginImpl {
316
276
  return teamsfx_api_1.ok(errors);
317
277
  }
318
278
  async updateManifest(ctx, isLocalDebug) {
319
- var _a, _b, _c, _d, _e, _f;
279
+ var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
320
280
  const teamsAppId = await this.getTeamsAppId(ctx, isLocalDebug);
321
281
  let manifest;
322
282
  let manifestString;
323
283
  const appDirectory = await common_1.getAppDirectory(ctx.root);
324
284
  const manifestPath = await this.getManifestTemplatePath(ctx.root, isLocalDebug);
325
- const manifestResult = await this.reloadManifestAndCheckRequiredFields(manifestPath);
285
+ const manifestResult = await this.reloadManifest(manifestPath);
326
286
  if (manifestResult.isErr()) {
327
287
  throw manifestResult;
328
288
  }
@@ -331,27 +291,7 @@ class AppStudioPluginImpl {
331
291
  }
332
292
  let appDefinition;
333
293
  if (common_1.isSPFxProject(ctx.projectSettings)) {
334
- let view;
335
- if (isLocalDebug) {
336
- view = {
337
- localSettings: {
338
- teamsApp: {
339
- teamsAppId: teamsAppId,
340
- },
341
- },
342
- };
343
- }
344
- else {
345
- view = {
346
- config: ctx.envInfo.config,
347
- state: {
348
- "fx-resource-appstudio": {
349
- teamsAppId: teamsAppId,
350
- },
351
- },
352
- };
353
- }
354
- manifestString = mustache_1.default.render(manifestString, view);
294
+ manifestString = await this.getSPFxManifest(ctx, isLocalDebug);
355
295
  manifest = JSON.parse(manifestString);
356
296
  const appDefinitionRes = await this.convertToAppDefinition(ctx, manifest, false);
357
297
  if (appDefinitionRes.isErr()) {
@@ -398,12 +338,26 @@ class AppStudioPluginImpl {
398
338
  }
399
339
  const appStudioToken = await ((_d = ctx === null || ctx === void 0 ? void 0 : ctx.appStudioToken) === null || _d === void 0 ? void 0 : _d.getAccessToken());
400
340
  try {
341
+ const localUpdateTime = isLocalDebug
342
+ ? undefined
343
+ : (_e = ctx.envInfo.state.get(constants_1.PluginNames.APPST)) === null || _e === void 0 ? void 0 : _e.get(constants_2.Constants.TEAMS_APP_UPDATED_AT);
344
+ if (localUpdateTime) {
345
+ const app = await appStudio_1.AppStudioClient.getApp(teamsAppId, appStudioToken, ctx.logProvider);
346
+ const devPortalUpdateTime = (_g = (_f = new Date(app.updatedAt)) === null || _f === void 0 ? void 0 : _f.getTime()) !== null && _g !== void 0 ? _g : -1;
347
+ if (localUpdateTime < devPortalUpdateTime) {
348
+ const res = await ((_h = ctx.ui) === null || _h === void 0 ? void 0 : _h.showMessage("warn", "The manifest file on Teams platform has been changed since your last update. Do you want to continue to update and overwrite the manifest file on Teams platform?", true, "Overwrite and update"));
349
+ if (!((res === null || res === void 0 ? void 0 : res.isOk()) && res.value === "Overwrite and update")) {
350
+ const error = results_1.AppStudioResultFactory.UserError(errors_1.AppStudioError.UpdateManifestCancelError.name, errors_1.AppStudioError.UpdateManifestCancelError.message(manifest.name.short));
351
+ return teamsfx_api_1.err(error);
352
+ }
353
+ }
354
+ }
401
355
  const result = await this.updateApp(ctx, appDefinition, appStudioToken, isLocalDebug, false, appDirectory, teamsAppId, ctx.logProvider);
402
356
  if (result.isErr()) {
403
357
  throw result.error;
404
358
  }
405
- (_e = ctx.logProvider) === null || _e === void 0 ? void 0 : _e.info(`Teams app updated: ${result.value}`);
406
- (_f = ctx.ui) === null || _f === void 0 ? void 0 : _f.showMessage("info", `Successfully updated manifest for [${manifest.name.short}]`, false);
359
+ (_j = ctx.logProvider) === null || _j === void 0 ? void 0 : _j.info(`Teams app updated: ${result.value}`);
360
+ (_k = ctx.ui) === null || _k === void 0 ? void 0 : _k.showMessage("info", `Successfully updated manifest for [${manifest.name.short}]`, false);
407
361
  return teamsfx_api_1.ok(teamsAppId);
408
362
  }
409
363
  catch (error) {
@@ -425,7 +379,7 @@ class AppStudioPluginImpl {
425
379
  ? `${ctx.root}/${constants_2.APP_PACKAGE_FOLDER_FOR_MULTI_ENV}`
426
380
  : `${ctx.root}/${teamsfx_api_1.AppPackageFolderName}`;
427
381
  await fs.ensureDir(newAppPackageFolder);
428
- if (await this.checkFileExist(archiveManifestPath)) {
382
+ if (await fs.pathExists(archiveManifestPath)) {
429
383
  manifest = await this.createV1Manifest(ctx);
430
384
  const resourcesDir = common_1.isMultiEnvEnabled()
431
385
  ? path_1.default.join(newAppPackageFolder, constants_2.MANIFEST_RESOURCES)
@@ -433,7 +387,7 @@ class AppStudioPluginImpl {
433
387
  await fs.ensureDir(resourcesDir);
434
388
  if (((_a = manifest === null || manifest === void 0 ? void 0 : manifest.icons) === null || _a === void 0 ? void 0 : _a.color) && !manifest.icons.color.startsWith("https://")) {
435
389
  const archiveColorFile = path_1.default.join(archiveAppPackageFolder, manifest.icons.color);
436
- const existColorFile = await this.checkFileExist(archiveColorFile);
390
+ const existColorFile = await fs.pathExists(archiveColorFile);
437
391
  const newColorFileName = existColorFile
438
392
  ? path_1.default.basename(manifest.icons.color)
439
393
  : constants_2.DEFAULT_COLOR_PNG_FILENAME;
@@ -444,7 +398,7 @@ class AppStudioPluginImpl {
444
398
  }
445
399
  if (((_b = manifest === null || manifest === void 0 ? void 0 : manifest.icons) === null || _b === void 0 ? void 0 : _b.outline) && !manifest.icons.outline.startsWith("https://")) {
446
400
  const archiveOutlineFile = path_1.default.join(archiveAppPackageFolder, manifest.icons.outline);
447
- const existOutlineFile = await this.checkFileExist(archiveOutlineFile);
401
+ const existOutlineFile = await fs.pathExists(archiveOutlineFile);
448
402
  const newOutlineFileName = existOutlineFile
449
403
  ? path_1.default.basename(manifest.icons.outline)
450
404
  : constants_2.DEFAULT_OUTLINE_PNG_FILENAME;
@@ -507,6 +461,13 @@ class AppStudioPluginImpl {
507
461
  }
508
462
  async buildTeamsAppPackage(ctx, isLocalDebug) {
509
463
  var _a, _b, _c;
464
+ // Validate manifest
465
+ const validationResult = await this.validateManifest(ctx, isLocalDebug);
466
+ if (validationResult.isOk() && validationResult.value.length > 0) {
467
+ const errMessage = errors_1.AppStudioError.ValidationFailedError.message(validationResult.value);
468
+ const validationFailed = results_1.AppStudioResultFactory.UserError(errors_1.AppStudioError.ValidationFailedError.name, errMessage);
469
+ throw validationFailed;
470
+ }
510
471
  let manifestString = undefined;
511
472
  if (!((_a = ctx.envInfo) === null || _a === void 0 ? void 0 : _a.envName)) {
512
473
  throw new Error("Failed to get target environment name from plugin context.");
@@ -525,17 +486,8 @@ class AppStudioPluginImpl {
525
486
  zipFileName = `${ctx.root}/${teamsfx_api_1.AppPackageFolderName}/appPackage.zip`;
526
487
  }
527
488
  if (common_1.isSPFxProject(ctx.projectSettings)) {
528
- manifestString = (await fs.readFile(await this.getManifestTemplatePath(ctx.root, isLocalDebug))).toString();
489
+ manifestString = await this.getSPFxManifest(ctx, isLocalDebug);
529
490
  if (common_1.isMultiEnvEnabled()) {
530
- const view = {
531
- config: ctx.envInfo.config,
532
- state: {
533
- "fx-resource-appstudio": {
534
- teamsAppId: await this.getTeamsAppId(ctx, isLocalDebug),
535
- },
536
- },
537
- };
538
- manifestString = mustache_1.default.render(manifestString, view);
539
491
  const manifest = JSON.parse(manifestString);
540
492
  if (!isUUID_1.default(manifest.id)) {
541
493
  manifest.id = uuid_1.v4();
@@ -571,7 +523,7 @@ class AppStudioPluginImpl {
571
523
  // color icon
572
524
  if (manifest.icons.color && !manifest.icons.color.startsWith("https://")) {
573
525
  const colorFile = `${appDirectory}/${manifest.icons.color}`;
574
- const fileExists = await this.checkFileExist(colorFile);
526
+ const fileExists = await fs.pathExists(colorFile);
575
527
  if (!fileExists) {
576
528
  throw results_1.AppStudioResultFactory.UserError(errors_1.AppStudioError.FileNotFoundError.name, errors_1.AppStudioError.FileNotFoundError.message(colorFile));
577
529
  }
@@ -581,7 +533,7 @@ class AppStudioPluginImpl {
581
533
  // outline icon
582
534
  if (manifest.icons.outline && !manifest.icons.outline.startsWith("https://")) {
583
535
  const outlineFile = `${appDirectory}/${manifest.icons.outline}`;
584
- const fileExists = await this.checkFileExist(outlineFile);
536
+ const fileExists = await fs.pathExists(outlineFile);
585
537
  if (!fileExists) {
586
538
  throw results_1.AppStudioResultFactory.UserError(errors_1.AppStudioError.FileNotFoundError.name, errors_1.AppStudioError.FileNotFoundError.message(outlineFile));
587
539
  }
@@ -593,7 +545,11 @@ class AppStudioPluginImpl {
593
545
  const manifestFileName = `${ctx.root}/${teamsfx_api_1.BuildFolderName}/${teamsfx_api_1.AppPackageFolderName}/manifest.` +
594
546
  (isLocalDebug ? "local" : ctx.envInfo.envName) +
595
547
  `.json`;
548
+ if (await fs.pathExists(manifestFileName)) {
549
+ await fs.chmod(manifestFileName, 0o777);
550
+ }
596
551
  await fs.writeFile(manifestFileName, manifestString);
552
+ await fs.chmod(manifestFileName, 0o444);
597
553
  }
598
554
  // localization file
599
555
  if (manifest.localizationInfo &&
@@ -616,7 +572,7 @@ class AppStudioPluginImpl {
616
572
  if (appDirectory === `${ctx.root}/.${teamsfx_api_1.ConfigFolderName}`) {
617
573
  await fs.ensureDir(path_1.default.join(ctx.root, `${teamsfx_api_1.AppPackageFolderName}`));
618
574
  const formerZipFileName = `${appDirectory}/appPackage.zip`;
619
- if (await this.checkFileExist(formerZipFileName)) {
575
+ if (await fs.pathExists(formerZipFileName)) {
620
576
  await fs.remove(formerZipFileName);
621
577
  }
622
578
  await fs.move(`${appDirectory}/${manifest.icons.color}`, common_1.isMultiEnvEnabled()
@@ -637,17 +593,7 @@ class AppStudioPluginImpl {
637
593
  const appDirectory = await common_1.getAppDirectory(ctx.root);
638
594
  let manifestString = JSON.stringify(await fs.readJSON(await this.getManifestTemplatePath(ctx.root)));
639
595
  if (common_1.isSPFxProject(ctx.projectSettings)) {
640
- if (common_1.isMultiEnvEnabled()) {
641
- const view = {
642
- config: ctx.envInfo.config,
643
- state: {
644
- "fx-resource-appstudio": {
645
- teamsAppId: await this.getTeamsAppId(ctx, false),
646
- },
647
- },
648
- };
649
- manifestString = mustache_1.default.render(manifestString, view);
650
- }
596
+ manifestString = await this.getSPFxManifest(ctx, false);
651
597
  manifest = JSON.parse(manifestString);
652
598
  }
653
599
  else {
@@ -693,7 +639,7 @@ class AppStudioPluginImpl {
693
639
  var _a, _b, _c, _d;
694
640
  let teamsAppId;
695
641
  const manifestPath = await this.getManifestTemplatePath(ctx.root, true);
696
- const manifest = await this.reloadManifestAndCheckRequiredFields(manifestPath);
642
+ const manifest = await this.reloadManifest(manifestPath);
697
643
  if (manifest.isErr()) {
698
644
  return teamsfx_api_1.err(manifest.error);
699
645
  }
@@ -805,7 +751,7 @@ class AppStudioPluginImpl {
805
751
  return result;
806
752
  }
807
753
  async beforePublish(ctx, appDirectory, manifestString, update) {
808
- var _a, _b, _c, _d;
754
+ var _a, _b, _c, _d, _e;
809
755
  const manifest = JSON.parse(manifestString);
810
756
  const publishProgress = (_a = ctx.ui) === null || _a === void 0 ? void 0 : _a.createProgressBar(`Publishing ${manifest.name.short}`, 3);
811
757
  try {
@@ -830,7 +776,11 @@ class AppStudioPluginImpl {
830
776
  ? (await fs.readFile(`${appDirectory}/${manifest.icons.outline}`)).toString("base64")
831
777
  : undefined;
832
778
  try {
833
- await appStudio_1.AppStudioClient.updateApp(remoteTeamsAppId, appDefinitionRes.value, appStudioToken, undefined, colorIconContent, outlineIconContent);
779
+ const app = await appStudio_1.AppStudioClient.updateApp(remoteTeamsAppId, appDefinitionRes.value, appStudioToken, undefined, colorIconContent, outlineIconContent);
780
+ if (app.updatedAt) {
781
+ (_d = ctx.envInfo.state
782
+ .get(constants_1.PluginNames.APPST)) === null || _d === void 0 ? void 0 : _d.set(constants_2.Constants.TEAMS_APP_UPDATED_AT, new Date(app.updatedAt).getTime());
783
+ }
834
784
  }
835
785
  catch (e) {
836
786
  if (e.name === 404) {
@@ -842,7 +792,7 @@ class AppStudioPluginImpl {
842
792
  await (publishProgress === null || publishProgress === void 0 ? void 0 : publishProgress.next(`Building Teams app package in ${appDirectory}.`));
843
793
  const appPackage = await this.buildTeamsAppPackage(ctx, false);
844
794
  const appContent = await fs.readFile(appPackage);
845
- appStudioToken = await ((_d = ctx.appStudioToken) === null || _d === void 0 ? void 0 : _d.getAccessToken());
795
+ appStudioToken = await ((_e = ctx.appStudioToken) === null || _e === void 0 ? void 0 : _e.getAccessToken());
846
796
  await (publishProgress === null || publishProgress === void 0 ? void 0 : publishProgress.next(`Publishing ${manifest.name.short}`));
847
797
  if (update) {
848
798
  // Update existing app in App Catalog
@@ -857,15 +807,6 @@ class AppStudioPluginImpl {
857
807
  await (publishProgress === null || publishProgress === void 0 ? void 0 : publishProgress.end(true));
858
808
  }
859
809
  }
860
- async checkFileExist(filePath) {
861
- try {
862
- await fs.stat(filePath);
863
- return true;
864
- }
865
- catch (error) {
866
- return false;
867
- }
868
- }
869
810
  replaceExistingValueToPlaceholder(config, value, placeholderName) {
870
811
  if (config && value && placeholderName) {
871
812
  config = config.split(value).join(placeholderName);
@@ -1050,12 +991,15 @@ class AppStudioPluginImpl {
1050
991
  }
1051
992
  async getTeamsAppId(ctx, isLocalDebug) {
1052
993
  var _a, _b, _c, _d, _e;
1053
- let teamsAppId;
994
+ let teamsAppId = "";
1054
995
  if (common_1.isMultiEnvEnabled() || !isLocalDebug) {
1055
996
  // User may manually update id in manifest template file, rather than configuration file
1056
997
  // The id in manifest template file should override configurations
1057
- const manifest = await fs.readJSON(await this.getManifestTemplatePath(ctx.root, isLocalDebug));
1058
- teamsAppId = manifest.id;
998
+ const manifestFile = await this.getManifestTemplatePath(ctx.root, isLocalDebug);
999
+ if (await fs.pathExists(manifestFile)) {
1000
+ const manifest = await fs.readJSON(manifestFile);
1001
+ teamsAppId = manifest.id;
1002
+ }
1059
1003
  if (!isUUID_1.default(teamsAppId)) {
1060
1004
  if (common_1.isMultiEnvEnabled()) {
1061
1005
  teamsAppId = isLocalDebug
@@ -1181,6 +1125,7 @@ class AppStudioPluginImpl {
1181
1125
  }
1182
1126
  }
1183
1127
  async updateApp(ctx, appDefinition, appStudioToken, isLocalDebug, createIfNotExist, appDirectory, teamsAppId, logProvider) {
1128
+ var _a;
1184
1129
  if (appStudioToken === undefined || appStudioToken.length === 0) {
1185
1130
  return teamsfx_api_1.err(results_1.AppStudioResultFactory.SystemError(errors_1.AppStudioError.AppStudioTokenGetFailedError.name, errors_1.AppStudioError.AppStudioTokenGetFailedError.message));
1186
1131
  }
@@ -1206,7 +1151,11 @@ class AppStudioPluginImpl {
1206
1151
  : undefined;
1207
1152
  appDefinition.appId = teamsAppId;
1208
1153
  try {
1209
- await appStudio_1.AppStudioClient.updateApp(teamsAppId, appDefinition, appStudioToken, logProvider, colorIconContent, outlineIconContent);
1154
+ const app = await appStudio_1.AppStudioClient.updateApp(teamsAppId, appDefinition, appStudioToken, logProvider, colorIconContent, outlineIconContent);
1155
+ if (app.updatedAt && !isLocalDebug) {
1156
+ const time = new Date(app.updatedAt).getTime();
1157
+ (_a = ctx.envInfo.state.get(constants_1.PluginNames.APPST)) === null || _a === void 0 ? void 0 : _a.set(constants_2.Constants.TEAMS_APP_UPDATED_AT, time);
1158
+ }
1210
1159
  return teamsfx_api_1.ok(teamsAppId);
1211
1160
  }
1212
1161
  catch (e) {
@@ -1240,7 +1189,11 @@ class AppStudioPluginImpl {
1240
1189
  validDomains.push(botDomain);
1241
1190
  }
1242
1191
  }
1243
- let manifest = (await fs.readFile(await this.getManifestTemplatePath(ctx.root, isLocalDebug))).toString();
1192
+ const manifestFile = await this.getManifestTemplatePath(ctx.root, isLocalDebug);
1193
+ if (!(await fs.pathExists(manifestFile))) {
1194
+ return teamsfx_api_1.err(results_1.AppStudioResultFactory.SystemError(errors_1.AppStudioError.FileNotFoundError.name, errors_1.AppStudioError.FileNotFoundError.message(manifestFile)));
1195
+ }
1196
+ let manifest = (await fs.readFile(manifestFile)).toString();
1244
1197
  // Bot only project, without frontend hosting
1245
1198
  let endpoint = tabEndpoint;
1246
1199
  const solutionSettings = (_b = ctx.projectSettings) === null || _b === void 0 ? void 0 : _b.solutionSettings;
@@ -1367,6 +1320,27 @@ class AppStudioPluginImpl {
1367
1320
  }
1368
1321
  return teamsfx_api_1.ok([appDefinition, updatedManifest]);
1369
1322
  }
1323
+ async getSPFxManifest(ctx, isLocalDebug) {
1324
+ var _a, _b;
1325
+ let manifestString = JSON.stringify(await fs.readJSON(await this.getManifestTemplatePath(ctx.root, isLocalDebug)));
1326
+ if (common_1.isMultiEnvEnabled()) {
1327
+ const view = {
1328
+ config: ctx.envInfo.config,
1329
+ state: {
1330
+ "fx-resource-appstudio": {
1331
+ teamsAppId: await this.getTeamsAppId(ctx, isLocalDebug),
1332
+ },
1333
+ },
1334
+ localSettings: {
1335
+ teamsApp: {
1336
+ teamsAppId: (_b = (_a = ctx.localSettings) === null || _a === void 0 ? void 0 : _a.teamsApp) === null || _b === void 0 ? void 0 : _b.get(localSettingsConstants_1.LocalSettingsTeamsAppKeys.TeamsAppId),
1337
+ },
1338
+ },
1339
+ };
1340
+ manifestString = mustache_1.default.render(manifestString, view);
1341
+ }
1342
+ return manifestString;
1343
+ }
1370
1344
  async getManifestTemplatePath(projectRoot, isLocalDebug = false) {
1371
1345
  const appDir = await common_1.getAppDirectory(projectRoot);
1372
1346
  if (common_1.isMultiEnvEnabled()) {