Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions samples/da-XBoxGameMaster/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
appPackage/*.zip
55 changes: 55 additions & 0 deletions samples/da-XBoxGameMaster/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,55 @@
# XBOX Game Master

## Summary

This sample is a declarative agent that is a master of XBOX games. Using the live XBOX gaming web site, it is able to answer questions, make recommendations, and even create graphics in the style of XBOX games.

![picture of the app recommending games](./assets/XBOX%20Game%20Master%202.png)
![picture of the app generating a simulated game image](./assets/XBOX%20Game%20Master%201.png)

## Frameworks

![No frameworks](https://img.shields.io/badge/nothing-1.00-green)

This app requires no tooling and can be developed using utilities that are built into any modern operating system such as a text editor, a web browser, and the ability to create a Zip archive file.

## Prerequisites

* [Office 365 tenant](https://dev.office.com/sharepoint/docs/spfx/set-up-your-development-environment) with permission to upload or install Teams applications
* [Microsoft 365 Copilot](https://www.microsoft.com/microsoft-365/copilot#plans)
* Any modern computer using Windows, MacOS, or Linux

## Version history

Version|Date|Author|Comments
-------|----|----|--------
1.0|January 9, 2025|Bob German|Initial release

## Disclaimer

**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.**

---

## Minimal Path to Awesome

* Clone or download this repository
* Navigate to this sample's **appPackage** folder on your computer
* (Optional: View or modify the files in the **appPackage** folder)
* Create a Zip file containing the contents of the **appPackage** folder at the root
* In Microsoft Teams click "Apps" 1️⃣ , "Manage yor apps"2️⃣ , "Upload an app" 3️⃣ , and then Upload a custom app 4️⃣ . Upload the zip file and follow the prompts to use your new agent in Copilot.

![Uploading a Teams application](./assets/Upload%20Teams%20app.png)

NOTE: If you want to make a second app, just copy and edit the files however **be sure to generate a new "id" value in manifest.json**. This can be any Globally Unique ID (GUID) as long as it's unique; you can generate one using the [online GUID generator](https://guidgenerator.com/)

## Features

This declarative agent includes:

* Ability to answer questions and make recommendations about XBOX games
* Grounded in the online XBOX game catalog at https://www.xbox.com
* Able to generate images based on XBOX games
* Shows how to use the `WebSearch` and `GraphicArt` capabilities for declarative agents

<img src="https://m365-visitor-stats.azurewebsites.net/copilot-pro-dev-samples/samples/da-xbox-game-master" />
34 changes: 34 additions & 0 deletions samples/da-XBoxGameMaster/appPackage/declarativeAgent.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
{
"$schema": "https://developer.microsoft.com/json-schemas/copilot/declarative-agent/v1.0/schema.json",
"version": "v1.2",
"name": "XBOX Game Master",
"description": "Copilot agent to recommend games for XBOX",
"instructions": "You are the `XBOX Game Master`, an avid XBOX gamer and an expert in the many available games for XBOX. Your job is to recommend and explain XBOX games to users. You are also able to generate cool game art based on users' suggestions. Greet users in a friendly tone and encourage them to play games and have fun. Try to work the XBox slogan, `Power your dreams` into each conversation.",
"conversation_starters": [
{
"title": "Get game recommendations",
"text":"What are some good racing games on XBOX"
},
{
"title": "Get game details",
"text": "How many airports are included in Flight Simulator?"
},
{
"title": "Generate cool game art",
"text": "Draw a picture of a dragon as it would appear in Minecraft"
}
],
"capabilities": [
{
"name": "WebSearch",
"sites": [
{
"url": "https://xbox.com"
}
]
},
{
"name": "GraphicArt"
}
]
}
39 changes: 39 additions & 0 deletions samples/da-XBoxGameMaster/appPackage/manifest.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
{
"$schema": "https://developer.microsoft.com/json-schemas/teams/v1.19/MicrosoftTeams.schema.json",
"manifestVersion": "1.19",
"version": "1.0.0",
"id": "53434cc0-6a90-4c50-9014-242ea676e615",
"developer": {
"name": "Bob German",
"websiteUrl": "https://www.xbox.com",
"privacyUrl": "https://support.xbox.com/help/family-online-safety/online-safety/manage-online-safety-and-privacy-settings-xbox-one",
"termsOfUseUrl": "https://www.xbox.com/legal/community-standards"
},
"icons": {
"color": "xbox192x192.png",
"outline": "xbox32x32.png"
},
"name": {
"short": "XBOX Game Master",
"full": "XBOX Game Master"
},
"description": {
"short": "Copilot agent to recommend games for XBOX",
"full": "Copilot agent to recommend games for XBOX based on the latest listings in xbox.com"
},
"accentColor": "#007D00",
"composeExtensions": [],
"permissions": [
"identity",
"messageTeamMembers"
],
"copilotAgents": {
"declarativeAgents": [
{
"id": "declarativeAgent",
"file": "declarativeAgent.json"
}
]
},
"validDomains": []
}
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
68 changes: 68 additions & 0 deletions samples/da-XBoxGameMaster/assets/sample.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,68 @@
[
{
"name": "pnp-copilot-pro-dev-da-xboxgamemaster",
"source": "pnp",
"title": "Declarative Agent with an API plugin that secured by Entra ID that validates its own tokens",
"shortDescription": "This sample demonstrates how to build a declarative agent for Microsoft 365 Copilot that answers questions about repairs. The agent uses an API plugin to connect to an API secured with OAuth. The project contains an Azure Function that validates tokens using an open source library.",
"url": "https://github.com/pnp/copilot-pro-dev-samples/tree/main/samples/da-xboxgamemaster",
"downloadUrl": "https://pnp.github.io/download-partial/?url=https://github.com/pnp/copilot-pro-dev-samples/tree/main/samples/da-XBoxGameMaster",
"longDescription": [
"This sample demonstrates how to build a declarative agent with no tools except what's built into Windows, MacOS, or Linux"
],
"creationDateTime": "2024-10-09",
"updateDateTime": "2024-10-11",
"products": [
"Microsoft 365 Copilot"
],
"metadata": [
{
"key": "PLATFORM",
"value": "None"
},
{
"key": "LANGUAGE",
"value": "JSON"
},
{
"key": "API-PLUGIN",
"value": "No"
},
{
"key": "GRAPH-CONNECTOR",
"value": "No"
}
],
"thumbnails": [
{
"type": "image",
"order": 100,
"url": "https://raw.githubusercontent.com/pnp/copilot-pro-dev-samples/refs/heads/notools/samples/da-XBoxGameMaster/assets/XBOX%20Game%20Master%201.png",
"alt": "Copilot agent generating a simulated image from an XBOX game"
}
],
"authors": [
{
"gitHubAccount": "BobGerman",
"pictureUrl": "https://github.com/BobGerman.png",
"name": "Bob German"
}
],
"references": [
{
"name": "Microsoft 365 Copilot extensibility",
"description": "Learn more about what Microsoft 365 Copilot and how you can extend it.",
"url": "https://learn.microsoft.com/microsoft-365-copilot/extensibility/"
},
{
"name": "Declarative agents for Microsoft 365 Copilot overview",
"description": "Learn more about what declarative agents for Microsoft 365 Copilot are.",
"url": "https://learn.microsoft.com/microsoft-365-copilot/extensibility/overview-declarative-agent"
},
{
"name": "Build a declarative agent for Microsoft 365 Copilot",
"description": "Learn how to build a declarative agent for Microsoft 365 Copilot.",
"url": "https://learn.microsoft.com/microsoft-365-copilot/extensibility/build-declarative-agents"
}
]
}
]
Loading