Upgrade to Pro — share decks privately, control downloads, hide ads and more …

Building Mobile First Experiences on Box Platform

Building Mobile First Experiences on Box Platform

With Box Platform, you can now build modern mobile experiences for your customers, employees and partners. This workshop covers:
- How to build mobile-first experiences on Box platform
- How to improve account and data access security through proper token management.
- Hands-on training with the latest Box developer tools, including the new iOS SDK

Jonathan LeBlanc

September 12, 2019
Tweet

More Decks by Jonathan LeBlanc

Other Decks in Technology

Transcript

  1. Building mobile-first experiences on Box Platform Jonathan LeBlanc Director of

    Developer Advocacy, Box Twitter: @jcleblanc Github: https://github.com/jcleblanc
  2. 3 Box Platform Developer Workshop 1.Native mobile SDKs in Box.

    2.Setting up a Box application with the Swift SDK. 3.Generating and refreshing tokens for mobile environments. 4.Increasing token security with downscoping techniques. 5.Cross platform mobile development UI tools. What are we looking at today?
  3. 5 Box Platform Developer Workshop Android SDK iOS SDK Swift

    SDK (beta) Available Native Mobile SDKs
  4. 7 Box Platform Developer Workshop Access Token Best Practices /

    Access tokens are valid for 1 hour and should be stored / reused. / Official server-side SDKs (Node, Java, .Net, Python) automatically refresh tokens. If these SDKs aren’t used, tokens need to be maintained manually. / Expired tokens will return a 401: Unauthorized error. This error should be handled to refresh the token. / JWT applications do not return a refresh token, use your standard auth credentials.
  5. 9 Box Platform Developer Workshop Downscoped Token Access Token Client-Side

    Code Downscoped token is deployed to client-side code, mobile environment, or UI tool. New access token that is tightly restricted in access rights (read / write) for a file or folder. Standard OAuth2 access token that is fully scoped for an enterprise or user. Token Downscoping Process
  6. 10 Box Platform Developer Workshop client.exchangeToken(appConfig.tokenScopes[service]).then((tokenInfo) => { // token

    available in tokenInfo.accessToken }).catch((err) => { console.error(err); }); Downscoping a Token (Node SDK)
  7. 11 Box Platform Developer Workshop Live Example • Setting up

    your package manager • Setting up the sample JWT application. • Setting up your token generation server code. • Improving the security of your token generation code with downscoping. Setting up your application with the Box Swift SDK
  8. 15 Box Platform Developer Workshop Box Embed Box View Box

    Elements Available UI and Embeddable Tools
  9. 16 Box Platform Developer Workshop Box View • HTML5 based

    component to embed the native Box file preview capabilities. • Responsive design to work across different devices and environments. • Uses a separate application type on the developer console, App Token Auth • App Token Auth only allows access to the following API functions: Upload File, Download File, Delete File, and Get Embed Link. Embedding preview capabilities for Box files in your own site
  10. 19 Box Platform Developer Workshop Box Embed • HTML5 based

    component to embed the entire box.com site, via an iframe, directly into your site or service. • Limited responsive capabilities with the iframe. • Uses a shared link for embedding content. Embed the entire box.com site into your own site or service
  11. 20 Box Platform Developer Workshop Box Elements • UI components

    built with React Native (JavaScript library). • Authentication and token agnostic: Works with JWT and OAuth flows. • User type agnostic: Works with app, managed, and external user types. Embed and customize common functionality of box.com in your own site.
  12. 21 Box Platform Developer Workshop Content Explorer Navigate Box files

    and folders within your app. Content Picker Select Box files and folders within your app Content Preview View docs, images, videos, 3D files, and more within your app Content Uploader Drag and drop files from a device into your app / Box. Open With Load Box content using G Suite, Adobe Sign, and more Sidebar See file attributes, statistics, and metadata.
  13. 22 Box Platform Developer Workshop Live Example • Setting up

    your first content explorer application. • Integrating downscoped tokens and special scopes. Building cross platform apps with Box Elements
  14. Building mobile-first experiences on Box Platform Jonathan LeBlanc Director of

    Developer Advocacy, Box Twitter: @jcleblanc Github: https://github.com/jcleblanc