@microsoft/teamsfx-core 3.0.10-alpha.c6f2c2bc0.0 → 3.0.10-alpha.edb63176e.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 (53) hide show
  1. package/build/common/templates-config.json +1 -1
  2. package/build/component/driver/script/scriptDriver.js +1 -1
  3. package/build/component/driver/script/scriptDriver.js.map +1 -1
  4. package/build/component/generator/configFiles/configGenerator.d.ts.map +1 -1
  5. package/build/component/generator/configFiles/configGenerator.js +1 -0
  6. package/build/component/generator/configFiles/configGenerator.js.map +1 -1
  7. package/build/component/generator/configFiles/copyPolicy.d.ts +2 -0
  8. package/build/component/generator/configFiles/copyPolicy.d.ts.map +1 -1
  9. package/build/component/generator/configFiles/copyPolicy.js +24 -3
  10. package/build/component/generator/configFiles/copyPolicy.js.map +1 -1
  11. package/build/core/generateConfigFiles.d.ts.map +1 -1
  12. package/build/core/generateConfigFiles.js +4 -1
  13. package/build/core/generateConfigFiles.js.map +1 -1
  14. package/package.json +4 -4
  15. package/resource/package.nls.cs.json +3 -3
  16. package/resource/package.nls.de.json +3 -3
  17. package/resource/package.nls.es.json +3 -3
  18. package/resource/package.nls.fr.json +3 -3
  19. package/resource/package.nls.it.json +3 -3
  20. package/resource/package.nls.ja.json +3 -3
  21. package/resource/package.nls.ko.json +3 -3
  22. package/resource/package.nls.pl.json +3 -3
  23. package/resource/package.nls.pt-BR.json +1 -1
  24. package/resource/package.nls.ru.json +3 -3
  25. package/resource/package.nls.tr.json +3 -3
  26. package/resource/package.nls.zh-Hans.json +3 -3
  27. package/resource/package.nls.zh-Hant.json +3 -3
  28. package/templates/configs/local/typescript/.vscode/launch.json.tpl +5 -5
  29. package/templates/configs/local/typescript/.vscode/tasks.json.tpl +1 -1
  30. package/templates/configs/remote/python/.vscode/launch.json.tpl +70 -0
  31. package/templates/configs/remote/python/.webappignore +11 -0
  32. package/templates/configs/remote/python/env/.env.dev +11 -0
  33. package/templates/configs/remote/python/infra/azure.bicep.tpl +108 -0
  34. package/templates/configs/remote/python/infra/azure.parameters.json.tpl +20 -0
  35. package/templates/configs/remote/python/infra/botRegistration/azurebot.bicep +42 -0
  36. package/templates/configs/remote/python/infra/botRegistration/readme.md +1 -0
  37. package/templates/configs/remote/python/m365agents.yml.tpl +131 -0
  38. package/templates/configs/remote/typescript/.vscode/launch.json.tpl +70 -0
  39. package/templates/configs/remote/typescript/.webappignore +27 -0
  40. package/templates/configs/remote/typescript/env/.env.dev +11 -0
  41. package/templates/configs/remote/typescript/infra/azure.bicep.tpl +105 -0
  42. package/templates/configs/remote/typescript/infra/azure.parameters.json.tpl +17 -0
  43. package/templates/configs/remote/typescript/infra/botRegistration/azurebot.bicep +42 -0
  44. package/templates/configs/remote/typescript/infra/botRegistration/readme.md +1 -0
  45. package/templates/configs/remote/typescript/m365agents.yml.tpl +142 -0
  46. package/templates/configs/remote/typescript/web.config +60 -0
  47. package/templates/fallback/common.zip +0 -0
  48. package/templates/fallback/csharp.zip +0 -0
  49. package/templates/fallback/js.zip +0 -0
  50. package/templates/fallback/python.zip +0 -0
  51. package/templates/fallback/ts.zip +0 -0
  52. package/templates/metadata.zip +0 -0
  53. /package/templates/configs/playground/{typescript/.localConfigs.playground → python/env/.env.playground.user} +0 -0
@@ -237,7 +237,7 @@
237
237
  "error.generator.SampleNotFoundError": "%s örneği bulunamıyor.",
238
238
  "error.generator.UnzipError": "Şablonlar ayık ve diske kaydedilemiyor.",
239
239
  "error.generator.MissKeyError": "%s anahtarı bulunamıyor",
240
- "error.generator.FileConflictError": "File conflict at %s",
240
+ "error.generator.FileConflictError": "%s konumunda dosya çakışması",
241
241
  "error.generator.FetchSampleInfoError": "Örnek bilgiler getirilemiyor",
242
242
  "error.generator.DownloadSampleApiLimitError": "Hız sınırlaması nedeniyle örnek indirilemiyor. Hız sınırı sıfırlandıktan sonra bir saat içinde yeniden deneyin veya depoya bu depodan el ile %s.",
