Amsterdam | April 2-3, 2019

Building a network of APIs

for a future-proof integrated architecture

Desy Kristianti @dessskris

@dessskris

Photo by Jordan Sanchez on Unsplash

Where did the cushion go?!

@dessskris

Photo by Cabinair Services

Airplane Seats "Micro" Parts

@dessskris

Photo by Pitch Aircraft Seating

About me

Desy Kristianti

Tech Consultant at Deloitte UK

Enterprise Integration Specialist

MuleSoft Certified Developer & API Designer

Dell Boomi Certified Developer

@dessskris

Agenda

  1. Microservices & Network of APIs
  2. Is this for you?
  3. Approaches for Design, Build and Test

@dessskris

Demistifying the jargon

Microservices

@dessskris

API

Connecting applications

Application Programming Interface

Representational State Transfer (REST)

Loosely coupled services

Integration

Why future-proof your architecture?

Photo by Randy Fath on Unsplash

@dessskris

It's not about size anymore...

Photo by Cara Fuller on Unsplash

@dessskris

Microservices architecture

Photo by Hong Lin on Unsplash

@dessskris

What's so good about
microservices architecture?

Fast to scale

@dessskris

Easy to plug
and un-plug

Loosely coupled, reusable services

Network of APIs

Photo by Dell Boomi

@dessskris

Case Study: Unibever

@dessskris

Order

Management System

Customer

Management System

Invoice

Management System

Case Study: Unibever

@dessskris

Order
Management System

Customer
Management System

Invoice
Management System

Process:

Upon receiving a new Order in NetSuite,

update the Customer details in Salesforce,

and create a new Invoice in SAP.

Traditionally...

@dessskris

Order
Management System

Customer
Management System

Invoice
Management System

In reality...

@dessskris

But what if...

@dessskris

API-enabled network

@dessskris

An API for each application

@dessskris

Supported by other APIs

@dessskris

With many more applications...

@dessskris

Easily plug and un-plug...

@dessskris

Is this for me?

@dessskris

Advantages

Quickly change
when adopting new or replacing old systems

@dessskris

Reusable components
with caching enabled

Easily integrate
a large number
of different applications

Less developer time and effort, saving money

Disadvantages

@dessskris

Overhead in API management

Extra effort in the short term

Twice the amount of data transformation required

Are you ready to be the fastest?

Photo by Jean Wimmerlin on Unsplash

@dessskris

Show me how to
build a network of APIs!

@dessskris

API Design Approach

@dessskris

Three-layered API architecture

@dessskris

Source: MuleSoft Blog

Case Study: Unibever

@dessskris

API Design Documentation

@dessskris

Photo by Aaron Burden on Unsplash

e.g. RAML, YAML, Swagger

Designing your endpoints

@dessskris

Endpoint GET HEAD POST PUT PATCH DELETE OPTIONS
https://host:port/api/v1/customers
https://host:port/api/v1/customers/{customerId}
https://host:port/api/v1/health
https://host:port/api/v1/errors

i.e. methods, resources, versioning

API Build
Approach

@dessskris

Building your API implementation

@dessskris

API Template with health check & error handling

Error Handling pAPI

Caching
where relevant

Client ID & Client Secret

Spike control, rate limiting, throttling, IP whitelist/blacklist

Integration Platform as a Service (iPaaS) Tools that can help

@dessskris

Gartner Magic Quadrant for iPaaS

Gartner Magic Quadrant for API Management

Micro-Version Control?

@dessskris

Mono-repository

Modular repositories

Individual API repositories

Branching strategy

@dessskris

Source: GitFlow by Vincent Driessen
https://datasift.github.io/gitflow/IntroducingGitFlow.html

CI/CD considerations

  • Each API is independently deployable
  • Tag every commit with your user story ID
  • Pick up approved and merged commits
  • Deploy and run automated tests

@dessskris

Photo by Synopsys

API Test
Approach

@dessskris

Testing considerations

  • Write unit tests based on API design docs
  • Test the smallest services, and mock its output
  • Validate against schema, but also test for expected responses

@dessskris

Conclusion

  • Build a network of APIs in order to scale fast
  • Three-layer architecture: Experience, Process and System APIs
  • API design document is your bible for build & test

@dessskris

Photo by Cara Fuller on Unsplash

Desy Kristianti

https://slides.com/dessskris/network-of-apis

dessskris@gmail.com

Desy Kristianti

@dessskris

Thank you!

Made with Slides.com