This sample helps users that often create blog post to help with elements of the creation process to get posts created quicker using capabilities within Declarative Agents.
Common features that the agent can help with:
- Suggest an introduction based on a topic
- Generate blog post header imagery - based on tools of “Microsoft Designer” to generate AI image headers to represent an article in the interest of speed.
- Review existing articles, or Find content that I would reference quickly.
This is based off the blog post: Building a blog post helper agent for Microsoft 365 Copilot | pkbullock.com
| Version | Date | Author | Comments |
|---|---|---|---|
| 1.0 | January 6th, 2025 | Paul Bullock | Initial release |
THIS CODE IS PROVIDED AS IS WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESS OR IMPLIED, INCLUDING ANY IMPLIED WARRANTIES OF FITNESS FOR A PARTICULAR PURPOSE, MERCHANTABILITY, OR NON-INFRINGEMENT.
Include consise instructions to set up and run the sample. These are just an example!
- Clone this repository
- Open the cloned copy of this folder with Visual Studio Code
- Ensure that the Teams Toolkit extension is installed and connected to a Microsoft 365 account that has a Microsoft 365 Copilot license and permission to install Microsoft 365 applications
- Open the Teams Toolkit extension and, under "Lifecycle" clik "Provision" to deploy the agent to Microsoft 365
- Use the conversation starters to see the results of agent working on the content.
Note: currently targets authors website: https://pkbullock.com; you can change this by editing the appPackage/declarativeAgent.json file.
With the declarative agent, you can build a custom version of Copilot that can be used for specific scenarios, such as for specialized knowledge, implementing specific processes, or simply to save time by reusing a set of AI prompts. For example, a grocery shopping Copilot declarative agent can be used to create a grocery list based on a meal plan that you send to Copilot.
Prerequisites
To run this app template in your local dev machine, you will need:
- Node.js, supported versions: 18, 20
- A Microsoft 365 account for development.
- Teams Toolkit Visual Studio Code Extension version 5.0.0 and higher or Teams Toolkit CLI
- Microsoft 365 Copilot license
- First, select the Teams Toolkit icon on the left in the VS Code toolbar.
- In the Account section, sign in with your Microsoft 365 account if you haven't already.
- Create Teams app by clicking
Provisionin "Lifecycle" section. - Select
Preview in Copilot (Edge)orPreview in Copilot (Chrome)from the launch configuration dropdown. - Once the Copilot app is loaded in the browser, click on the "…" menu and select "Copilot chats". You will see your declarative agent on the right rail. Clicking on it will change the experience to showcase the logo and name of your declarative agent.
- Ask a question to your declarative agent and it should respond based on the instructions provided.
| Folder | Contents |
|---|---|
.vscode |
VSCode files for debugging |
appPackage |
Templates for the Teams application manifest, the GPT manifest and the API specification |
env |
Environment files |
The following files can be customized and demonstrate an example implementation to get you started.
| File | Contents |
|---|---|
appPackage/declarativeAgent.json |
Define the behaviour and configurations of the declarative agent. |
appPackage/manifest.json |
Teams application manifest that defines metadata for your declarative agent. |
The following are Teams Toolkit specific project files. You can visit a complete guide on Github to understand how Teams Toolkit works.
| File | Contents |
|---|---|
teamsapp.yml |
This is the main Teams Toolkit project file. The project file defines two primary things: Properties and configuration Stage definitions. |
- Add conversation starters: Conversation starters are hints that are displayed to the user to demonstrate how they can get started using the declarative agent.
- Add web content for the ability to search web information.
- Add OneDrive and SharePoint content as grounding knowledge for the agent.
- Add Microsoft Graph connectors content to ground agent with enterprise knowledge.
- Add API plugins for agent to interact with REST APIs.