243
243
  "error.generator.DownloadSampleNetworkError": "Ağ hatası nedeniyle örnek indirilemiyor. Ağ bağlantınızı denetleyin ve yeniden deneyin veya depoya bu depodan el ile %s",
@@ -945,7 +945,7 @@
945
945
  "error.yaml.InvalidActionInputError": "'%s' eylemi, %s parametreleri eksik olduğundan veya sağlanan YAML dosyasında (%s) geçersiz değere sahip olduğundan tamamlanamıyor. Gerekli parametrelerin sağlandığından ve geçerli değerlere sahip olduklarından emin olup yeniden deneyin.",
946
946
  "error.common.InstallSoftwareError": "%s yüklenemiyor. Visual Studio Code’da Araç Seti'ni kullanıyorsanız Visual Studio Code’u kendiniz yükleyip yeniden başlatabilirsiniz.",
947
947
  "error.common.VersionError": "Belirtilen sürüm aralığını karşılayan bir sürüm %s.",
948
- "error.common.MissingEnvironmentVariablesError": "Missing environment variables '%s' for file: %s. Please edit the .env file '%s' or '%s', or adjust system environment variables. For new projects, run local debugging or provision a remote environment to set these variables.",
948
+ "error.common.MissingEnvironmentVariablesError": "'%s' dosyası için eksik ortam değişkenleri: %s. Lütfen .env dosyasını '%s' veya '%s' olarak düzenleyin ya da sistem ortam değişkenlerini ayarlayın. Yeni projeler için bu değişkenleri ayarlamak amacıyla yerel hata ayıklamayı çalıştırın veya uzak bir ortam sağlayın.",
949
949
  "error.common.InvalidProjectError": "Bu komut yalnızca Microsoft 365 Aracı Araç Seti tarafından oluşturulan projeler için çalışır. 'm365agents.yml' veya 'm365agents.local.yml' bulunamadı",
950
950
  "error.common.InvalidProjectError.display": "Bu komut yalnızca Microsoft 365 Aracı Araç Seti tarafından oluşturulan projeler için çalışır. Yaml dosyası bulunamadı: %s",
951
951
  "error.common.FileNotFoundError": "Dosya veya dizin bulunamadı: '%s'. Mevcut olup olmadığını ve buna erişim izninizin olup olmadığını denetleyin.",
@@ -1134,7 +1134,7 @@
1134
1134
  "core.createProjectQuestion.mcpServerType.remote.detail": "HTTP üzerinden uzaktan barındırılan bir MCP sunucusuna bağlanın",
1135
1135
  "core.createProjectQuestion.mcpLocalServer.title": "Yerel MCP Sunucusu",
1136
1136
  "core.createProjectQuestion.mcpLocalServer.placeholder": "Yerel bir MCP sunucusu seçin",
1137
- "core.createProjectQuestion.mcpLocalServer.validationHelp": "At least one MCP server must be selected",
1137
+ "core.createProjectQuestion.mcpLocalServer.validationHelp": "En az bir MCP sunucusunun seçilmiş olması gerekir",
1138
1138
  "core.MCPForDA.updatePluginManifest": "MCP sunucunuzdan seçilen işlemler, Copilot'ın etkileşim kurması için başarıyla eklendi. Ayrıntıları kontrol etmek için '%s' sayfasına gidebilirsiniz. Artık bildirim aracınızı sağlama işlemi için devam edebilirsiniz.",
1139
1139
  "core.MCPForDA.mcpAuthMetadataMissingError": "MCP sunucusunda kimlik doğrulama meta verileri bulunamadı. Lütfen MCP sunucusunun doğru yapılandırıldığından emin olun ve tekrar deneyin. Ayrıntılar: %s",
1140
1140
  "core.MCPForDA.mcpAuthMetadataUrlNotFound": "MCP sunucusunun yanıtındaki \"resource_metadata\" özelliğinde kimlik doğrulama meta verileri bulunamadı.",
@@ -237,7 +237,7 @@
237
237
  "error.generator.SampleNotFoundError": "无法找到示例: %s。",
238
238
  "error.generator.UnzipError": "无法提取模板并将其保存到磁盘。",
239
239
  "error.generator.MissKeyError": "无法找到键 %s",
240
- "error.generator.FileConflictError": "File conflict at %s",
240
+ "error.generator.FileConflictError": "%s 处发生文件冲突",
241
241
  "error.generator.FetchSampleInfoError": "无法提取示例信息",
242
242
  "error.generator.DownloadSampleApiLimitError": "由于速率限制,无法下载示例。请在速率限制重置后一小时后重试,或者可以从 %s 手动克隆存储库。",
243
243
  "error.generator.DownloadSampleNetworkError": "由于网络错误,无法下载示例。请检查网络连接,然后重试,或者你可以从 %s 手动克隆存储库",
@@ -945,7 +945,7 @@
945
945
  "error.yaml.InvalidActionInputError": "无法完成 \"%s\" 操作,因为以下参数: %s 缺失或在提供的 yaml 文件中具有无效值: %s。请确保提供所需的参数并具有有效值,然后重试。",
