Skip to content

Commit 4656c6b

Browse files
heyitsaamirclaude
andauthored
docs: reorder card snippets, add llms.txt page (#2804)
## Summary - Reordered the adaptive cards "executing actions" page so SubmitData sits next to its handler examples instead of being buried in the middle - Added a dedicated llms.txt docs page under Developer Tools ## Test plan - [ ] Verify the adaptive cards executing actions page reads well top-to-bottom - [ ] Verify the new llms.txt page renders correctly with tabs --------- Co-authored-by: Claude <noreply@anthropic.com>
1 parent f908450 commit 4656c6b

5 files changed

Lines changed: 90 additions & 6 deletions

File tree

teams.md/docs/cli/index.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ slug: /
66
# Teams CLI
77

88
:::warning[Preview]
9-
The Teams CLI v2.1 is currently in **preview**. Commands, options, and behavior may change between releases.
9+
The Teams CLI v3 is currently in **preview**. Commands, options, and behavior may change between releases.
1010
:::
1111

1212
CLI for managing Microsoft Teams apps. Create, manage, and configure Teams apps from the command line.

teams.md/docs/main/developer-tools/README.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,4 +11,5 @@ Learn more about the developer tools that come with Teams SDK.
1111

1212
1. [Teams CLI](./cli)
1313
2. [Agent Skills](./agent-skills) — give AI coding assistants context for Teams development
14-
3. [DevTools](./devtools)
14+
3. [llms.txt](./llms-txt) — documentation files optimized for AI coding assistants
15+
4. [DevTools](./devtools)

teams.md/docs/main/developer-tools/agent-skills.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ summary: Give AI coding assistants (Claude Code, Cursor, GitHub Copilot) relevan
55

66
# Agent Skills
77

8-
[Agent Skills](https://agentskills.io/what-are-skills) give AI coding assistants relevant context for specific development tasks. The `teams-dev` skill is the go-to agent skill for Teams bot development. It gives AI coding assistants (Claude Code, Cursor, GitHub Copilot, and others) relevant context to assist in developing Teams bots and use the Teams CLI to manage your bot infrastructure. Instead of running CLI commands manually, you describe what you want and your AI assistant handles the rest.
8+
[Agent Skills](https://aka.ms/teams-agent-skills) give AI coding assistants relevant context for specific development tasks. The `teams-dev` skill is the go-to agent skill for Teams bot development. It gives AI coding assistants (Claude Code, Cursor, GitHub Copilot, and others) relevant context to assist in developing Teams bots and use the Teams CLI to manage your bot infrastructure. Instead of running CLI commands manually, you describe what you want and your AI assistant handles the rest.
99

1010
:::note Alternative: Use llms.txt directly
1111
If you'd rather not install a skill, you can provide the same context by pointing your AI tool to the llms.txt URL:
Lines changed: 69 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,69 @@
1+
---
2+
sidebar_position: 3
3+
summary: Documentation files optimized for AI coding assistants to give them context about the Teams SDK.
4+
---
5+
6+
# llms.txt
7+
8+
The Teams SDK publishes [llms.txt](https://llmstxt.org) files, plain-text versions of the documentation optimized for AI coding assistants. Point your tool at the right file and it gets the context it needs to help you build Teams apps.
9+
10+
## Available files
11+
12+
### Root
13+
14+
High-level SDK overview with links to reference guides.
15+
16+
```
17+
https://microsoft.github.io/teams-sdk/llms_docs/llms.txt
18+
```
19+
20+
:::tip
21+
Instead of manually providing URLs, you can install the [`teams-dev` agent skill](./agent-skills) which automatically gives your coding assistant the right context.
22+
:::
23+
24+
### Per-language
25+
26+
import Tabs from '@theme/Tabs';
27+
import TabItem from '@theme/TabItem';
28+
29+
<Tabs>
30+
<TabItem value="typescript" label="TypeScript">
31+
32+
**Small** — navigation index, the assistant fetches individual pages as needed.
33+
```
34+
https://microsoft.github.io/teams-sdk/llms_docs/llms_typescript.txt
35+
```
36+
37+
**Full** — complete documentation in a single file, best for tools with large context windows.
38+
```
39+
https://microsoft.github.io/teams-sdk/llms_docs/llms_typescript_full.txt
40+
```
41+
42+
</TabItem>
43+
<TabItem value="python" label="Python">
44+
45+
**Small** — navigation index, the assistant fetches individual pages as needed.
46+
```
47+
https://microsoft.github.io/teams-sdk/llms_docs/llms_python.txt
48+
```
49+
50+
**Full** — complete documentation in a single file, best for tools with large context windows.
51+
```
52+
https://microsoft.github.io/teams-sdk/llms_docs/llms_python_full.txt
53+
```
54+
55+
</TabItem>
56+
<TabItem value="csharp" label="C#">
57+
58+
**Small** — navigation index, the assistant fetches individual pages as needed.
59+
```
60+
https://microsoft.github.io/teams-sdk/llms_docs/llms_csharp.txt
61+
```
62+
63+
**Full** — complete documentation in a single file, best for tools with large context windows.
64+
```
65+
https://microsoft.github.io/teams-sdk/llms_docs/llms_csharp_full.txt
66+
```
67+
68+
</TabItem>
69+
</Tabs>

teams.md/src/pages/templates/in-depth-guides/adaptive-cards/executing-actions.mdx

Lines changed: 17 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -60,11 +60,25 @@ Input Controls provide ways for you to validate. More details can be found on th
6060

6161
<LanguageInclude section="input-validation-example" />
6262

63-
## Server Handlers
63+
## Routing & Handlers
6464

65-
### Basic Structure
65+
### Using SubmitData
6666

67-
Card actions arrive as `card.action` activities in your app. These give you access to the validated input values plus any `data` values you had configured to be sent back to you.
67+
The SDK provides a `SubmitData` helper that sets the routing key for your action. This is the recommended way to wire up actions to specific handlers:
68+
69+
<LanguageInclude section="submit-data-example" />
70+
71+
### Action-Specific Handlers
72+
73+
Register handlers for specific actions. When you use `SubmitData` to set the action name on the card, the SDK routes directly to the matching handler:
74+
75+
<LanguageInclude section="sub-route-handler-example" />
76+
77+
This is cleaner than a catch-all with a switch statement, and scales better as you add more actions.
78+
79+
### Catch-All Handler
80+
81+
If you need to handle all card actions in one place, you can use the catch-all handler:
6882

6983
<LanguageInclude section="server-handler-example" />
7084

0 commit comments

Comments
 (0)