SlideShare a Scribd company logo
1 of 15
Data To Go
Mobile API Design
Chuck Greb
Mobile Platform Architect
AWeber Communications
@ecgreb
Data To Go
Good Mobile API Design
Chuck Greb
Mobile Platform Architect
AWeber Communications
@ecgreb
A Brief Survey
What is an API?
An application programming interface (API)
is a specification of how software
components should interact with each other.
In most cases an API is a library that
includes specification for routines, data
structures, object classes, and variables.
http://en.wikipedia.org/wiki/Application_programming_interface
Remote Service API
● Remote (web-based) services
● Desktop, laptop, or mobile client
● Communication protocol and data model
(HTTP + REST + JSON)
Web API Request
Mobile API Request
Mobile API requests are
generally slower and more
prone to timeouts and other
failures!
3 Principles of Good Mobile APIs
1. Reduce round trips to the server
2. Control verbosity
3. Restrict access
These 3 rules don't always get along!
Principle #1
Reduce round trips to the server
● Resources are limited (battery,
bandwidth, memory, CPU)
● Eliminate network overhead
● Brevity trumps discoverability
● Users are impatient
Batch Request (3 in 1)
POST https://www.example.com/api/v1/login
Input
{"username":"chuck@example.com", "password":"Kronos"}
Output
{
"user_id": 123
"access_token":"Y2h1Y2tAZXhhbXBsZS5jb20=",
"name":"Chuck Greb",
"email":"chuck@example.com",
"avatar":"http://www.example.com/images/dh3d67kfb.jpg",
"recent_messages": [
{"message_id":"101", "subject":"Hey!", "sender":{...}},
{"message_id":"102", "subject":"What's up?", "sender":{...}},
...
]
}
Principle #2
Control Verbosity
● Slow connection speed
● Limited data plans $$$
● Purge irrelevant and empty data
● Specify verbosity level per request
● Object expansion
Object Expansion
GET https://www.example.com/api/v1/user/123/recent_messages
{"recent_messages": [
{
"message_id":"101", "subject":"Hey bro!", "sender":{
"name":"Jeff Greb",
"avatar":"http://www.example.com/images/dh3d67kfb.jpg"}
},
...
]}
GET https://www.example.com/api/v1/message/101
{
"message_id":"101", "subject":"Hey bro!", "sender":{
"name":"Jeff Greb",
"avatar":"http://www.example.com/images/dh3d67kfb.jpg",
"interests":["English", "Japanese", "Music", "Comedy", ...]},
"timestamp":"2013-6-12T13:38:22",
"body":"Long time no see. What's new? I was thinking last..."
}
Principle #3
Restrict Access
● Identify the source of all requests
● Prevent unauthorized access
● Protect sensitive data
● Mobile-friendly security model
Authentication & Authorization
POST https://www.example.com/api/v1/login
Input
{"username":"chuck@example.com", "password":"Kronos"}
Output
{
"user_id": 123,
"auth_token":"Y2h1Y2tAZXhhbXBsZS5jb20="
...
}
Header
"Access-Token":"Y2h1Y2tAZXhhbXBsZS5jb20="
Thank You
Questions?
Chuck Greb
Mobile Platform Architect
AWeber Communications
@ecgreb

More Related Content

Viewers also liked

Creating an Effective Mobile API
Creating an Effective Mobile API Creating an Effective Mobile API
Creating an Effective Mobile API Nick DeNardis
 
Jordi Romero Api for-the-mobile-era
Jordi Romero Api for-the-mobile-eraJordi Romero Api for-the-mobile-era
Jordi Romero Api for-the-mobile-era.toster
 
Api mobile first
Api mobile firstApi mobile first
Api mobile firstChris Saez
 
Mobile Api and Caching
Mobile Api and CachingMobile Api and Caching
Mobile Api and CachingNew Relic
 
Mobile API: Design & Techniques
Mobile API: Design & TechniquesMobile API: Design & Techniques
Mobile API: Design & TechniquesFred Brunel
 