946
946
  "error.common.InstallSoftwareError": "无法安装 %s。如果在 Visual Studio Code 中使用工具包,可手动安装该工具包并重启 Visual Studio Code。",
947
947
  "error.common.VersionError": "找不到满足版本范围 %s 的版本。",
948
- "error.common.MissingEnvironmentVariablesError": "Missing environment variables '%s' for file: %s. Please edit the .env file '%s' or '%s', or adjust system environment variables. For new projects, run local debugging or provision a remote environment to set these variables.",
948
+ "error.common.MissingEnvironmentVariablesError": "文件 %s 缺少环境变量 \"%s\"。请编辑 .env 文件 \"%s\" \"%s\",或调整系统环境变量。对于新项目,请运行本地调试或预配远程环境以设置这些变量。",
949
949
  "error.common.InvalidProjectError": "此命令仅适用于由 Microsoft 365 智能体工具包创建的项目。找不到 “m365agents.yml” 或 “m365agents.local.yml”",
950
950
  "error.common.InvalidProjectError.display": "此命令仅适用于由 Microsoft 365 智能体工具包创建的项目。找不到 Yaml 文件: %s",
951
951
  "error.common.FileNotFoundError": "找不到文件或目录: '%s'。检查是否存在,以及你是否有权访问。",
@@ -1134,7 +1134,7 @@
1134
1134
  "core.createProjectQuestion.mcpServerType.remote.detail": "通过 HTTP 连接远程托管的 MCP 服务器",
1135
1135
  "core.createProjectQuestion.mcpLocalServer.title": "本地 MCP 服务器",
1136
1136
  "core.createProjectQuestion.mcpLocalServer.placeholder": "选择本地 MCP 服务器",
1137
- "core.createProjectQuestion.mcpLocalServer.validationHelp": "At least one MCP server must be selected",
1137
+ "core.createProjectQuestion.mcpLocalServer.validationHelp": "至少必须选择一个 MCP 服务器",
1138
1138
  "core.MCPForDA.updatePluginManifest": "已成功添加从 MCP 服务器选择的操作,供 Copilot 交互。可转到“%s”查看详细信息。现在你可预配声明性智能体以继续。",
1139
1139
  "core.MCPForDA.mcpAuthMetadataMissingError": "无法在 MCP 服务器中找到身份验证元数据。请确保 MCP 服务器配置正确,然后重试。详细信息: %s",
1140
1140
  "core.MCPForDA.mcpAuthMetadataUrlNotFound": "无法从 MCP 服务器响应的 \"resource_metadata\" 属性中找到身份验证元数据。",
@@ -237,7 +237,7 @@
237
237
  "error.generator.SampleNotFoundError": "找不到範例: %s。",
238
238
  "error.generator.UnzipError": "無法擷取範本並將它們儲存到磁碟。",
239
239
  "error.generator.MissKeyError": "找不到金鑰 %s",
240
- "error.generator.FileConflictError": "File conflict at %s",
240
+ "error.generator.FileConflictError": "%s 發生檔案衝突",
241
241
  "error.generator.FetchSampleInfoError": "無法擷取範例資訊",
242
242
  "error.generator.DownloadSampleApiLimitError": "由於速率限制,無法下載樣本。請在速率限制重設后一小時后再試一次,或者您可以從 %s 手動複製存放庫。",
243
243
  "error.generator.DownloadSampleNetworkError": "由於網路錯誤,無法下載範例。檢查您的網路連線,然後再試一次,或者您可以手動從 %s 複製存放庫",
@@ -945,7 +945,7 @@
945
945
  "error.yaml.InvalidActionInputError": "無法完成 '%s' 動作,因為下列參數: %s,在提供的 yaml 檔案中遺失或具有無效值: %s。請確定已提供所需的參數,且具有有效的值,然後再試一次。",
946
946
  "error.common.InstallSoftwareError": "無法安裝 %s。如果您使用 Visual Studio Code 中的工具組,則可以手動安裝並重新啟動 Visual Studio Code。",
947
947
  "error.common.VersionError": "找不到符合版本範圍 %s 的版本。",
948
- "error.common.MissingEnvironmentVariablesError": "Missing environment variables '%s' for file: %s. Please edit the .env file '%s' or '%s', or adjust system environment variables. For new projects, run local debugging or provision a remote environment to set these variables.",
948
+ "error.common.MissingEnvironmentVariablesError": "檔案 %s 缺少環境變數 '%s'。請編輯 .env 檔案 '%s' '%s',或調整系統環境變數。針對新專案,請執行本機偵錯或佈建遠端環境以設定這些變數。",
949
949
  "error.common.InvalidProjectError": "此命令僅適用於 Microsoft 365 代理程式工具組建立的專案。找不到 'm365agents.yml' 或 'm365agents.local.yml'",
950
950
  "error.common.InvalidProjectError.display": "此命令僅適用於 Microsoft 365 代理程式工具組建立的專案。找不到 Yaml 檔案: %s",
