46
Getting Started with Office 365 Development Speaker: Dragan Panjkov 15 th November 2014 Host: Matthew Hughes

Getting Started with Office 365 Development

Embed Size (px)

DESCRIPTION

Slides for session presented at Office365 Saturday Europe 2014, 15.11.2014. This session introduces you to the Microsoft Office 365 Development platform. It introduces the main two approaches to developing using the App Model to make your customizations appear in the products and the Office 365 APIs to consume them from within your own applications. Understand the strategy and direction of the Office 365 development platform. Learn the key ways to develop on top of the Office 365 platform. See some key scenarios that highlight the benefit of building business solutions on top of the Office 365 platform. This session is delivered on TechEd Europe 2014, in a bit longer format.

Citation preview

Page 1: Getting Started with Office 365 Development

Getting Started with Office 365

DevelopmentSpeaker: Dragan Panjkov

15th November 2014

Host: Matthew Hughes

Page 2: Getting Started with Office 365 Development

O365EU Sponsors

Page 3: Getting Started with Office 365 Development

Dragan Panjkov

Learning SharePoint since 2007 www.dragan-panjkov.com www.twitter.com/panjkov

PlanB. d.o.o. www.planb.ba

New Office User Group BiH www.1sug.com www.mscommunity.ba

MCSD – SharePoint Applications MVP for Office365 (april 2014)

Page 4: Getting Started with Office 365 Development

AgendaApps for Office

Apps for SharePoint

Office 365 REST APIs

5

Page 5: Getting Started with Office 365 Development

Apps for Office

Page 6: Getting Started with Office 365 Development

Office 2013 web apps

Content app

Mail app

Task pane app

Office 2013 development options

Pre-Office 2013 developmentExtending Office ribbon

COM add-in

Macro

VSTO

Office 2013 desktop apps

Task pane app

Content app

Mail app

Page 7: Getting Started with Office 365 Development

Office 2013 development scenarios

Business processes Sales and marketing, finance, and HR

Team collaboration Content and project management

Workflow Document approval and expenses

App for Sharepoint

Document template

App for Office

App for Office

App for Office

App for Office

Translation, definitions, dictionary, help, research

Business data lookup (CRM), contextual forms (surveys)

Rich web content YouTube video and photo gallery

Data visualization, analysis and

mashups

Maps, custom charts, and lookups

Reference tools

Content authoring and

publishingContextual

content and services

Workflow and collaboration

Doc builders and print services

Project tracking, coauthoring

App for Office

Content authoring

Resumes and contracts

Dashboards Data analysis and data mashups

Forms andreports

Legal forms and financial reports

Document template

App for Office

App for Office

App for Office

App for Office

Page 8: Getting Started with Office 365 Development

Apps for Office - dev fundamentals App components:

App manifest Web site

Office JavaScript API (Office.js)

Referenced on Microsoft CDN or deployed locally

API updates are versioned

It’s web development! Use all JS/CSS frameworks

you want! Same origin policy applies Secure dev practices needed

(SSL, input validation etc.)

Web server

Office Store or

App catalog

Page 9: Getting Started with Office 365 Development

http://aka.ms/OfficeJSAPIs

Page 10: Getting Started with Office 365 Development

Build your first App for Office

Demo

Page 11: Getting Started with Office 365 Development

App shapes for Office

Task paneApp adjacent to the document

ContentApp in the body of the document

Mail Inline pane on an email or appointment item

Page 12: Getting Started with Office 365 Development
Page 13: Getting Started with Office 365 Development

App shapes for Office

Task paneApp adjacent to the document

ContentApp in the body of the document

Mail Inline pane on an email or appointment item

Page 14: Getting Started with Office 365 Development
Page 15: Getting Started with Office 365 Development

App shapes for Office

Task paneApp adjacent to the document

ContentApp in the body of the document

Mail Inline pane on an email or appointment item

Page 16: Getting Started with Office 365 Development
Page 17: Getting Started with Office 365 Development

Apps for Office samples

Demo

Page 18: Getting Started with Office 365 Development

Apps for SharePoint

Page 19: Getting Started with Office 365 Development

SharePoint apps - recap

Code is isolated from SharePoint, using remote APIsClient-side: JavaScript in user’s browserServer-side: CSOM code in Azure/IIS/other

