slide1 n.
Skip this Video
Download Presentation
Jerry Yasir SharePoint MVP, MCT

Loading in 2 Seconds...

play fullscreen
1 / 22

Jerry Yasir SharePoint MVP, MCT - PowerPoint PPT Presentation

  • Uploaded on

Building Autohosted Apps for SharePoint 2013. Jerry Yasir SharePoint MVP, MCT. Who Am I?. SharePoint Server MVP Since 2010 SharePoint Practice Lead at US TECH Solutions (Jersey City, NJ)

I am the owner, or an agent authorized to act on behalf of the owner, of the copyrighted work described.
Download Presentation

PowerPoint Slideshow about 'Jerry Yasir SharePoint MVP, MCT' - rhona

Download Now An Image/Link below is provided (as is) to download presentation

Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author.While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server.

- - - - - - - - - - - - - - - - - - - - - - - - - - E N D - - - - - - - - - - - - - - - - - - - - - - - - - -
Presentation Transcript

Building Autohosted Apps for SharePoint 2013

Jerry Yasir

SharePoint MVP, MCT

who am i
Who Am I?
  • SharePoint Server MVP Since 2010
  • SharePoint Practice Lead at US TECH Solutions (Jersey City, NJ)
  • Founder of the Largest SharePoint User Group in Middle East Riyadh SharePoint User Group RSUG  Co-Lead SharePoint Pakistan User Group
  • Microsoft Certified Trainer (MCT) since 2008.
  • MCSE SharePoint 2013
  • MCITPSharePoint Admin 2010, MCPD SharePoint Developer 2010 & MCTS SharePoint 2010 Configuration & Development
  • MCTS WSS 3.0, SharePoint Server 2007, MCITP, MCTS Silverlight 4 Development, Project Server 2007 & 2010, MCTS Project Professional 2007 & 2010, MCPD.NET, MCSD.NET MCAD.NET
  • Email:, MSN:
  • Twitter: @jerry_yasir Facebook: yasir.attiq (Jerry Yasir)
  • Blog:
evolution of sharepoint development
Evolution of SharePoint Development









IIS with _api



Code runs from GAC on same w3wp.exeas SharePoint web application

Code runs on SPUCWorkerProcess.exe or calls client.svc (CSOM)

Code runs outside of SharePoint but has trust to leverage capabilities exposed in _api

app hosting options
App Hosting Options



Your Hosted Site

SharePoint Host Web

Provider-Hosted App

“Bring your own server hosting infrastructure and technology platform”

App Web* (separate SharePoint domain)

Cloud-based Apps

Get remote events from SharePoint Use CSOM/REST + OAuth to work with SP


Windows Azure + SQL Azure provisioned invisibly as apps are installed


SharePoint Host Web

App Web* (separate SharePoint domain)

  • SharePoint-Hosted App
  • Provision an isolated sub web on a parent web (separate domain)
    • Reuse web elements (lists, files, out-of-box web parts)
    • No server code allowed; use client JavaScript for logic, UX

SharePoint Host Web

App Web (separate SharePoint domain)

*App Webs are optional in Cloud-Hosted Apps

autohosted capability quiz
Autohosted Capability Quiz

Custom Actions

Client Web Part

Managed Code

Web Part Page





Host Web

App Web


app lifecycle
App Lifecycle

Tenant A

Web Site



Site Owner

Tenant Admin

App Developer

App Catalog



Web Site



Site Owner


Tenant B

Web Site



Site Owner


Web Site


SharePoint Store

(Office Marketplace)

Site Owner

  • Autohosted App Debug vs. Deploy
app ux options
App UX Options


Navigating to the app takes the user out of the SharePoint site and to the app host (ex: Azure, separate SharePoint domain, etc)

The app uses the full real estate of the browser viewing area (can leverage SharePoint chrome)

SharePoint Dialog

Similar to Full-screen, but displayed in a dialog window

Typically launched through custom action or script (ex: context menu or ribbon button)

App Parts

Displays app as an element in an existing web part or wiki page

Very similar to Page Viewer Web Part, but with better communication capabilities

optimizing ux
Optimizing UX

Leverage chrome control

Chrome control allows full-screen apps to be framed in the chrome and styles similar to the host web (including placeholders for icons, breadcrumbs, and menus)

Import styles from host web

Add reference to http://<host web domain>/_layouts/15/defaultcss.ashx in the head of app page

