Who has helped you recently? When did you last send them a praise / kudos / etc.?
On a monthly basis I lead a team retrospective for our Microsoft Graph CPx team. I generally adjust the questions each month so that we don’t keep repeating the same questions / responses each month.
This month, as part of our retrospective I posed the questions at top of this post.
Who has helped you recently?
When did you last send them a praise / kudos / etc.?
While everyone was able to identify people or teams that have helped them, responses to the second question varied from “I send perspectives feedback / praise regularly to X, Y, and Z” to “I haven’t sent anything to those people in awhile, thanks for the reminder”.
Personally, in addition to my monthly personal retrospective I also schedule time (~15 mins) on my calendar each month to send out praise to people that have helped me recently. Case in point, as we’re wrapping up this calendar year I just filled out 3 perspectives feedback requests before writing this post.
I encourage everyone to make a habit (schedule recurring time on your calendar, set a repeating ToDo reminder, etc.) of:
identifying people that have helped you in the last week / month
send those people a thank you / praise / kudos
How are you expressing your gratitude to others that have helped you?
Do you ever want to test a few lines of code, but have to write dozens of lines of support code (i.e. “boilerplate” or “basic plumbing” code)?
Microsoft Graph has a number of offerings such as quick starts to let you pick a supported code language, download a sample application, and run the project within a few minutes, but this can still take 5-30 mins depending on your level of familiarity.
Separately, there is Microsoft Graph Explorer or the Microsoft Graph Postman collection to quickly execute a query against Microsoft Graph (seconds to minutes usually), but these only execute HTTP REST endpoints and not using SDKs (which I prefer).
I’ve used 3rd party tools such as LINQPad or websites like .Net Fiddle to quickly prototype and execute Microsoft Graph SDK code but these are often disconnected experiences from where I typically develop which is Visual Studio Code.
.Net Interactive and Polyglot Notebooks
Enter .Net Interactive. .Net Interactive builds upon the Jupyter ecosystem (notebooks, kernels, server, etc.) to allow programming in a notebook fashion (executable code alongside text) but with support for multiple languages (C#, F#, JavaScript, PowerShell, SQL, and more). With this added support for multiple languages, the Visual Studio Code extension has been recently renamed to Polyglot Notebooks (previously called .Net Interactive Notebooks), but the base engine itself is still called .Net Interactive.
At a base level, Polyglot Notebooks allow you to write snippets of executable code in multiple languages alongside markdown text blocks. This is great for writing tutorials, sharing a sample of code with someone with explanation (beyond simple comments in the code), or designing a multi-step process of code blocks.
.Net Interactive is also extensible by allowing developers to create custom kernel extensions, magic commands, or script-based extensions.
Microsoft Graph extension for .Net Interactive
During a recent company hackathon event, myself, Jason Johnston, Jon Sequeira, and Diego Colombo built an initial prototype of a Microsoft Graph extension for .Net Interactive. The extension implements a magic command for #!microsoftgraph that can create and authenticate a GraphServiceClient and then binds it to a variable that can then be used in code blocks. The magic command accepts input parameters to control authentication flow, Azure AD application / tenant, Microsoft Graph API version, and more. The current repository includes support for C# (.Net) but we’re also exploring JavaScript and PowerShell in the future.
Prerequisites
There are a few prerequisites that you will need install
After above requirements are met, you can get started by following the instructions in the GitHub repo README or the demo notebook.
Let’s take a look at a few samples.
Create a polyglot notebook
To create a new polyglot notebook, open the Command Palette(Ctrl+Shift+P) on Windows or (Cmd+Shift+P) on MacOS, and select Polyglot Notebook: Create new blank notebook. You can also create a new notebook with Ctrl+Shift+Alt+N key combination on Windows.
Build the NuGet package
After forking the repository, navigate to the source directory and run the following command (or execute in a PowerShell code block inside the notebook) to generate a NuGet package which we will then import in the next steps.
After the NuGet package has been built, run the following commands (be sure to replace <REPLACE_WITH_WORKING_DIRECTORY> with the actual directory location) in a C# script block in the notebook to import the NuGet package.
Executing the #!microsoftgraph magic command with -h or –help will display the syntax and parameters available for input. Note that options are available with full name (two dashes “–“) or aliases (one dash “-“).
#!microsoftgraph -h
Create client
The following creates an instance of a GraphServiceClient with variable name “deviceCodeClient” using the device code authentication flow. Be sure to replace the input parameters for “YOUR_TENANT_ID” and “YOUR_CLIENT_ID”.
#!microsoftgraph -t "YOUR_TENANT_ID" -c "YOUR_CLIENT_ID" -a DeviceCode -n deviceCodeClient
Since we used -n to name the GraphServiceClient instance that is created, we can now use that variable going forward to make requests.
Make requests
Now you can execute Microsoft Graph .Net SDK code using the deviceCodeClient GraphServiceClient just created. We will be prompted to complete the device code authentication flow at this time. Follow the prompt and provide the device code provided.
var me = await deviceCodeClient.Me.GetAsync();
Console.WriteLine($"Me: {me.DisplayName}, {me.UserPrincipalName}");
Live demo
Recently Jason Johnston and I joined the M365 platform community call to give an overview and demo of the Microsoft Graph extension for .Net Interactive. If you want to skip to just the demo, jump to 8:28 timestamp in the video to see things in action.
Conclusion
As you can see, the Microsoft Graph extension for .Net Interactive offers a way to write code and text side by side. There are many scenarios that can benefit from this such as workshop tutorials, exploring the SDKs, prototyping solutions, and more. We welcome your input on feature requests, contributions, raising bugs, etc. Please submit issues or pull requests to the GitHub repository and we will review. Thanks and enjoy!
When I joined the Microsoft Graph team I set up recurring 1:1 meetings with each of my teammates and a number of people from other teams within our group. As luck would have it those meetings defaulted to have an end date ~1 year from when the series was created.
As you might guess, I forgot to extend some of those meetings and then after they reached their end date I had to go through my calendar to find which ones were impacted and extend them.
<Update 2023-02-02>I confirmed with the PM for this endpoint that the Recurrence property does not support filtering at this time. As such you will need to filter client-side through your own means.</Update>
The below query is intended to find all recurring meetings on your Exchange Online calendar. It is not a complete solution as I haven’t figured out the exact syntax for recurrence property with an end date in the past. Hopefully someone finds this useful and if you have enhancements to help with filtering please feel free to share in the comments.
Note that type = ‘seriesMaster’ will only find the series and not individual meeting instances which may have exceptions from the original recurrence pattern.
Similar to my recent post about “share early and share often” I also encourage others that are creating things (documents, videos, blog posts, digital artwork, etc.) to make them “linkable”. Let me describe what I mean and why it is important.
If you create a document for a new project specification and then store it on the desktop of your computer, how would you go about sharing that document to a coworker?
You could email / FTP / etc. the full file, but now when you make changes how do they get those changes? Instead, if you share the document to a cloud storage location and then send them a link, now they have access to the latest version.
In a similar way, when I have an idea that I want to share with others (like this post) I’m putting it in a location (Yammer, my blog, cloud storage, etc.) that I can easily link to and share with others. Same goes for tips and tricks videos that I’ve posted to TikTok.
Conclusion
By making things I create “linkable”, now the next time a topic comes up in conversation, I can quickly grab the link and share with others.
I’ve always enjoyed “Show and Tell Fridays”, “Brown bag sessions” (i.e. bring your lunch and a presenter shares about a topic), and hackathons to see what cool things my peers are working on. Not only do I get to see / hear interesting projects and solutions they are building, it also sparks creativity in me to work on my own projects.
During our September 2022 company-wide hackathon I had the opportunity to collaborate with folks from multiple areas of Microsoft (Teams, Outlook, .Net Interactive, M365 Profile, and more) on interesting projects. What was really interesting to me is that 2 of these projects started via tweets on Twitter. A random message from myself was picked up by one engineering team for 1 project and a thread from a peer about “wouldn’t it be cool if…” started another project.
Ultimately, I highly recommend that you take the time to share early and share often your ideas, interests, side projects, and more. You never know how that may lead you and your peers to build the next innovative product / feature / etc.
For those interested, here is a link to one of the hackathon projects I worked on for a “Microsoft Graph extension for .Net Interactive”. For those unfamiliar, .Net Interactive Notebooks allow you to mix text (Markdown) and runnable code snippets (multiple languages supported) in a notebook style format. This custom extension allows authenticating to Microsoft Graph via 3 different authentication flows (possibly more to come) and run Microsoft Graph SDK queries easily.
I’ll be sharing more about this on my blog, M365 platform community call, and a few other places as it continues to develop. For now follow / star / fork / etc. the GitHub repo for more updates.
Starting July 1st of this year I set some goals for myself to get back into exercise routines and improve my overall health. Many of these are things that I had done before the pandemic but had not gotten back into.
Walk / run 4-mile (6.4 km) race before end of 2022
Workout for at least 10 mins a day, 4 days a week
Lose 10 pounds (4.5 kg) by end of 2022
Rather than dive head-first into these goals, I made small adjustments to my daily / weekly schedule and continued adding every few weeks, but always being consistent.
Much of the inspiration for this approach came from the book Atomic Habits by James Clear which I read earlier this year.
Installed a phone app for “core body workouts” that I use for 10-15 mins in the morning
I didn’t have high hopes for the app but here I am 40+ days later making real progress, repeating 3 days on and 1 day off for rest (even through vacations with family).
Walk on my home office treadmill at least 2-3 times a week
I now don’t let myself watch nighttime TV unless I’m walking on the treadmill. This motivates me to walk longer but also avoid eating unhealthy foods after dinner.
Reduce after hours snacking
This used to be a frequent problem, but with the other areas I’m seeing results with losing 7 pounds (3.2 kg) already, and I’m motivated to not gain that back by eating unhealthy foods.
Signed up for a 4-mile race in Oct
I’m already registered and working my way up in distance (see above for nighttime TV motivator for compounding effect).
Progress started out small and slow with the workouts, but overall I’m feeling in much better shape and plan to keep this up through the rest of the year. I enjoy that it was small adjustments that started to compound the gains I was seeing across the board.
What positive habits have you started up this year that have made an impact?