Page 20: Getting Started with Office 365 Development

Custom client code

_api

JavaScript library Silverlight library .Net CLR library

Execute query REST/

OData

…SearchSites, Lists and

LibsTaxonomy BCSWorkflow

The SharePoint client APIs

Page 21: Getting Started with Office 365 Development

Packaging and publishing apps

Packaging apps.app file extension—a package typically includes the following files:

AppManifest.xml

AppIcon.png

Solution file

Data tier application package

Publishing appsOffice Store

App catalogs

Page 22: Getting Started with Office 365 Development

Build your first App for SharePoint

Demo

Page 23: Getting Started with Office 365 Development

App shapes for SharePoint

Full pageImplement complete app experiences to satisfy business scenarios

PartsCreate app parts that can interact with the SharePoint experience

UI command extensionsAdd new commands to the ribbon and item menus

Page 24: Getting Started with Office 365 Development
Page 25: Getting Started with Office 365 Development

App shapes for SharePoint

Full pageImplement complete app experiences to satisfy business scenarios

PartsCreate app parts that can interact with the SharePoint experience

UI command extensionsAdd new commands to the ribbon and item menus

Page 26: Getting Started with Office 365 Development
Page 27: Getting Started with Office 365 Development

App shapes for SharePoint

Full pageImplement complete app experiences to satisfy business scenarios

PartsCreate app parts that can interact with the SharePoint experience

UI command extensionsAdd new commands to the ribbon and item menus

Page 28: Getting Started with Office 365 Development
Page 29: Getting Started with Office 365 Development

App for SharePoint sample

Demo

Page 30: Getting Started with Office 365 Development

Office 365 APIs

Page 31: Getting Started with Office 365 Development

Available REST EndpointsExchange & Outlook.com

Calendar

Contacts

Mail

OneDrive

OneDrive for Business

Active Directory

Users

Groups

SharePoint

Client API

Search

Sites, Lists and Libs

Taxonomy

BCSWorkflow

Sites

Page 32: Getting Started with Office 365 Development

Common Consent Framework for Office 365

• Single Authentication flow for O365• Azure AD Graph, Exchange,

SharePoint• Device apps and web apps• Admin and end-user consent

• Secure protocol• OAuth 2.0• No capturing user credentials• Fine-grained access scopes• Supports MFA and federated user

sign-in• Long-term access through refresh

tokens

Page 33: Getting Started with Office 365 Development

Discovering endpoints and API’s

36

 

Office 365 discovery servicesAutomatically determine URL of O365 servicesSupports device app and website flowsSecured using Azure AD authenticationServes information stored about services in AAD

Rich service metadata Lists all Entities, Collections, Actions, Complex Types, Enums and their Properties.https://outlook.office365.com/api/v1.0/$metadata

Page 34: Getting Started with Office 365 Development

• .NET SDK to build many types of apps using Visual Studio.NET Windows Store AppsWindows Forms ApplicationWPF ApplicationASP.NET MVC Web ApplicationASP.NET Web Forms ApplicationXamarin Android and iOS ApplicationsMulti-device Hybrid Apps (Cordova)

• Android SDK & iOS SDK’s

Rich Tooling

Page 35: Getting Started with Office 365 Development

Get the tools

https://visualstudiogallery.msdn.microsoft.com/a15b85e6-69a7-4fdf-adda-a38066bb5155?SRC=VSIDE

Page 36: Getting Started with Office 365 Development

Permissions Read, Read+Write, Send

Entities, Collections, Actions

Samples https://outlook.office365.com/api/v1.0/Me/Folders/Inbox/ https://outlook.office365.com/api/v1.0/Me/Folders/Inbox/Messages?$top=1 https://outlook.office365.com/api/v1.0/Me/SendMail/

Mail

Entity Collection Actions

Folder Folders CRUD, Copy, Move

Message Messages

CRUD, Copy, Move, Reply, ReplyAll, Forward, Send, CreateReply, CreateReplyAll, CreateForward 

Attachment Attachments CRUD

CollectionEntity

Intuitive Send API

Page 37: Getting Started with Office 365 Development

Permissions Read, Read+Write

Entities, Collections, Actions

Samples https://outlook.office365.com/api/v1.0/Me/Calendar https://outlook.office365.com/api/v1.0/Me/Calendar/Events?$top=1 https://outlook.office365.com/api/v1.0/Me/CalendarView?startDateTime=2014-10-