Data to Go: Mobile API Design
Data to Go: Mobile API DesignData to Go: Mobile API Design
Data to Go: Mobile API DesignChuck Greb
 
Data to Go: Mobile API Design (SXSW)
Data to Go: Mobile API Design (SXSW)Data to Go: Mobile API Design (SXSW)
Data to Go: Mobile API Design (SXSW)Chuck Greb
 
Build a REST API for your Mobile Apps using Node.js
Build a REST API for your Mobile Apps using Node.jsBuild a REST API for your Mobile Apps using Node.js
Build a REST API for your Mobile Apps using Node.jsStormpath
 
We we should be Mobile API - First, by Brad Hipps
We we should be Mobile API - First, by Brad HippsWe we should be Mobile API - First, by Brad Hipps
We we should be Mobile API - First, by Brad HippsPuerto Rico Tech Summit
 
Designing API for mobile apps (MobileWarsaw 19.01.2015)
Designing API for mobile apps (MobileWarsaw 19.01.2015)Designing API for mobile apps (MobileWarsaw 19.01.2015)
Designing API for mobile apps (MobileWarsaw 19.01.2015)Wojtek Erbetowski
 

Viewers also liked (11)

Creating an Effective Mobile API
Creating an Effective Mobile API Creating an Effective Mobile API
Creating an Effective Mobile API
 
Jordi Romero Api for-the-mobile-era
Jordi Romero Api for-the-mobile-eraJordi Romero Api for-the-mobile-era
Jordi Romero Api for-the-mobile-era
 
Api mobile first
Api mobile firstApi mobile first
Api mobile first
 
Mobile Api and Caching
Mobile Api and CachingMobile Api and Caching
Mobile Api and Caching
 
Mobile API: Design & Techniques
Mobile API: Design & TechniquesMobile API: Design & Techniques
Mobile API: Design & Techniques
 
Data to Go: Mobile API Design
Data to Go: Mobile API DesignData to Go: Mobile API Design
Data to Go: Mobile API Design
 
Data to Go: Mobile API Design (SXSW)
Data to Go: Mobile API Design (SXSW)Data to Go: Mobile API Design (SXSW)
Data to Go: Mobile API Design (SXSW)
 
Build a REST API for your Mobile Apps using Node.js
Build a REST API for your Mobile Apps using Node.jsBuild a REST API for your Mobile Apps using Node.js
Build a REST API for your Mobile Apps using Node.js
 
We we should be Mobile API - First, by Brad Hipps
We we should be Mobile API - First, by Brad HippsWe we should be Mobile API - First, by Brad Hipps
We we should be Mobile API - First, by Brad Hipps
 
Designing API for mobile apps (MobileWarsaw 19.01.2015)
Designing API for mobile apps (MobileWarsaw 19.01.2015)Designing API for mobile apps (MobileWarsaw 19.01.2015)
Designing API for mobile apps (MobileWarsaw 19.01.2015)
 
Build Features, Not Apps
Build Features, Not AppsBuild Features, Not Apps
Build Features, Not Apps
 

Similar to Data To Go: Mobile API Design (Lightning Talk)

apidays LIVE Hong Kong 2021 - Multi-Protocol APIs at Scale in Adidas by Jesus...
apidays LIVE Hong Kong 2021 - Multi-Protocol APIs at Scale in Adidas by Jesus...apidays LIVE Hong Kong 2021 - Multi-Protocol APIs at Scale in Adidas by Jesus...
apidays LIVE Hong Kong 2021 - Multi-Protocol APIs at Scale in Adidas by Jesus...apidays
 
Modern REST API design principles and rules.pdf
Modern REST API design principles and rules.pdfModern REST API design principles and rules.pdf
Modern REST API design principles and rules.pdfAparna Sharma
 
zendframework2 restful
zendframework2 restfulzendframework2 restful
zendframework2 restfultom_li
 
Fullstack Interview Questions and Answers.pdf
Fullstack Interview Questions and Answers.pdfFullstack Interview Questions and Answers.pdf
Fullstack Interview Questions and Answers.pdfcsvishnukumar
 
