SlideShare a Scribd company logo
Microsoft Graph API and
OutSystems
Delegated Permissions
Access Microsoft Cloud Services via Graph API in
OutSystems
December 13th 10am (CET)
Stefan Weber
Senior Director Software Development
Telelink Business Services Germany GmbH
OutSystems MVP – AWS Community Builder
Fundamentals
ď‚§ Quick Recap of Part 1
ď‚§ OAuth 2.0 Authorization Code Flow
ď‚§ Application Sign In vs Account Linking
ď‚§ Elements we need to build
Agenda
Implementation
ď‚§ Prerequisites
ď‚§ Register an application with Microsoft Identity Provider
(Entra ID)
ď‚§ Build an Authorization Code Flow for Application Sign In
ď‚§ Consume Graph API endpoints with OutSystems
OAuth 2.0
Authorization Code Flow
The OAuth 2.0 Authorization Code flow is designed for
applications to access a service API on-behalf of a user.
This flow requires the user to be redirected to the identity
provider to authenticate, after which they are redirected back to
the application with an authorization code. This code is then
exchanged for an access token by the application backend using
a client secret.
Authorization Code Flow with Proof Key Exchange (PKCE) is
originally designed for applications that cannot securely store a
client secret but will be mandatory in OAuth 2.1
OAuth 2.0 Authorization Code Flow - Tokens
Access Token
An OAuth 2.0 Access Token is a
credential used to access protected
resources on behalf of a resource
owner.
Issued by the authorization server, it
represents the grant of access given
to a client application.
This token does not contain
information about the user's identity;
instead, it is used to access APIs
securely.
OpenID Connect Token
This token contains claims about the
authentication of an end user and is
a JSON Web Token (JWT) that
includes information such as the
user's identity, the authentication
method used, and the token's validity
period
Refresh Token
An OAuth 2.0 refresh token is a
special kind of token that is used to
obtain a renewed access token when
it expired or became invalid.
The refresh token is used to securely
request a new access token without
requiring the user to go through the
authentication process again.
Refresh tokens are particularly useful
in applications that need to maintain
long-term access to a user's
resources hosted by a service
provider.
Application Sign In vs Account Linking
Sign In
A user authenticates himself via an external, OAuth 2.0-
compatible identity provider and is authorized as a user in
OutSystems.
Link Account
A user logs into OutSystems and then connects one or more
external accounts of applications that use an OAuth 2.0
compatible identity provider for authentication.
Implementation
Prerequisites
ď‚§ Access to your Azure Tenant using the Azure Portal
ď‚§ Cloud Application Administrator role assigned to your user
account to register an application in your tenant.
Building Blocks
Authentication Request
Creates a new Authentication intent,
constructs an Authorization Url and
redirects the users browser.
Callback Handler
Retrieves the authorization code
from the Identity Provider after
successful authentication. (Screen or
exposed REST API)
Token Cache
Caches access and refresh tokens for
later retrieval.
Token Handler
Retrieves an access token from the
token cache directly or performs a
token refresh.
Calls
{authorizationUrl}?
client_id={clientId}
&response_type=code
&redirect_uri={redirectUrl}
&response_mode=query
&scope=openid%20offline_access%20{scopes}
&state={state}
{redirectUrl}?
code={code}
&state={state}
&error={error}
&error_description={errorDescription}
{tokenEndpoint}
Content-Type: application/x-www-form-urlencoded
client_id={clientId}
&scope=openid%20offline_access%20{scopes}
&code={authorizationCode}
&redirect_uri={redirectUrl}
&grant_type=authorization_code
&client_secret={client_secret}
{tokenEndpoint}
Content-Type: application/x-www-form-urlencoded
client_id={clientId}
&scope=openid%20offline_access%20{scopes}
&refresh_token={refreshToken}
&grant_type=refresh_token
&client_secret={client_secret}
Redirect Callback
Exchange Code Refresh Token
Walkthrough
ď‚§ Master OAuth 2.0 Website
ď‚§ Microsoft Developer Program
ď‚§ Azure Portal
 Microsoft Learn – Authorization Code Flow
ď‚§ Use the Microsoft Graph API documentation
ď‚§ Microsoft Graph Permission Reference
ď‚§ Microsoft Graph Explorer
ď‚§ OAuth Token Exchange Forge component
ď‚§ CryptoAPI Forge component
Additional Material
ď‚§ Acquire and Link multiple OAuth Tokens to OutSystems
users for delegated access
 Getting started with OutSystems and Microsoft Graph—
Delegated Permissions
Coming up
Subscribe to Microsoft Graph API events
ď‚§ How to subscribe to individual events offered in Graph API.
ď‚§ How to securely consume triggered events in OutSystems.
ď‚§ How to refresh subscription authorization.
When?
January 2024
Stefan Weber
Senior Director Software Development
Telelink Business Services Germany GmbH
OutSystems MVP – AWS Community Builder
https://www.tbs.tech
https://www.linkedin.com/in/stefanweber1/
https://lcnc.blog

More Related Content