951
951
  "error.common.FileNotFoundError": "找不到檔案或目錄: '%s'。請檢查它是否存在,以及您是否有存取它的權限。",
@@ -1134,7 +1134,7 @@
1134
1134
  "core.createProjectQuestion.mcpServerType.remote.detail": "透過 HTTP 連線到遠端託管的 MCP 伺服器",
1135
1135
  "core.createProjectQuestion.mcpLocalServer.title": "本機 MCP 伺服器",
1136
1136
  "core.createProjectQuestion.mcpLocalServer.placeholder": "選取本機 MCP 伺服器",
1137
- "core.createProjectQuestion.mcpLocalServer.validationHelp": "At least one MCP server must be selected",
1137
+ "core.createProjectQuestion.mcpLocalServer.validationHelp": "必須選取至少一個 MCP 伺服器",
1138
1138
  "core.MCPForDA.updatePluginManifest": "已順利新增從 MCP 伺服器選取的作業,讓 Copilot 與其互動。您可以前往 '%s' 來查看詳細資料。現在,您可以佈建宣告式代理程式以繼續。",
1139
1139
  "core.MCPForDA.mcpAuthMetadataMissingError": "在 MCP 伺服器中找不到驗證中繼資料。請確定您的 MCP 伺服器已正確設定,然後再試一次。詳細資料: %s",
1140
1140
  "core.MCPForDA.mcpAuthMetadataUrlNotFound": "無法從 MCP 伺服器的回應中找到來自 \"resource_metadata\" 屬性的驗證中繼資料。",
@@ -86,7 +86,7 @@
86
86
  "preLaunchTask": "Start App Locally",
87
87
  "presentation": {
88
88
  "group": "2-local",
89
- "order": 1
89
+ "order": 4
90
90
  },
91
91
  "stopAll": true
92
92
  },
@@ -99,7 +99,7 @@
99
99
  "preLaunchTask": "Start App Locally",
100
100
  "presentation": {
101
101
  "group": "2-local",
102
- "order": 2
102
+ "order": 5
103
103
  },
104
104
  "stopAll": true
105
105
  },
@@ -111,7 +111,7 @@
111
111
  "preLaunchTask": "Start App in Desktop Client",
112
112
  "presentation": {
113
113
  "group": "2-local",
114
- "order": 3
114
+ "order": 6
115
115
  },
116
116
  "stopAll": true
117
117
  },
@@ -124,7 +124,7 @@
124
124
  ],
125
125
  "preLaunchTask": "Start App Locally",
126
126
  "presentation": {
127
- "group": "3-copilot",
127
+ "group": "2-local",
128
128
  "order": 1
129
129
  },
130
130
  "stopAll": true
@@ -137,7 +137,7 @@
137
137
  ],
138
138
  "preLaunchTask": "Start App Locally",
139
139
  "presentation": {
140
- "group": "3-copilot",
140
+ "group": "2-local",
141
141
  "order": 2
142
142
  },
143
143
  "stopAll": true
@@ -30,7 +30,7 @@
30
30
  "portOccupancy" // Validate available ports to ensure those debug ones are not occupied.
31
31
  ],
32
32
  "portOccupancy": [
33
- 3978, // tab service port,
33
+ 3978, // app port,
34
34
  9239 // app inspector port for Node.js debugger
35
35
  ]
36
36
  }