REST & RESTful APIs: The State of Confusion
REST & RESTful APIs: The State of ConfusionREST & RESTful APIs: The State of Confusion
REST & RESTful APIs: The State of ConfusionGlenn Antoine
 
Modern REST API design principles and rules.pdf
Modern REST API design principles and rules.pdfModern REST API design principles and rules.pdf
Modern REST API design principles and rules.pdfAparna Sharma
 
Protecting Your APIs Against Attack & Hijack
Protecting Your APIs Against Attack & Hijack Protecting Your APIs Against Attack & Hijack
Protecting Your APIs Against Attack & Hijack CA API Management
 
APIdays San Francisco, 06/22/2013
APIdays San Francisco, 06/22/2013APIdays San Francisco, 06/22/2013
APIdays San Francisco, 06/22/2013Jerome Louvel
 
From Web APIs to Cross-Device Web Sites
From Web APIs to Cross-Device Web SitesFrom Web APIs to Cross-Device Web Sites
From Web APIs to Cross-Device Web SitesRestlet
 
Developing Profitable APIs - John Fraser - Platform A
Developing Profitable APIs - John Fraser - Platform ADeveloping Profitable APIs - John Fraser - Platform A
Developing Profitable APIs - John Fraser - Platform Aauexpo Conference
 
aip-developer-intro_pag2015
aip-developer-intro_pag2015aip-developer-intro_pag2015
aip-developer-intro_pag2015Matthew Vaughn
 
Starting Your DevOps Journey – Practical Tips for Ops
Starting Your DevOps Journey – Practical Tips for OpsStarting Your DevOps Journey – Practical Tips for Ops
Starting Your DevOps Journey – Practical Tips for OpsDynatrace
 
What is the difference between an api and web services
What is the difference between an api and web servicesWhat is the difference between an api and web services
What is the difference between an api and web servicesAparna Sharma
 
REST-API introduction for developers
REST-API introduction for developersREST-API introduction for developers
REST-API introduction for developersPatrick Savalle
 
SPTECHCON - Rev Your Engines - SharePoint 2013 Performance Enhancements
SPTECHCON - Rev Your Engines - SharePoint 2013 Performance EnhancementsSPTECHCON - Rev Your Engines - SharePoint 2013 Performance Enhancements
SPTECHCON - Rev Your Engines - SharePoint 2013 Performance EnhancementsEric Shupps
 
Building A Mobile First API When You're Not Mobile First - Tyler Singletary
Building A Mobile First API When You're Not Mobile First - Tyler SingletaryBuilding A Mobile First API When You're Not Mobile First - Tyler Singletary
Building A Mobile First API When You're Not Mobile First - Tyler SingletaryProgrammableWeb
 
Phalcon 2 High Performance APIs - DevWeekPOA 2015
Phalcon 2 High Performance APIs - DevWeekPOA 2015Phalcon 2 High Performance APIs - DevWeekPOA 2015
Phalcon 2 High Performance APIs - DevWeekPOA 2015Jackson F. de A. Mafra
 

Similar to Data To Go: Mobile API Design (Lightning Talk) (20)

REST != WebAPI
REST != WebAPIREST != WebAPI
REST != WebAPI
 
apidays LIVE Hong Kong 2021 - Multi-Protocol APIs at Scale in Adidas by Jesus...
apidays LIVE Hong Kong 2021 - Multi-Protocol APIs at Scale in Adidas by Jesus...apidays LIVE Hong Kong 2021 - Multi-Protocol APIs at Scale in Adidas by Jesus...
apidays LIVE Hong Kong 2021 - Multi-Protocol APIs at Scale in Adidas by Jesus...
 
Modern REST API design principles and rules.pdf
Modern REST API design principles and rules.pdfModern REST API design principles and rules.pdf
Modern REST API design principles and rules.pdf
 
zendframework2 restful
zendframework2 restfulzendframework2 restful
zendframework2 restful
 