01T01:01:01Z & endDateTime=2014-11-01T01:01:01Z

Calendar

Entity Collection Actions

CalendarGroup CalendarGroups CRUD 

Calendar Calendars CRUD 

Event EventsCRUD, Accept, Decline, TentativelyAccept

CalendarView N/A Read

Attachment Attachments CRUD CollectionEntity

No client-side recurrence

expansion required

Page 38: Getting Started with Office 365 Development

Permissions Read, Read+Write

Entities, Collections, Actions

Samples https://outlook.office365.com/api/v1.0/Me/ContactFolders(‘Contacts’)/ https://outlook.office365.com/api/v1.0/Me/Contacts/

Use AAD Graph API to find users in a tenant.

Contacts

Entity Collection Actions

ContactFolder ContactFolders

Contact Contacts CRUD

Page 39: Getting Started with Office 365 Development

Permissions Read, Read+Write

Entities, Collections, Actions

Samples https://contoso-my.sharepoint.com/_api/v1.0/me/drive https://contoso-my.sharepoint.com/_api/v1.0/me/drive/files

Files

Entity Collection Actions

Drive Read

File Files CRUD, Upload, Download

Folder CRUD

Page 40: Getting Started with Office 365 Development

Permissions Read, Read+Write

Entities, Collections, Actions

Samples https://graph.windows.net/contoso.com/users?api-version=1.5 https://graph.windows.net/contoso.com/groups?api-version=1.5

Users + Groups

Entity Collection Actions

User Users CRUD

Groups Groups CRUD

Page 41: Getting Started with Office 365 Development

Rich Query Syntax using ODataScenario URL

Get 5 messages from Inbox https://outlook.office365.com/api/v1.0/Me/Folders/Inbox/Messages?$top=5

Get the next 10 messages https://outlook.office365.com/api/v1.0/Me/Folders/Inbox/Messages?$top=10&$skip=5

Get top 10 messages sorted by DateTimeCreated

https://outlook.office365.com/api/v1.0/Me/Folders/Inbox/Messages?$top=10&$orderby=DateTimeCreated

Get selective properties on messages

https://outlook.office365.com/api/v1.0/Me/Folders/Inbox/Messages?$top=5&$select=From,DateTimeCreated,Subject

Get events starting after a particular DateTime

https://outlook.office365.com/api/v1.0/Me/Events?$top=5&$select=Subject,Start,End&$filter=Start ge 2014-09-22T20:00:00Z

Get Inbox messages with subject and attachment info

https://outlook.office365.com/api/v1.0/Me/Folders/Inbox/Messages?$format=application/json;odata.metadata=none&$select=Subject&$expand=Attachments

Get # of messages with attachment(s)

https://outlook.office365.com/api/v1.0/Me/Folders/Inbox/Messages/$count?$filter=HasAttachments eq true

Get count and selective props on messages with attachment(s)

https://outlook.office365.com/v1.0/Me/Folders/Inbox/Messages?$format=application/json;odata.metadata=none&$select=Subject&$filter=HasAttachments%20eq%20true&$count=true

Get contact with a given name

https://outlook.office365.com/v1.0/Me/Contacts/?$filter=Givenname eq ‘John’

Page 42: Getting Started with Office 365 Development

45

Page 43: Getting Started with Office 365 Development

Getting Started:

Office 365 APIs starter Project – Visual StudioDemo

Page 44: Getting Started with Office 365 Development

RecapEmbed your customization in Office and SharePoint user experience using Apps

Manipulate data in Office 365 from your standalone apps using REST APIs

47

Page 45: Getting Started with Office 365 Development

Resources• Microsoft Virtual Academy

http://www.microsoftvirtualacademy.com/product-training/office-development

• TechEd Europe 2014 sessionshttp://www.dragan-panjkov.com/getting-started-with-office-365-development-teched-europe-2014-session-resources

• ITUnity Article (Getting Started) http://www.itunity.com/article/programming-office-365-apis-general-availability-release-678

• GitHub Office Dev Repository https://github.com/OfficeDev

• Office Dev portaldev.office.com

Page 46: Getting Started with Office 365 Development

Questions?www.dragan-panjkov.com

www.twitter.com/panjkov