-
Notifications
You must be signed in to change notification settings - Fork 0
Deployment guide
To begin, you will need:
-
User account to sign in to Badgr. Choose one of the available regions: US, Canada, Australia, or EU/Ireland and remember your selection.
-
An Azure subscription where you can create the following kinds of resources:
-
App service
-
App service plan
-
Bot channels registration
-
Azure Key Vault
-
Application Insights
-
A copy of the Badgr app GitHub repo URL
-
User account to sign in US Server Badgr website
- If this is the first time you are setting up an account in Badgr, then please Sign up with your preferred region.
- Sign in to Badgr with the account you created above.
- Please note which server location you are using:
- US - https://badgr.com (API at api.badgr.io)
- AU - https://au.badgr.com (API at api.au.badgr.io)
- EU - https://eu.badgr.com (API at api.eu.badgr.io)
- CA - https://ca.badgr.com (API at api.ca.badgr.io)
-
After successful sign in, please go to the Issuers menu and add Create new issuer. For more help, please refer
- Please add details in Issuer form
- Name (for e.g. Fabrikam University). Please make sure that the issuer name is not used before to avoid unwanted conflicts.
- Website URL (for e.g. http://fabrikam.com/ )
- Contact Email - please select the same email account you have signed up
- Description - Add your group description
- Please read the policy and click Create Issuer
- Please note the name of Issuer as it will be used in step 3 section 6
- Please add details in Issuer form
-
We recommend to create few badges after this step. These badges will be available for all users in your company once they sign in via Open Badges teams application.
- tip: Decide a few badges that you would like to allow team members to award to each other. Upload badge images that match your brand and program instead of random images.
-
Client id and client secret from Badgr (Needed in Step 4)
- To get client id and client secret, please send email to Badgr support team with following details
- Mail address: [email protected]
- Subject: : Client id and secret for Open Badges Microsoft Teams app
- Body: Please make sure to add below information in email
- Badgr account email - (Your Badgr account email)
- Badgr account server location (US, CA, EU, AU) from step 1.1
- Redirect URL -
https://token.botframework.com/.auth/web/redirect
- Website URL -
https://open-badges-{yourcompanyname}.azurewebsites.net
(please make sure to use the same URL you are planning for deployment and remove the{}
symbols) - Service name (required, for example "Fabrikam University Professional Development")
- Application logo (optional, will use MS Teams logo if none provided)
- Privacy policy URL of your organization (required for step 5.2 even if not functional yet)
- Terms of service URL of your organization (required for step 5.2 even if not functional yet)
- Badgr support team will revert back within 2-3 business day with link to access client id and secret via Owncloud secure file share.
- Please copy and save the client id and secret as it will be used while setting up the authentication in steps 4.4.iii and 4.4.iv
- To get client id and client secret, please send email to Badgr support team with following details
By this time, you should have following details :
- User account email and password of Issuer owner in Badgr
- Issuer name within Badgr
-
Open the Azure Active Directory panel in the Azure portal. If you are not in the correct tenant, click Switch directory to switch to the correct tenant. (For instruction on creating a tenant, see Access the portal and create a tenant.)
-
Open the App registrations panel.
-
In the App registrations panel, click New registration.
-
Fill in the required fields and create the app registration.
- Name your application - if you are following the template for a default deployment, we recommend "Open Badges".
- Select the Supported account type as Accounts in any organizational directory.
- For the Redirect URI
- Select Web
- Set the URL to https://token.botframework.com/.auth/web/redirect.
- Click Register
- Once it is created, Azure displays the Overview page for the app.
- Record the Application (client) ID value. You will use this value later as the Client ID when you register your Microsoft Azure Active Directory application with your bot.
- Also record the Directory (tenant) ID value. You will also use this to register this application with your bot (Step 3.6.iii)
- Also record the Directory (tenant) ID value. You will also use this to register this application with your bot (Step 3.6.iii)
-
In the navigation pane, click Certificates & secrets to create a secret for your application.
- Under Client secrets, click New client secret.
- Add a description to identify this secret from others you might need to create for this app, such as bot login.
- Set Expires to Never
- Click Add
- Before leaving this page, record the secret. You will use this value later as the Client secret when you register your Microsoft Azure Active Directory application with your bot. Application Secret = Bot Client Secret (Step 3.6.ii).
You now have an application registered in Microsoft Azure Active Directory.
-
When prompted, log in to your Azure subscription.
-
Azure will create a "Custom deployment" based on the ARM template and ask you to fill in the template parameters.
-
Select a subscription and resource group.
- We recommend creating a new resource group.
- The resource group location MUST be in a data center that supports: Application Insights; Key Vault. For an up-to-date list, click here, and select a region where the following services are available:
- Application Insights
- Key Vault
-
Enter a "Base Resource Name", which the template uses to generate names for the other resources. (no spaces)
- The app service name [Base Resource Name] must be available. For example, if you select Open Badges as the base name, the name Open Badges must be available (not taken); otherwise, the deployment will fail with a Conflict error.
- Remember the base resource name that you selected. We will need it later.
-
Fill in the various IDs in the template. Make sure that the values are copied as-is, with no extra spaces. The template checks that GUID are exactly 36 characters.
- Bot client ID: The application (client) ID of the Microsoft Teams bot app
- Bot client secret: The client secret of the Microsoft Teams bot app
- Tenant ID: Tenant ID where application is hosted (from step 2)
-
Badge provider base URL:
- US - https://api.badgr.io
- AU - https://api.au.badgr.io
- EU - https://api.eu.badgr.io
- CA - https://api.ca.badgr.io
- Issuer entity name: User need to provide Issuer group entity name (created in Step 1)
- Superuser username: User need to provide issuer group owners user id (Owner account used in Step 1)
- Superuser Password: User need to provide issuer group owners password (Owner account password used in Step 1)
-
If you wish to change the app name, description, and icon from the defaults, modify the corresponding template parameters.
-
Agree to the Azure terms and conditions by clicking on the check box "I agree to the terms and conditions stated above" located at the bottom of the page.
-
Click on "Purchase" to start the deployment.
-
Wait for the deployment to finish. You can check the progress of the deployment from the "Notifications" pane of the Azure Portal. It can take up to 20 minutes for the deployment to finish.
-
Once the deployment has finished, you would be directed to a page that has the following fields:
- BotId - This is the Microsoft Application ID for the Open Badges.
- AppDomain - This is the base domain for the Open Badges.
-
Note the name of the bot that you deployed, which is [BaseResourceName].
-
Go to azure portal here and search for your bot.
-
Click on the bot in the application list. Under "Settings", click on "Add Setting".
-
Fill in the form as follows:
- For Name, enter "BadgrAuth". You'll use it in your bot code.
- For Service Provider, select Generic Oauth 2.
- For Client ID, enter the application (client) ID that Badgr team has provided from step 1.4.
- For Client secret, enter the secret that you have received from Badgr team from step 1.4.
- For Authorization URL, use https://badgr.io/auth/oauth2/authorize (US Server ONLY)
- AU - https://au.badgr.com/auth/oauth2/authorize.
- EU - https://eu.badgr.com/auth/oauth2/authorize.
- CA - https://ca.badgr.com/auth/oauth2/authorize.
- NOTE: Only use this if you are using the free version of Badgr. If you are a paying customer subscribed to Badgr Pro, please use the production domain provided during implementation. Example URL https://www.{company name}.badgr.com/auth/oauth2/authorize. If your organization has a custom domain, add “/auth/oauth2/authorize” to the end of it.
- For Token URL, use https://api.badgr.io/o/token (US Server ONLY)
- For Refresh URL, use https://api.badgr.io/o/token (US Server ONLY)
- For Scopes, enter the names of the permission you chose from application registration: rw:backpack rw:profile rw:issuer
-
Click Save.
Create Teams app package:
-
Open the Manifest\manifest.json file in a text editor.
-
Change the placeholder fields in the manifest to values appropriate for your organization.
- developer.name (What's this?)
- developer.websiteUrl
- developer.privacyUrl
- developer.termsOfUseUrl
-
Change the
<<botId>>
placeholder to your Azure Active Directory application's ID from step 3.11. This is the same GUID that you entered in the template under "Bot Client ID". -
In the "validDomains" section, replace the
<<appDomain>>
with your bot App Service's domain. This will be [BaseResourceName].azurewebsites.net. For example if you chose "contosoBadgr" as the base name, change the placeholder to contosoBadgr.azurewebsites.net.
-
Create a ZIP package with the manifest.json,color.png, and outline.png. The two image files are the icons for your app in Teams. If the names of the .png files differ, be sure to update the file names to match in the manifest file.
- Name this package OpenBadges.zip.
- Make sure that the 3 files are the top level of the ZIP package, with no nested folders.
-
If your tenant has sideloading apps enabled, you can install your app by following the instructions here
-
You can also upload it to your tenant's app catalog, so that it can be available for everyone in your tenant to install. See here
-
Install the end-user app (the OpenBadges.zip package) to your users.
Please see our Troubleshooting page.