Fullstack Interview Questions and Answers.pdf
Fullstack Interview Questions and Answers.pdfFullstack Interview Questions and Answers.pdf
Fullstack Interview Questions and Answers.pdf
 
REST & RESTful APIs: The State of Confusion
REST & RESTful APIs: The State of ConfusionREST & RESTful APIs: The State of Confusion
REST & RESTful APIs: The State of Confusion
 
Modern REST API design principles and rules.pdf
Modern REST API design principles and rules.pdfModern REST API design principles and rules.pdf
Modern REST API design principles and rules.pdf
 
Protecting Your APIs Against Attack & Hijack
Protecting Your APIs Against Attack & Hijack Protecting Your APIs Against Attack & Hijack
Protecting Your APIs Against Attack & Hijack
 
APIdays San Francisco, 06/22/2013
APIdays San Francisco, 06/22/2013APIdays San Francisco, 06/22/2013
APIdays San Francisco, 06/22/2013
 
From Web APIs to Cross-Device Web Sites
From Web APIs to Cross-Device Web SitesFrom Web APIs to Cross-Device Web Sites
From Web APIs to Cross-Device Web Sites
 
Developing Profitable APIs - John Fraser - Platform A
Developing Profitable APIs - John Fraser - Platform ADeveloping Profitable APIs - John Fraser - Platform A
Developing Profitable APIs - John Fraser - Platform A
 
aip-developer-intro_pag2015
aip-developer-intro_pag2015aip-developer-intro_pag2015
aip-developer-intro_pag2015
 
REST API
REST APIREST API
REST API
 
Starting Your DevOps Journey – Practical Tips for Ops
Starting Your DevOps Journey – Practical Tips for OpsStarting Your DevOps Journey – Practical Tips for Ops
Starting Your DevOps Journey – Practical Tips for Ops
 
What is the difference between an api and web services
What is the difference between an api and web servicesWhat is the difference between an api and web services
What is the difference between an api and web services
 
REST-API introduction for developers
REST-API introduction for developersREST-API introduction for developers
REST-API introduction for developers
 
SPTECHCON - Rev Your Engines - SharePoint 2013 Performance Enhancements
SPTECHCON - Rev Your Engines - SharePoint 2013 Performance EnhancementsSPTECHCON - Rev Your Engines - SharePoint 2013 Performance Enhancements
SPTECHCON - Rev Your Engines - SharePoint 2013 Performance Enhancements
 
Building A Mobile First API When You're Not Mobile First - Tyler Singletary
Building A Mobile First API When You're Not Mobile First - Tyler SingletaryBuilding A Mobile First API When You're Not Mobile First - Tyler Singletary
Building A Mobile First API When You're Not Mobile First - Tyler Singletary
 
Apitesting.pptx
Apitesting.pptxApitesting.pptx
Apitesting.pptx
 
Phalcon 2 High Performance APIs - DevWeekPOA 2015
Phalcon 2 High Performance APIs - DevWeekPOA 2015Phalcon 2 High Performance APIs - DevWeekPOA 2015
Phalcon 2 High Performance APIs - DevWeekPOA 2015
 

More from Chuck Greb

Testable Android Architecture
Testable Android ArchitectureTestable Android Architecture
Testable Android ArchitectureChuck Greb
 
Building Location-Aware Apps with Open Source & Open Data (SXSW 2015)
Building Location-Aware Apps with Open Source & Open Data (SXSW 2015)Building Location-Aware Apps with Open Source & Open Data (SXSW 2015)
Building Location-Aware Apps with Open Source & Open Data (SXSW 2015)Chuck Greb
 
What's the deal with Android maps?
What's the deal with Android maps?What's the deal with Android maps?
What's the deal with Android maps?Chuck Greb
 
Building Location-Aware Apps using Open Source (AnDevCon SF 2014)
Building Location-Aware Apps using Open Source (AnDevCon SF 2014)Building Location-Aware Apps using Open Source (AnDevCon SF 2014)
Building Location-Aware Apps using Open Source (AnDevCon SF 2014)Chuck Greb
 