@@ -0,0 +1,70 @@
1
+ {
2
+ "version": "0.2.0",
3
+ "configurations": [
4
+ {{#supportCopilot}}
5
+ {
6
+ "name": "(Preview) View Remote Agent in Copilot (Edge)",
7
+ "type": "msedge",
8
+ "request": "launch",
9
+ "url": "https://m365.cloud.microsoft/chat/entity1-d870f6cd-4aa5-4d42-9626-ab690c041429/${agent-hint}?auth=2&${account-hint}&developerMode=Basic",
10
+ "presentation": {
11
+ "group": "3-remote",
12
+ "order": 1
13
+ },
14
+ "internalConsoleOptions": "neverOpen",
15
+ "runtimeArgs": [
16
+ "--remote-debugging-port=9222",
17
+ "--no-first-run"
18
+ ]
19
+ },
20
+ {
21
+ "name": "(Preview) View Remote Agent in Copilot (Chrome)",
22
+ "type": "chrome",
23
+ "request": "launch",
24
+ "url": "https://m365.cloud.microsoft/chat/entity1-d870f6cd-4aa5-4d42-9626-ab690c041429/${agent-hint}?auth=2&${account-hint}&developerMode=Basic",
25
+ "presentation": {
26
+ "group": "3-remote",
27
+ "order": 2
28
+ },
29
+ "internalConsoleOptions": "neverOpen",
30
+ "runtimeArgs": [
31
+ "--remote-debugging-port=9223",
32
+ "--no-first-run"
33
+ ]
34
+ },
35
+ {{/supportCopilot}}
36
+ {
37
+ "name": "View Remote App in Teams (Edge)",
38
+ "type": "msedge",
39
+ "request": "launch",
40
+ "url": "https://teams.microsoft.com/l/app/$\{{TEAMS_APP_ID}}?installAppPackage=true&webjoin=true&${account-hint}",
41
+ "presentation": {
42
+ "group": "3-remote",
43
+ "order": 4
44
+ },
45
+ "internalConsoleOptions": "neverOpen"
46
+ },
47
+ {
48
+ "name": "View Remote App in Teams (Chrome)",
49
+ "type": "chrome",
50
+ "request": "launch",
51
+ "url": "https://teams.microsoft.com/l/app/$\{{TEAMS_APP_ID}}?installAppPackage=true&webjoin=true&${account-hint}",
52
+ "presentation": {
53
+ "group": "3-remote",
54
+ "order": 5
55
+ },
56
+ "internalConsoleOptions": "neverOpen"
57
+ },
58
+ {
59
+ "name": "View Remote App in Teams (Desktop)",
60
+ "type": "node",
61
+ "request": "launch",
62
+ "preLaunchTask": "Start App in Desktop Client (Remote)",
63
+ "presentation": {
64
+ "group": "3-remote",
65
+ "order": 6
66
+ },
67
+ "internalConsoleOptions": "neverOpen",
68
+ }
69
+ ]
70
+ }
@@ -0,0 +1,11 @@
1
+ .webappignore
2
+ .venv/
3
+ .vscode/
4
+ .env
5
+ env/
6
+ __pycache__/
7
+ README.md
8
+ m365agents.yml
9
+ m365agents.local.yml
10
+ m365agents.playground.yml
11
+ /devTools/
@@ -0,0 +1,11 @@
1
+ TEAMSFX_ENV=dev
2
+ APP_NAME_SUFFIX=dev
3
+
4
+ # Updating AZURE_SUBSCRIPTION_ID or AZURE_RESOURCE_GROUP_NAME after provision may also require an update to RESOURCE_SUFFIX, because some services require a globally unique name across subscriptions/resource groups.
5
+ AZURE_SUBSCRIPTION_ID=
6
+ AZURE_RESOURCE_GROUP_NAME=
7
+ RESOURCE_SUFFIX=
8
+
9
+ TEAMS_APP_ID=
10
+ BOT_ENDPOINT=
11
+ BOT_DOMAIN=
@@ -0,0 +1,108 @@
1
+ @maxLength(20)
2
+ @minLength(4)
3
+ @description('Used to generate names for all resources in this file')
4
+ param resourceBaseName string
5
+
6
+ param webAppSku string
7
+ param linuxFxVersion string
8
+
9
+ param serverfarmsName string = resourceBaseName
10
+ param webAppName string = resourceBaseName
11
+ param location string = resourceGroup().location
12
+ param pythonVersion string = linuxFxVersion
13
+ {{#hasAzureBot}}
14
+ @maxLength(42)
15
+ param botDisplayName string
16
+ {{/hasAzureBot}}
17
+
18
+ {{#hasAzureBot}}
19
+ resource identity 'Microsoft.ManagedIdentity/userAssignedIdentities@2023-01-31' = {
20
+ location: location
21
+ name: resourceBaseName
22
+ }
23
+ {{/hasAzureBot}}
24
+
25
+
26
+ resource serverfarm 'Microsoft.Web/serverfarms@2021-02-01' = {
27
+ kind: 'app,linux'
28
+ location: location
29
+ name: serverfarmsName
30
+ sku: {
31
+ name: webAppSku
32
+ }
33
+ properties:{
34
+ reserved: true
35
+ }
36
+ }
37
+
38
+ resource webApp 'Microsoft.Web/sites@2021-02-01' = {
39
+ kind: 'app,linux'
40
+ location: location
41
+ name: webAppName
42
+ properties: {
43
+ serverFarmId: serverfarm.id
44
+ httpsOnly: true
45
+ siteConfig: {
46
+ alwaysOn: true
47
+ appCommandLine: 'python app.py'
48
+ linuxFxVersion: linuxFxVersion
49
+ appSettings: [
50
+ {
51
+ name: 'WEBSITES_CONTAINER_START_TIME_LIMIT'
52
+ value: '900'
53
+ }
54
+ {
55
+ name: 'SCM_DO_BUILD_DURING_DEPLOYMENT'
56
+ value: 'true'
57
+ }
58
+ {{#hasAzureBot}}
59
+ {
60
+ name: 'CLIENT_ID'
61
+ value: identity.properties.clientId
62
+ }
63
+ {
64
+ name: 'TENANT_ID'
65
+ value: identity.properties.tenantId
66
+ }
67
+ {
68
+ name: 'BOT_TYPE'
69
+ value: 'UserAssignedMsi'
70
+ }
71
+ {{/hasAzureBot}}
72
+ ]
73
+ ftpsState: 'FtpsOnly'
74
+ }
75
+ }
76
+ {{#hasAzureBot}}
77
+ identity: {
78
+ type: 'UserAssigned'
79
+ userAssignedIdentities: {
80
+ '${identity.id}': {}
81
+ }
82
+ }
83
+ {{/hasAzureBot}}
84
+ }
85
+
86
+ {{#hasAzureBot}}
87
+ // Register your web service as a bot with the Bot Framework
88
+ module azureBotRegistration './botRegistration/azurebot.bicep' = {
89
+ name: 'Azure-Bot-registration'
90
+ params: {
91
+ resourceBaseName: resourceBaseName
92
+ botDisplayName: botDisplayName
93
+ identityResourceId: identity.id
94
+ identityClientId: identity.properties.clientId
95
+ identityTenantId: identity.properties.tenantId
96
+ botAppDomain: webApp.properties.defaultHostName
97
+ }
98
+ }
99
+ {{/hasAzureBot}}
100
+
101
+ // The output will be persisted in .env.{envName}. Visit https://aka.ms/teamsfx-actions/arm-deploy for more details.
102
+ output AZURE_APP_SERVICE_RESOURCE_ID string = webApp.id // used in deploy stage
103
+ output BOT_DOMAIN string = webApp.properties.defaultHostName
104
+ output BOT_ENDPOINT string = 'https://${webApp.properties.defaultHostName}'
105
+ {{#hasAzureBot}}
106
+ output BOT_ID string = identity.properties.clientId
107
+ output BOT_TENANT_ID string = identity.properties.tenantId
108
+ {{/hasAzureBot}}
@@ -0,0 +1,20 @@
1
+ {
2
+ "$schema": "https://schema.management.azure.com/schemas/2015-01-01/deploymentParameters.json#",
3
+ "contentVersion": "1.0.0.0",
4
+ "parameters": {
5
+ {{#hasAzureBot}}
6
+ "botDisplayName": {
7
+ "value": "{{appName}}"
8
+ },
9
+ {{/hasAzureBot}}
10
+ "resourceBaseName": {
11
+ "value": "app$\{{RESOURCE_SUFFIX}}"
12
+ },
13
+ "webAppSku": {
14
+ "value": "B3"
15
+ },
16
+ "linuxFxVersion": {
17
+ "value": "PYTHON|3.12"
18
+ }
19
+ }
20
+ }
@@ -0,0 +1,42 @@
1
+ @maxLength(20)
2
+ @minLength(4)
3
+ @description('Used to generate names for all resources in this file')
4
+ param resourceBaseName string
5
+
6
+ @maxLength(42)
7
+ param botDisplayName string
8
+
9
+ param botServiceName string = resourceBaseName
10
+ param botServiceSku string = 'F0'
11
+ param identityResourceId string
12
+ param identityClientId string
13
+ param identityTenantId string
14
+ param botAppDomain string
15
+
16
+ // Register your web service as a bot with the Bot Framework
17
+ resource botService 'Microsoft.BotService/botServices@2021-03-01' = {
18
+ kind: 'azurebot'
19
+ location: 'global'
20
+ name: botServiceName
21
+ properties: {
22
+ displayName: botDisplayName
23
+ endpoint: 'https://${botAppDomain}/api/messages'
24
+ msaAppId: identityClientId
25
+ msaAppMSIResourceId: identityResourceId
26
+ msaAppTenantId:identityTenantId
27
+ msaAppType:'UserAssignedMSI'
28
+ }
29
+ sku: {
30
+ name: botServiceSku
31
+ }
32
+ }
33
+
34
+ // Connect the bot service to Microsoft Teams
35
+ resource botServiceMsTeamsChannel 'Microsoft.BotService/botServices/channels@2021-03-01' = {
36
+ parent: botService
37
+ location: 'global'
38
+ name: 'MsTeamsChannel'
39
+ properties: {
40
+ channelName: 'MsTeamsChannel'
41
+ }
42
+ }
@@ -0,0 +1 @@
1
+ The `azurebot.bicep` module is provided to help you create Azure Bot service when you don't use Azure to host your app. If you use Azure as infrastrcture for your app, `azure.bicep` under infra folder already leverages this module to create Azure Bot service for you. You don't need to deploy `azurebot.bicep` again.
@@ -0,0 +1,131 @@
1
+ # yaml-language-server: $schema=https://aka.ms/m365-agents-toolkits/v1.11/yaml.schema.json
2
+ # Visit https://aka.ms/teamsfx-v5.0-guide for details on this file
3
+ # Visit https://aka.ms/teamsfx-actions for details on actions
4
+ version: v1.11
5
+
6
+ provision:
7
+ # Creates an app
8
+ - uses: teamsApp/create
9
+ with:
10
+ # app name
11
+ name: {{appName}}$\{{APP_NAME_SUFFIX}}
12
+ # Write the information of created resources into environment file for
13
+ # the specified environment variable(s).
14
+ writeToEnvironmentFile:
15
+ teamsAppId: TEAMS_APP_ID
16
+
17
+ - uses: arm/deploy # Deploy given ARM templates parallelly.
18
+ with:
19
+ # AZURE_SUBSCRIPTION_ID is a built-in environment variable,
20
+ # if its value is empty, toolkit will prompt you to select a subscription.
21
+ # Referencing other environment variables with empty values
22
+ # will skip the subscription selection prompt.
23
+ subscriptionId: $\{{AZURE_SUBSCRIPTION_ID}}
24
+ # AZURE_RESOURCE_GROUP_NAME is a built-in environment variable,
25
+ # if its value is empty, toolkit will prompt you to select or create one
26
+ # resource group.
27
+ # Referencing other environment variables with empty values
28
+ # will skip the resource group selection prompt.
29
+ resourceGroupName: $\{{AZURE_RESOURCE_GROUP_NAME}}
30
+ templates:
31
+ - path: ./infra/azure.bicep # Relative path to this file
32
+ # Placeholders will be replaced with corresponding environment
33
+ # variable before ARM deployment.
34
+ parameters: ./infra/azure.parameters.json
35
+ # Required when deploying ARM template
36
+ deploymentName: Create-resources
37
+ # Microsoft 365 Agents Toolkit will download this bicep CLI version from github for you,
38
+ # will use bicep CLI in PATH if you remove this config.
39
+ bicepCliVersion: v0.9.1
40
+
41
+ # Validate using manifest schema
42
+ - uses: teamsApp/validateManifest
43
+ with:
44
+ # Path to manifest template
45
+ manifestPath: ./appPackage/manifest.json
46
+
47
+ # Build app package with latest env value
48
+ - uses: teamsApp/zipAppPackage
49
+ with:
50
+ # Path to manifest template
51
+ manifestPath: ./appPackage/manifest.json
52
+ outputZipPath: ./appPackage/build/appPackage.$\{{TEAMSFX_ENV}}.zip
53
+ outputFolder: ./appPackage/build
54
+
55
+ # Validate app package using validation rules
56
+ - uses: teamsApp/validateAppPackage
57
+ with:
58
+ # Relative path to this file. This is the path for built zip file.
59
+ appPackagePath: ./appPackage/build/appPackage.$\{{TEAMSFX_ENV}}.zip
60
+
61
+ # Apply the app manifest to an existing app in Developer Portal.
62
+ # Will use the app id in manifest file to determine which app to update.
63
+ - uses: teamsApp/update
64
+ with:
65
+ # Relative path to this file. This is the path for built zip file.
66
+ appPackagePath: ./appPackage/build/appPackage.$\{{TEAMSFX_ENV}}.zip
67
+
68
+ {{#hasCopilot}}
69
+ - uses: teamsApp/extendToM365
70
+ with:
71
+ # Relative path to the build app package.
72
+ appPackagePath: ./appPackage/build/appPackage.$\{{TEAMSFX_ENV}}.zip
73
+ # Write the information of created resources into environment file for
74
+ # the specified environment variable(s).
75
+ writeToEnvironmentFile:
76
+ titleId: M365_TITLE_ID
77
+ appId: M365_APP_ID
78
+ {{/hasCopilot}}
79
+
80
+ deploy:
81
+ # Deploy your application to Azure App Service using the zip deploy feature.
82
+ # For additional details, refer to https://aka.ms/zip-deploy-to-app-services.
83
+ - uses: azureAppService/zipDeploy
84
+ with:
85
+ # Deploy base folder
86
+ artifactFolder: src
87
+ # Ignore file location, leave blank will ignore nothing
88
+ ignoreFile: .webappignore
89
+ # The resource id of the cloud resource to be deployed to.
90
+ # This key will be generated by arm/deploy action automatically.
91
+ # You can replace it with your existing Azure Resource id
92
+ # or add it to your environment variable file.
93
+ resourceId: $\{{AZURE_APP_SERVICE_RESOURCE_ID}}
94
+
95
+ publish:
96
+ # Validate using manifest schema
97
+ - uses: teamsApp/validateManifest
98
+ with:
99
+ # Path to manifest template
100
+ manifestPath: ./appPackage/manifest.json
101
+
102
+ # Build app package with latest env value
103
+ - uses: teamsApp/zipAppPackage
104
+ with:
105
+ # Path to manifest template
106
+ manifestPath: ./appPackage/manifest.json
107
+ outputZipPath: ./appPackage/build/appPackage.$\{{TEAMSFX_ENV}}.zip
108
+ outputFolder: ./appPackage/build
109
+
110
+ # Validate app package using validation rules
111
+ - uses: teamsApp/validateAppPackage
112
+ with:
113
+ # Relative path to this file. This is the path for built zip file.
114
+ appPackagePath: ./appPackage/build/appPackage.$\{{TEAMSFX_ENV}}.zip
115
+
116
+ # Apply the app manifest to an existing app in Developer Portal.
117
+ # Will use the app id in manifest file to determine which app to update.
118
+ - uses: teamsApp/update
119
+ with:
120
+ # Relative path to this file. This is the path for built zip file.
121
+ appPackagePath: ./appPackage/build/appPackage.$\{{TEAMSFX_ENV}}.zip
122
+
123
+ # Publish the app to Teams Admin Center (https://admin.teams.microsoft.com/policies/manage-apps)
124
+ # for review and approval
125
+ - uses: teamsApp/publishAppPackage
126
+ with:
127
+ appPackagePath: ./appPackage/build/appPackage.$\{{TEAMSFX_ENV}}.zip
128
+ # Write the information of created resources into environment file for
129
+ # the specified environment variable(s).
130
+ writeToEnvironmentFile:
131
+ publishedAppId: TEAMS_APP_PUBLISHED_APP_ID
@@ -0,0 +1,70 @@
1
+ {
2
+ "version": "0.2.0",
3
+ "configurations": [
4
+ {{#supportCopilot}}
5
+ {
6
+ "name": "(Preview) View Remote Agent in Copilot (Edge)",
7
+ "type": "msedge",
8
+ "request": "launch",
9
+ "url": "https://m365.cloud.microsoft/chat/entity1-d870f6cd-4aa5-4d42-9626-ab690c041429/${agent-hint}?auth=2&${account-hint}&developerMode=Basic",
10
+ "presentation": {
11
+ "group": "3-remote",
12
+ "order": 1
13
+ },
14
+ "internalConsoleOptions": "neverOpen",
15
+ "runtimeArgs": [
16
+ "--remote-debugging-port=9222",
17
+ "--no-first-run"
18
+ ]
19
+ },
20
+ {
21
+ "name": "(Preview) View Remote Agent in Copilot (Chrome)",
22
+ "type": "chrome",
23
+ "request": "launch",
24
+ "url": "https://m365.cloud.microsoft/chat/entity1-d870f6cd-4aa5-4d42-9626-ab690c041429/${agent-hint}?auth=2&${account-hint}&developerMode=Basic",
25
+ "presentation": {
26
+ "group": "3-remote",
27
+ "order": 2
28
+ },
29
+ "internalConsoleOptions": "neverOpen",
30
+ "runtimeArgs": [
31
+ "--remote-debugging-port=9223",
32
+ "--no-first-run"
33
+ ]
34
+ },
35
+ {{/supportCopilot}}
36
+ {
37
+ "name": "View Remote App in Teams (Edge)",
38
+ "type": "msedge",
39
+ "request": "launch",
40
+ "url": "https://teams.microsoft.com/l/app/$\{{TEAMS_APP_ID}}?installAppPackage=true&webjoin=true&${account-hint}",
41
+ "presentation": {
42
+ "group": "3-remote",
43
+ "order": 4
44
+ },
45
+ "internalConsoleOptions": "neverOpen"
46
+ },
47
+ {
48
+ "name": "View Remote App in Teams (Chrome)",
49
+ "type": "chrome",
50
+ "request": "launch",
51
+ "url": "https://teams.microsoft.com/l/app/$\{{TEAMS_APP_ID}}?installAppPackage=true&webjoin=true&${account-hint}",
52
+ "presentation": {
53
+ "group": "3-remote",
54
+ "order": 5
55
+ },
56
+ "internalConsoleOptions": "neverOpen"
57
+ },
58
+ {
59
+ "name": "View Remote App in Teams (Desktop)",
60
+ "type": "node",
61
+ "request": "launch",
62
+ "preLaunchTask": "Start App in Desktop Client (Remote)",
63
+ "presentation": {
64
+ "group": "3-remote",
65
+ "order": 6
66
+ },
67
+ "internalConsoleOptions": "neverOpen",
68
+ }
69
+ ]
70
+ }
@@ -0,0 +1,27 @@
1
+ .webappignore
2
+ .deployment
3
+ .localConfigs
4
+ .localConfigs.playground
5
+ .notification.localstore.json
6
+ .notification.playgroundstore.json
7
+ .vscode
8
+ *.js.map
9
+ *.ts.map
10
+ *.ts
11
+ .git*
12
+ .tsbuildinfo
13
+ CHANGELOG.md
14
+ README.md
15
+ local.settings.json
16
+ test
17
+ tsconfig.json
18
+ .DS_Store
19
+ m365agents.yml
20
+ m365agents.*.yml
21
+ /env/
22
+ /node_modules/.bin
23
+ /node_modules/ts-node
24
+ /node_modules/typescript
25
+ /appPackage/
26
+ /infra/
27
+ /devTools/
@@ -0,0 +1,11 @@
1
+ TEAMSFX_ENV=dev
2
+ APP_NAME_SUFFIX=dev
3
+
4
+ # Updating AZURE_SUBSCRIPTION_ID or AZURE_RESOURCE_GROUP_NAME after provision may also require an update to RESOURCE_SUFFIX, because some services require a globally unique name across subscriptions/resource groups.
5
+ AZURE_SUBSCRIPTION_ID=
6
+ AZURE_RESOURCE_GROUP_NAME=
7
+ RESOURCE_SUFFIX=
8
+
9
+ TEAMS_APP_ID=
10
+ BOT_ENDPOINT=
11
+ BOT_DOMAIN=