The chrome control automatically adds styles from the host web, so this approach is only required for pages displayed in app parts or modal windows

Optimize apps part size with post message

Host web listens for post message and resizes based on dimensions passed from the app part

Still imperative to design around a predictable rendering size (challenging without knowing the styles that will be applied)

app permissions
App Permissions

App permissions are configured in the app manifest

Developers specify the permissions the app needs to be able to run

Apps request permissions during installation

Granting app permission is all or nothing (installer can’t pick a chose what to grant from the request)

Apps must be granted permissions by the user executing the app

Users can only grant the permissions they have

Azure Access Control Service (ACS) plays the role of the authorization server

Azure ACS stores basic information about the app and provides apps access tokens for calling SharePoint APIs

appmanifest xml dissected
AppManifest.xml Dissected

General Information

Title, version, icon, start page and query string


Permission levels at specific scopes (ex: write access to profiles, read access to site collection)


Define feature dependencies for the app (ex: publishing features)

Supported Locales

Defines locales the application will support (ex: en-US, fr-FR, etc)

Remote Endpoints

A list of remote endpoints the SharePoint App may access through SP.WebProxy.invoke()

app storage options
App Storage Options

SharePoint Lists

Great for SharePoint-hosted apps, but requires CAML

Requires an app web

SQL Azure

Package app with SQL Package (.dacpac) or by referencing SQL Database project

SQL Azure components are provisioned invisibly when the app is installed by a tenant

Connection information in available through specific APIs (both SqlConnection class and raw connection string)

Others, but be careful with latency

sql azure
SQL Azure

Using SqlConnection object

Specify connection string in web.config using name LocalDBInstanceForDebuggingand the API will dynamically use this connection when debugging

Using raw connection string

The API for retrieving the raw connection string will NOT automatically work when debugging

  • Supplier App
app roles admins
App Roles/Admins

Leverage SharePoint permissions from app web

The app web inherits permissions from the host web

Great for simple permissions models (ex: App Administrator = Host Site Administrator)

Be careful…checking permission on the host web would require the app to have full control of the host web

Store app permissions in the app’s storage (ex: SQL Azure)

Very flexible…can use almost any data/permission model

Need a way to seed the permissions table with administrators

demo employee recognition part 1
Demo - Employee Recognition Part 1


Allow users to send recognition to other users

Submission should post to the SharePoint Newsfeed

App should be profile aware (user pictures, titles, managers, etc)

App should send email to submitter, recipient, and both managers (if applicable)

No administrative settings (static settings)

Design Decisions

Hosting: Autohosted

UX: full-screen and app part

APIs: mixture of CSOM and SSOM

Storage: SharePoint List

App Roles/Admin: Not Applicable

demo employee recognition part 2
Demo - Employee Recognition Part 2

Requirements (same as previous, except the following)

Allow users to select badges to go with the recognition (ex: Going Green, Community Ninja, etc)

Allow app administrators to configure quotas and notification settings

Provide reports of recognition history

Design Decisions

Hosting: Autohosted

UX: full-screen and app part

APIs: mixture of CSOM and SSOM

Storage: SQL Azure (much better for reporting) for data and SharePoint Library for badges

App Roles/Admin: User permissions from SharePoint app web



  • Advanced Employee Recognition
usage model and licensing
Usage Model and Licensing

Microsoft-owned Azure account

All autohosted apps for SharePoint are provisioned into a Microsoft-owned Azure account that only Microsoft has access to

Licensing through Tenant

Azure hosting costs passed through to tenant…developer doesn’t pay for hosting

App Catalog

Great for company-specific customizations

1 app hosting license = 1 user / app / month

Initial number of free licenses, but more available for purchase by tenant admins

SharePoint Store

Great for ISVs or developers looking capitalize on the app model

Support for autohosted apps is coming soon to the SharePoint store

usage quotas throttlin g
Usage Quotas/Throttling

*Usage quotas can be monitored from SharePoint Online admin portal

key takeaways
Key Takeaways

Easy to Develop

Developing autohosted apps leverages familiar tools, simple deployment, and automatic DR

Simplified Upgrade

Autohosted apps provide a reliable upgrade path and do not impede farm upgrades/patches

Cloud Ready

Autohosted apps were developed to provide an uncompromised cloud experience in Office 365

Rich SharePoint Integration

New APIs allow autohosted apps to run from Azure but richly integrate with SharePoint

Low Cost of Entry for Developers

No more bulky development environment…Visual Studio and a tenant