Building Location-Aware Apps with Open Source & Open Data
Building Location-Aware Apps with Open Source & Open DataBuilding Location-Aware Apps with Open Source & Open Data
Building Location-Aware Apps with Open Source & Open DataChuck Greb
 
AnDevCon 2013 Roundup
AnDevCon 2013 RoundupAnDevCon 2013 Roundup
AnDevCon 2013 RoundupChuck Greb
 
Google Charts for native Android apps
Google Charts for native Android appsGoogle Charts for native Android apps
Google Charts for native Android appsChuck Greb
 
HowAboutWe... Build an Android App
HowAboutWe... Build an Android AppHowAboutWe... Build an Android App
HowAboutWe... Build an Android AppChuck Greb
 

More from Chuck Greb (11)

Testable Android Architecture
Testable Android ArchitectureTestable Android Architecture
Testable Android Architecture
 
Building Location-Aware Apps with Open Source & Open Data (SXSW 2015)
Building Location-Aware Apps with Open Source & Open Data (SXSW 2015)Building Location-Aware Apps with Open Source & Open Data (SXSW 2015)
Building Location-Aware Apps with Open Source & Open Data (SXSW 2015)
 
Bu
BuBu
Bu
 
What's the deal with Android maps?
What's the deal with Android maps?What's the deal with Android maps?
What's the deal with Android maps?
 
Building Location-Aware Apps using Open Source (AnDevCon SF 2014)
Building Location-Aware Apps using Open Source (AnDevCon SF 2014)Building Location-Aware Apps using Open Source (AnDevCon SF 2014)
Building Location-Aware Apps using Open Source (AnDevCon SF 2014)
 
Building Location-Aware Apps with Open Source & Open Data
Building Location-Aware Apps with Open Source & Open DataBuilding Location-Aware Apps with Open Source & Open Data
Building Location-Aware Apps with Open Source & Open Data
 
Notifunk
NotifunkNotifunk
Notifunk
 
AnDevCon 2013 Roundup
AnDevCon 2013 RoundupAnDevCon 2013 Roundup
AnDevCon 2013 Roundup
 
Android TDD
Android TDDAndroid TDD
Android TDD
 
Google Charts for native Android apps
Google Charts for native Android appsGoogle Charts for native Android apps
Google Charts for native Android apps
 
HowAboutWe... Build an Android App
HowAboutWe... Build an Android AppHowAboutWe... Build an Android App
HowAboutWe... Build an Android App
 

Recently uploaded

WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure serviceWhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure servicePooja Nehwal
 
CNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of ServiceCNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of Servicegiselly40
 
Presentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreterPresentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreternaman860154
 
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfThe Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfEnterprise Knowledge
 
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...Igalia
 
The Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxThe Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxMalak Abu Hammad
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)Gabriella Davis
 
08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking MenDelhi Call girls
 
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptxHampshireHUG
 
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Miguel Araújo
 
Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)Allon Mureinik
 
Maximizing Board Effectiveness 2024 Webinar.pptx
Maximizing Board Effectiveness 2024 Webinar.pptxMaximizing Board Effectiveness 2024 Webinar.pptx
Maximizing Board Effectiveness 2024 Webinar.pptxOnBoard
 
08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking MenDelhi Call girls
 
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...Neo4j
 
Handwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsHandwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsMaria Levchenko
 
IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsEnterprise Knowledge
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerThousandEyes
 
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking MenDelhi Call girls
 
The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024Rafal Los
 
Enhancing Worker Digital Experience: A Hands-on Workshop for Partners
Enhancing Worker Digital Experience: A Hands-on Workshop for PartnersEnhancing Worker Digital Experience: A Hands-on Workshop for Partners
Enhancing Worker Digital Experience: A Hands-on Workshop for PartnersThousandEyes
 

Recently uploaded (20)

WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure serviceWhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
 
CNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of ServiceCNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of Service
 
Presentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreterPresentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreter
 
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfThe Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
 
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
 
The Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxThe Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptx
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)
 
08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men
 
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
 
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
 
Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)
 
Maximizing Board Effectiveness 2024 Webinar.pptx
Maximizing Board Effectiveness 2024 Webinar.pptxMaximizing Board Effectiveness 2024 Webinar.pptx
Maximizing Board Effectiveness 2024 Webinar.pptx
 
08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men
 
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
 
Handwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsHandwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed texts
 
IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI Solutions
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
 
The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024
 
Enhancing Worker Digital Experience: A Hands-on Workshop for Partners
Enhancing Worker Digital Experience: A Hands-on Workshop for PartnersEnhancing Worker Digital Experience: A Hands-on Workshop for Partners
Enhancing Worker Digital Experience: A Hands-on Workshop for Partners
 

Data To Go: Mobile API Design (Lightning Talk)

  • 1. Data To Go Mobile API Design Chuck Greb Mobile Platform Architect AWeber Communications @ecgreb
  • 2. Data To Go Good Mobile API Design Chuck Greb Mobile Platform Architect AWeber Communications @ecgreb
  • 4. What is an API? An application programming interface (API) is a specification of how software components should interact with each other. In most cases an API is a library that includes specification for routines, data structures, object classes, and variables. http://en.wikipedia.org/wiki/Application_programming_interface
  • 5. Remote Service API ● Remote (web-based) services ● Desktop, laptop, or mobile client ● Communication protocol and data model (HTTP + REST + JSON)
  • 7. Mobile API Request Mobile API requests are generally slower and more prone to timeouts and other failures!
  • 8. 3 Principles of Good Mobile APIs 1. Reduce round trips to the server 2. Control verbosity 3. Restrict access These 3 rules don't always get along!
  • 9. Principle #1 Reduce round trips to the server ● Resources are limited (battery, bandwidth, memory, CPU) ● Eliminate network overhead ● Brevity trumps discoverability ● Users are impatient
  • 10. Batch Request (3 in 1) POST https://www.example.com/api/v1/login Input {"username":"chuck@example.com", "password":"Kronos"} Output { "user_id": 123 "access_token":"Y2h1Y2tAZXhhbXBsZS5jb20=", "name":"Chuck Greb", "email":"chuck@example.com", "avatar":"http://www.example.com/images/dh3d67kfb.jpg", "recent_messages": [ {"message_id":"101", "subject":"Hey!", "sender":{...}}, {"message_id":"102", "subject":"What's up?", "sender":{...}}, ... ] }
  • 11. Principle #2 Control Verbosity ● Slow connection speed ● Limited data plans $$$ ● Purge irrelevant and empty data ● Specify verbosity level per request ● Object expansion
  • 12. Object Expansion GET https://www.example.com/api/v1/user/123/recent_messages {"recent_messages": [ { "message_id":"101", "subject":"Hey bro!", "sender":{ "name":"Jeff Greb", "avatar":"http://www.example.com/images/dh3d67kfb.jpg"} }, ... ]} GET https://www.example.com/api/v1/message/101 { "message_id":"101", "subject":"Hey bro!", "sender":{ "name":"Jeff Greb", "avatar":"http://www.example.com/images/dh3d67kfb.jpg", "interests":["English", "Japanese", "Music", "Comedy", ...]}, "timestamp":"2013-6-12T13:38:22", "body":"Long time no see. What's new? I was thinking last..." }
  • 13. Principle #3 Restrict Access ● Identify the source of all requests ● Prevent unauthorized access ● Protect sensitive data ● Mobile-friendly security model
  • 14. Authentication & Authorization POST https://www.example.com/api/v1/login Input {"username":"chuck@example.com", "password":"Kronos"} Output { "user_id": 123, "auth_token":"Y2h1Y2tAZXhhbXBsZS5jb20=" ... } Header "Access-Token":"Y2h1Y2tAZXhhbXBsZS5jb20="
  • 15. Thank You Questions? Chuck Greb Mobile Platform Architect AWeber Communications @ecgreb