PPTX
Microservice security with spring security 5.1,Oauth 2.0 and open id connect
PPTX
Microsoft Graph API Webinar Application Permissions
PDF
Deep Dive into OAuth for Connected Apps
PDF
Introducing OpenID 1.0 Protocol: Security and Performance
PDF
Stateless Auth using OAUTH2 & JWT
PDF
OAuth2 primer
PPTX
OAuth2 and OpenID with Spring Boot
PDF
A Survey on SSO Authentication protocols: Security and Performance
Microservice security with spring security 5.1,Oauth 2.0 and open id connect
Microsoft Graph API Webinar Application Permissions
Deep Dive into OAuth for Connected Apps
Introducing OpenID 1.0 Protocol: Security and Performance
Stateless Auth using OAUTH2 & JWT
OAuth2 primer
OAuth2 and OpenID with Spring Boot
A Survey on SSO Authentication protocols: Security and Performance

Similar to Microsoft Graph API Delegated Permissions (20)

PDF
Stateless Auth using OAuth2 & JWT
PPTX
Oauth2 and OWSM OAuth2 support
PDF
#5 WSO2 Masterclassitalia - WSO2 Identity Server, un approccio OAUTH2
PDF
OpenID Connect Explained
PPTX
OAuth 2.0 - The fundamentals, the good , the bad, technical primer and commo...
PDF
Intro to API Security with Oauth 2.0
PPTX
OAuth 2
PPTX
OAuth with Salesforce - Demystified
PDF
Lecture #25 : Oauth 2.0
PDF
SAML VS OAuth 2.0 VS OpenID Connect
PDF
OAuth 2.0 and OpenID Connect
PDF
Authentication through Claims-Based Authentication
 
PPTX
OAuth2 + API Security
PPTX
Intro to OAuth2 and OpenID Connect
PDF
.NET Core, ASP.NET Core Course, Session 19
PDF
Protecting your APIs with OAuth 2.0
PPTX
OAuth in the Wild
PDF
REST API Authentication Methods.pdf
PDF
Demystifying OAuth 2.0
PDF
O auth2.0 guide
Stateless Auth using OAuth2 & JWT
Oauth2 and OWSM OAuth2 support
#5 WSO2 Masterclassitalia - WSO2 Identity Server, un approccio OAUTH2
OpenID Connect Explained
OAuth 2.0 - The fundamentals, the good , the bad, technical primer and commo...
Intro to API Security with Oauth 2.0
OAuth 2
OAuth with Salesforce - Demystified
Lecture #25 : Oauth 2.0
SAML VS OAuth 2.0 VS OpenID Connect
OAuth 2.0 and OpenID Connect
Authentication through Claims-Based Authentication
 
OAuth2 + API Security
Intro to OAuth2 and OpenID Connect
.NET Core, ASP.NET Core Course, Session 19
Protecting your APIs with OAuth 2.0
OAuth in the Wild
REST API Authentication Methods.pdf
Demystifying OAuth 2.0
O auth2.0 guide
Ad

Recently uploaded (20)

PDF
Internet Downloader Manager (IDM) Crack 6.42 Build 42 Updates Latest 2025
PPTX
Operating system designcfffgfgggggggvggggggggg
PPTX
Odoo POS Development Services by CandidRoot Solutions
PDF
How to Choose the Right IT Partner for Your Business in Malaysia
PDF
top salesforce developer skills in 2025.pdf
PPTX
Transform Your Business with a Software ERP System
PPTX
Agentic AI : A Practical Guide. Undersating, Implementing and Scaling Autono...
PDF
Design an Analysis of Algorithms II-SECS-1021-03
PPTX
ManageIQ - Sprint 268 Review - Slide Deck
PDF
System and Network Administration Chapter 2
PDF
medical staffing services at VALiNTRY
PDF
Which alternative to Crystal Reports is best for small or large businesses.pdf
PDF
Navsoft: AI-Powered Business Solutions & Custom Software Development
PPTX
ISO 45001 Occupational Health and Safety Management System
PPT
Introduction Database Management System for Course Database
PDF
Softaken Excel to vCard Converter Software.pdf
PDF
How to Migrate SBCGlobal Email to Yahoo Easily
PPTX
Introduction to Artificial Intelligence
PDF
Claude Code: Everyone is a 10x Developer - A Comprehensive AI-Powered CLI Tool
PDF
Flood Susceptibility Mapping Using Image-Based 2D-CNN Deep Learnin. Overview ...
Internet Downloader Manager (IDM) Crack 6.42 Build 42 Updates Latest 2025
Operating system designcfffgfgggggggvggggggggg
Odoo POS Development Services by CandidRoot Solutions
How to Choose the Right IT Partner for Your Business in Malaysia
top salesforce developer skills in 2025.pdf
Transform Your Business with a Software ERP System
Agentic AI : A Practical Guide. Undersating, Implementing and Scaling Autono...
Design an Analysis of Algorithms II-SECS-1021-03
ManageIQ - Sprint 268 Review - Slide Deck
System and Network Administration Chapter 2
medical staffing services at VALiNTRY
Which alternative to Crystal Reports is best for small or large businesses.pdf
Navsoft: AI-Powered Business Solutions & Custom Software Development
ISO 45001 Occupational Health and Safety Management System
Introduction Database Management System for Course Database
Softaken Excel to vCard Converter Software.pdf
How to Migrate SBCGlobal Email to Yahoo Easily
Introduction to Artificial Intelligence
Claude Code: Everyone is a 10x Developer - A Comprehensive AI-Powered CLI Tool
Flood Susceptibility Mapping Using Image-Based 2D-CNN Deep Learnin. Overview ...
Ad

Microsoft Graph API Delegated Permissions