How to Integrate
Blockchain
Technology into Your
Applications
Juarez Barbosa Junior
Azure Developer Advocacy Lead, Blockchain
Developer Advocate – Microsoft Western Europe HQ
juarez.junior@microsoft.com @juarezjunior
Juarez Barbosa
Junior
• Azure Developer Advocacy Lead
• Blockchain Expert
• Past roles
• Developer Advocacy & Strategy Director,
Oracle EMEA
• IBM Watson Evangelist
• IBM Mobile Thought Leader & Evangelist
• Software / Solutions Architect & Engineer
• Passionate about Emerging Techs, Blockchain,
Cloud, Programming Languages
• Working in IT industry 20+ Years
Image
Microsoft Tech X
https://aka.ms/TechXDublin
Don’t forget to add Microsoft Azure skill to your
LinkedIn account to stay connected with our
developer community in Ireland!
Image
•
•
•
•
Types of blockchain networks
Consortium
Woodgrove
Financial
Contoso
Bank
Northwind
Traders
Bank b
Insurance c
Investment
consortium
c
Bank A
Blockchain
Location 1
Location 2
Location 3
Location 4
Department
A
Department
B
Public
blockchain
Person a
Woodgrove
Financial
Person B
Northwind
Traders
Bank 6
Bank 1
Consortium
6
Public
(permissionless)
Consortium
(permissioned)
Private
• Many, unknown participants
• Writes by all participants
• Reads by all participants
• Consensus by Proof of Work
• Known participants from one org
• Write permissions centralized
• Reads may be public or restricted
• Multiple algorithms for consensus
• Known participants from multiple orgs
• Writes require consensus of n participants
• Reads may be public or restricted
• Multiple algorithms for consensus
Corda
Chain
Enterprise
Ethereum Quorum
P
Image
Transaction 0
Transaction 1
Transaction 2
Transaction 3
Transaction 4
New Hash
+
Block0 Hash
First Hash
New Hash
+
Block1 Hash
New Hash
+
Block2 Hash
Node 1
Node 7
Node 4
Node 5
Node 2
Node 3
Node 0
Node 6
First Hash
Node 1
Node 7
Node 4
Node 5
Node 2
Node 3
Node 0
Node 6
Node 1
Node 7
Node 4
Node 5
Node 2
Node 3
Node 0
Node 6
Node 1
Node 7
Node 4
Node 5
Node 2
Node 3
Node 0
Node 6
Node 1
Node 7
Node 4
Node 5
Node 2
Node 3
Node 0
Node 6
Transaction 0
Transaction 1
New Hash
+
Block0 Hash
Node 1
Node 7
Node 4
Node 5
Node 2
Node 3
Node 0
Node 6
Transaction 2
Transaction 3
Transaction 4
New Hash
+
Block1 Hash
Image
Business has always been built on trust
Seller’s Agent
Land Registry
Buyer
Lending Bank
Property Purchase
Property
Inspector
Appraiser
Insurer
Source
materials
Freight
Manufacture
and assembly
Quality
Inspection
Retailer
Financing
Consumer
Industrial Supply Chain
Inspection Company
Issuing Bank
Importer
Exporter
Adviser Bank Shipping Company
Trade Finance
And losing it can have serious consequences
69% of CEOs claimed
their #1 priority over the
last 12 months was to
ensure their company
is trusted
40% of credit card
holders surveyed
reported loss of trust in
Equifax post a massive
data breach
77% of organization
suppliers don’t have
strong transparency and
visibility across the
supply chain
The truth is there is a
high cost to a bad
reputation.
DARA KHOSROWSHAHI, UBER
Our reputation is more
important than the last
hundred million dollars.
RUPERT MURDOCH
Existing methods of managing trust create friction
and cost
Intermediaries
increase cost and reduce
direct contact with consumers
Manual verification
is time-consuming
and error-prone
Blockchain streamlines the way trust is established
Asset
Health
Government
Retail
Banking and
Capital Markets
Insurance
Manufacturing
Enterprise
Cryptocurrency
Blockchain
Loyalty tracking
Product provenance
Logistics management
Digital rewards
P2P selling
Ticket purchases
Asset tracking
Real-time auction for
supplier contracts
Supply chain
transparency
Dynamic commodities
pricing
Claims management
MBS/Property payments
Fraud detection
Automated underwriting
Risk visualizations
Licensing and ID
Benefits distribution
Aid tracking
Military security
Copyrights
Audit compliance
Bond issuance
Trade finance
Loan syndication
Post trade settlement
Global payments
Derivatives trading
KYC/AML
Personalized medicine
Records sharing
Compliance
Agricultural
authentication
Pharmaceutical purity
Manufacturing Retail Insurance Government
Banking and
Capital Markets
Health
And has applications across industries
Asset Transfer Provenance Cross-Organizational Workflow High Assurance Audit
Keystone Research estimated up to
$100B of technology value capture in
the US alone across industries​
Gartner forecasts the total business
to value of blockchain to be
$176B by 2025, $3.1T by 2030
Digitizing business processes will deliver massive
business value
Reduce security threats from fraud,
hacking, and data manipulation
Mitigate Risk
Use a shared data source for
transparency across organizations
and increased end-to-end speed
Increase Speed
Remove friction and allow direct
interaction between parties
Reduce Cost
Image
Building from scratch is a huge undertaking
Choose
your ledger
Write smart
contract
Manage node
health
Build the
network
Manually
deploy ledger
Write
business logic
Assign node
identities
Connect
nodes
Provision
members
Network
governance
Extend to
additional
networks
Manage
permissions
Establish
node roles
Enforce
policies
Customize
integrations
Microsoft breaks blockchain down to the essential steps
Launch and manage the
network
Model smart contracts Build and extend the
application
Microsoft has the best cloud for blockchain
Analysts place us ahead of the competition
Our open, app-focused approach has been
validated by Gartner, Forrester and many other
third-party analysts
We have designed a thoughtful product portfolio
We have spent 4 years developing the most open
and comprehensive blockchain portfolio to simplify
development of this new class of apps
Customers and partners trust us
Businesses have built thousands of blockchain apps
on Azure working with our rich ecosystem of
blockchain partners ​
And a comprehensive set of tools and services
for developers
Launch and manage
the network
Build, deploy, and
manage blockchain
networks
Model smart contracts
VS Code
Author and test
smart contracts
Azure Blockchain
Service
Build and extend the
application Dev Kit
Extend your app
and move to
production
Workbench
Prototype your
application
Build and extend a new class of applications
Sensors
and IoT
(unstructured)
Ingest Transform Attest Read & Route
Apps
Transaction
Builder
Logs
(unstructured)
Service Bus
Project WestlakeMedia
(unstructured)
Files
(unstructured)
Business/
custom apps
(structured)
Power BI
Azure IoT Hub
Application InsightsAzure Key Vault Virtual NetworkingAzure AD
DLT Watcher
Power Apps
Event Grid
Flow Cloud
Database
Off-chain
storage
Off-chain
database
Azure
Development Kit
Image
Customers and partners are building blockchain apps on
Azure
PARTNERS CUSTOMERS
Starbucks empowers each
member of its supply chain
Over the next two years, we will look to demonstrate
how technology and innovative data platforms can
give coffee farmers even more financial empowerment
— Kevin Johnson
Starbucks CEO
Challenge • Starbucks needed increased visibility into the movement of
beans across its vast supply chain
• 97% of farmers are small hold/one-acre farms that have
difficulty scaling production to meet demand
Solution • Use blockchain based smart contracts to define the
responsibilities of each supply chain participant and record
their activities
• Provides immutable proof-of-end purchase to farmers
enabling access to higher quality credit
• Monitor the movement of beans from farm to pour using a
shared, cloud-based app
And reinforces trust from farmers to customers
Farmers
Starbucks Customers
Farmers are financially empowered…
• Understand downstream movement of their
product and better forecast demand
• Receive immutable “proof-of-end purchase”
from Starbucks
• Establish creditworthiness to access higher
quality credit and expand operations
Starbucks receives
immutable record of…
• Bean provenance
• Inventory state changes and
movement
Customers enjoy
increased transparency…
• Into the individual region
• The farm origin of the coffee
• Tactics used to farm
their high-end coffee
Using blockchain to reinforce trust from farmer to customer
Carrier
Authenticity is verified and beans
are delivered to the factory
Customer
At purchase can view certifications,
origin, and other quality details with
assurances from farm to pour
Manufacturer
Containers are verified and
coffee is processed and
bagged
Small Hold Farmer
Produce coffee beans under specified conditions
to earn organic and Fair Trade certifications.
Receive “proof of end purchase” from Starbucks
they can use to access credit for next years
harvest
Retailer
The bags reach the retailer having been
accounted for at each step of the journey
Farmer
✓ Plot #839049
✓ 25 tons of cocoa beans
✓ Certifications
Carrier
✓ Shipped 2/5/2018
✓ Organic
✓ Fair Trade
Manufacturer
✓ Delivered 2/12/2018
✓ Organic
✓ Fair Trade
Distributor
✓ Delivered 2/19/2018
✓ Organic
✓ Fair Trade
Retailer
✓ Delivered 2/26/2018
✓ Organic
✓ Fair Trade
Customer
✓ Guaranteed fresh
✓ Certified organic
✓ Certified Fair Trade
At various points in the journey, an IoT device scans the product and records its status and condition which are updated on the blockchain
Quality attestationProof of Purchase Consumer visibility
Distributor
The coffee is moved through distributor network
under high-quality assurance regulations
Singapore Airlines | Expand customer loyalty
Challenge
Singapore Airlines wanted to improve customer
participation and loyalty by streamlining their
rewards program
Strategy
Singapore Airlines partnered with KPMG Digital
Village and Microsoft to build a blockchain-
based rewards program that linked their digital
wallets to their KrisFlyer reward miles
Results
• Empowered customers to easily use their
KrisFlyer miles for point-of-sale transactions on
an expanded retail partner network
• Increased mileage program participation and
loyalty to the Singapore Airlines brand
“This groundbreaking development in which we will be using blockchain technology to ‘digitalise’
KrisFlyer miles is a demonstration of the investment we are making to significantly enhance the digital
side of our business for the benefit of our customers”
— Goh Choon Phong, Chief Executive Officer of Singapore Airlines
Blockchain in Action | Partner network management
Digital wallet
Reward points are stored in
the customer’s digital wallet
Partner retail location
Customers are able to redeem loyalty
points for goods and services from any
retail location in the partner network
SHARED LEDGER
Update: SFO → HKG: 7,000 miles
• Dec 2016 LAX → ICN: 6,000 miles
• Jan 2015 IAH → DME: 5,000 miles
• Jun 2015 JFK → FRA: 4,000 miles
• 7,000 miles = 700 points
• 6,000 miles = 600 points
• 5,000 miles = 500 points
• 4,000 miles = 400 points
• 2,200 points redeemed for:
o Free stay at hotel A
o Admittance to airport lounge B
o Spa treatment at resort C
Contract
updated
Contract
updated
Mobile app
Customers purchase their
ticket on their mobile device
Contract
created
Awarded miles
Each flight is worth miles that
are converted to rewards points
Contract
updated
XBOX | Blockchain for royalty payments
Challenge
Microsoft wanted to replace the complicated,
manual royalty calculation process used to pay
XBOX publishers with a faster, more efficient
approach
Strategy
Microsoft developed a blockchain-based
solution that automated processes to offer XBOX
royalty information in near real time while
maximizing security and transparency
Results
• Improved trust by making the royalty payment
calculation process more transparent for
publishers
• Gave publishers actionable business insights,
enabling them to proactively respond to
customer demand
• Reduced XBOX process efforts by two thirds
and saved publishers time by eliminating the
need for manual audits
“We are developing an ecosystem within the gaming industry that connects developers and publishers
to game performance. Providing near real-time access to data greatly improves the process’
effectiveness and insights that lead to a more enriching experience for the partners.”
— Tim Stuart, Chief Financial Officer of Xbox
• Game Purchased
• Publisher ID
• Price
• Customer Age
• Customer Gender
• Location
CONTRACT CREATED
CONTRACT VISIBILITY
• Top Grossing Content
• Publisher Royalty
• Publisher Demand
• Net Revenue
Blockchain in action | Manage royalty payments
XBOX Platform
SHARED LEDGER DATA
CONTENT PUBLISHER A VISIBILITY
• Customer ID
• Content Dev ID
• Licensing ID
• Marketing ID
• Distributor ID
• Content Provider ID
Publisher C
• Customer ID
• Content Dev ID
• Licensing ID
• Marketing ID
• Distributor ID
• Content Provider ID
Publisher B
• Customer ID
• Content Dev ID
• Licensing ID
• Marketing ID
• Distributor ID
• Content Provider ID
Publisher A
Content Publishers
Gain visibility into sales
data and royalty revenue,
enabling them to make
near real time decisions.
$
$
$
$
$
Licensing
Marketing
Distribution
Content
Provider
Content
Developer
$12.99
$59.99
$3.99
Media
Purchase
Movie
Video game
Song
Quantity
Quantity
XBOX Platform
Consumers purchase digital content
through the XBOX platform. The
data then is written to the shared
ledger. This automatically makes
royalty data visible to the XBOX
publishers.
XBOX PAYS
ROYALTIES
Media Sale: July 13th
XiaoMi | Supply Chain Finance Service
Challenge
XiaoMi works with a broad ecosystem of
partners and suppliers that lacked the
connectivity and transparency needed to scale
trust and quickly verify credit for banking and
factoring
Strategy
XiaoMi worked with Microsoft to streamline trust
on a shared, blockchain-based data layer that
easily connects with the apps and systems used
throughout their ecosystem
Results
• Improved cash efficacy by digitizing credit
establishment
• Shortened the timeframe of factoring and
banking processes from weeks to days
• Expanded the business network for multi-layer
supply chain hierarchy with minimal IT efforts
“Our partners and suppliers form an important ecosystem that we want to continue to grow, so our
digital transformation couldn’t just improve our products, services, and operations—it needed to build
a platform of trust, transparency, and efficacy for our partners and suppliers as well.”
— TBD
Blockchain in action | Supply Chain Finance service
Shared ledger data
SRM App
Core Enterprise
SAP ERP System
BPM App
Approval
Bank C, Supplier 3, …
• Transaction Stages
-> CreatePO, …
• Events/Logs
• Entities
-> PO, ASN, GR
-> FA, Payments
Bank B, Supplier 2, …
• Events/Logs
• Transaction Stages
-> CreatePO, …
• Entities
-> PO, ASN, GR
-> FA, Payments
Provider ID
Bank A, Supplier 1, …
• Transaction Stages
-> CreatePO, …
• Events/Logs
• Entities
-> PO, ASN, GR
-> FA, Payments
Create
ASN
Create
GR
Pay for
FA
Pay for
Payment
-Sheet
Create
PO
Supply chain data is shared
on the blockchain to
inform POs, ASNs, GRs,
FAs, and Payments
Workflow Group visibility
Contracts visibility
• In all workflow groups
• Workflow initiator
• Owners configuration
• Roles configuration
Core Enterprise
• Supplier, Bank, Core-
Enterprise group set up with
owners, observers
• Shared transactions and
Shared entities are
independent smart contracts
Contracts created
Suppliers
Banks and
SCF System
Bühler | Ensuring food
safety
We’re not only going to get economic results, but
hopefully we can transform and save lives at the same
time. It’s the most exciting and valuable project I’ve
worked on in my 40 years with the company.
It’s a really big thing.
— Ben Deefholts
Senior Research Engineer
Challenge • A lack of connectivity, transparency, and traceability in the
food supply chain caused food waste and inefficiencies.
• 25% of all harvested grain is contaminated with mycotoxins
and nearly half a billion people are at risk of consuming
aflatoxin contaminated crops.
Solution • Buhler and Microsoft developed a blockchain strategy to
track grain and ensure it’s handled according to regulations.
• Augmented physical machines with an AI-enabled insights
platform to ensure all grains processed are toxin-free
Results • Digitally verify that all grains are handled compliantly as they
move through the supply chain, providing transparency to
each counterparty through a shared ledger.
• Assess any contamination and alert all parties in real-time to
avoid a public safety issue.
• Create a shared food-safety utility for the agricultural
industry that could guarantee crop safety from farm to fork
Bühler | Ensuring food safety
Carrier 1
The product is securely shipped and
handled per manufacturer’s
regulations and compliance
standards
Miller
The grains are milled and must be
handled per manufacturer’s regulations
and compliance standards
Granary
The grains are stored per
manufacturer’s regulations
and compliance standards
Retail store
Rejects the pasta products sent by food
processor A due to poor handling procedures
Harvest
The grains are harvested and
assessed for contaminants.
The remaining grains are then
packaged for shipment.
Food processors
Transform the grains
into packaged goods for
consumption per
manufacturer’s
regulations and
compliance standards
A
B
C
Smart contract
created
Grain needs to be
harvested and
shipped.
Carriers
• Grains
delivered
• Compliant
handling
Granary
• Grains
stored
• Compliant
handling
Miller
• Grains
milled
• Compliant
handling
Food processors
A: Pasta products
B: Bread products
C: Rice products
Retail store
A: Rejected – non-
compliant handling
B: Accepted
C: Accepted
Harvest
• 25% of grains
have toxins
• 75% of grains
are shipped
Food processor A has breached the contract and
is liable for penalty
25% of grains are
found to have toxins
and are rejected.
SHARED LEDGER
Interswitch | Seamless
supply chain financing
Armed with a single version of the truth across the supply
chain, Nigerian lenders and suppliers can identify and
build relationships with high performing entrepreneurs.
That will help empower people to create more jobs, more
wealth, and a more prosperous Africa.
— Eghosa Ojo
Designer Thinker and Head of Innovation at Interswitch
Challenge • To bridge the gap between the existing corporate-based
financing infrastructure in Nigeria and a growing number of
small to mid-size enterprises in need of capital.
• Supply chain financing involves multiple counter-parties who
lack end-to-end visibility, exposing lenders to risk, delaying
financing, and jeopardizing projects.
Solution • Interswitch partnered with Microsoft to develop a
blockchain-based supply chain financing service that brings
together major financial institutions from different countries
to seamlessly manage trade finance.
Results • Banks reduce their exposure to loss or fraud and streamline
financing decisions, giving more people access to more
funding, while lenders can deliver more value.
• Borrowers now secure financing in three weeks or less, so
they can take on more work in less time.
• Project contractors and suppliers can better predict
requirements, accelerate turnaround, and increase sales
cycles and volumes.
Interswitch | Seamless supply chain financing
Contract updated
• The supplier receives
the guarantee and
fulfills the purchase
Contract updated
• Entrepreneur
receives the
supplies
Contract updated
• Bank and the
supplier agree on
guarantee terms
Smart contract created
• Entrepreneur submits a
purchase order to a
supplier
Supplier
Requires a bank
guarantee for the
purchase
Entrepreneur
Submits a
purchase order
to the supplier
Supplier
Receives the
guarantee and
fulfills the order
Entrepreneur
Receives
supplies
Bank Admin
Creates sales
contract
Corp. Sales Officer
Verifies the customer
with the bank
Bank Manager
Issues the bank
guarantee
Corp. Sales Director
Approves bank
guarantee terms
Bank Admin
Releases ATC to
customer
Bank Manager
Option to contend
the guarantee terms
Contract updated
• Supplier requests
a bank guarantee
SHARED LEDGER
Image
Digitize trust with Microsoft Azure Blockchain
Seamlessly integrate blockchain
with your business using built-in
connections to Azure and the
tools you're already familiar with—
all on an open, trusted, globally
available cloud platform
Iterate and validate blockchain
scenarios quickly with an intuitive
UI for modelling smart contracts
and prebuilt blockchain templates
and commands
Cut development time with
painless network deployment,
built-in governance and
extensible, fully-managed
infrastructure
Simplify
development
Get up and
running quickly
Innovate with
confidence
Get started now
Launch your first
network today with
Azure Blockchain
Service
Learn how businesses
are leveraging
blockchain
Join the
conversation on
Azure Advisors
Contact your account
team to connect with a
blockchain expert
Learn more
at the Azure
Blockchain Blog
Blockchain on Azure - Resources
Scan this QR-code to access free educational
resources, step-by-step learning guides as well as get
practical experience in Blockchain on Azure!
https://aka.ms/AA65mf2
Don’t forget to add Microsoft Azure skill to your LinkedIn
account to stay connected with a developer community + Microsoft Azure
We post the latest announcements about free events for
developers in Ireland on our official Twitter account @MSDevIRL
Image
Image
Dynamics 365 Community
Benefits
• Participate and help
build a pool of
knowledge that’s
accessible by
members at any time!
• Expand your network
by engaging with
peers
•
•
•
•
•
•
•
Join the Dynamics 365 Community, where you can interact with your peers and Microsoft Dynamics
365 experts. You can get answers to your questions by posting questions in the forums, starting
discussions, reading informative blog articles, and watching how-to videos.
https://community.dynamics.com
Social
 www.365portal.org
 Twitter: @Dyn365Community
 Linkedin: @365-Saturday
 Hashtags
 #D365SatDub #365Saturday
#msdyn365
 Wifi:
 Network – MSFTGUEST
 Password - msevent662en
 Community.Dynamics365.com
Feedback
 We really value your feedback.
Log-in to the 365portal event
page and click on the session
title.
 Make sure you have added the
session to your schedule and you
have checked in.
 You can now leave feedback
which will help the speaker and
improve our future events for the
community.
Feedback