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

DotNetDay18: Building Cross-Platform Server-Side Data APIs by Julie Lerman

DotNetDay18: Building Cross-Platform Server-Side Data APIs by Julie Lerman

Front ends are cool but mostly useless without data. Sure, some of your data sources provide REST APIs so you can just write queries directly against them but that is so old school. Instead, you can build back end APIs that address the specific data needs of your web application and relieve front end devs from tangling with database schema, query syntax and other distractions. In this session you’ll learn the basics of creating a back end API as well as some smart architectural guidance to make moving data between your front end and your data store. We'll start with an ASP.NET Core Web API, EF Core and a relational database, then look at a data API built with Azure Functions to support a Cosmos DB document database.

https://github.com/julielerman/2018DataApi
www.about.me/julielerman
www.thedatafarm.com

dotnetday

May 29, 2018
Tweet

More Decks by dotnetday

Other Decks in Programming

Transcript

  1. Two Types of Data APIs ASP.NET Core Web API “Demo-ware”

    à Better architectural practices ASP.NET Core 2.1, EF Core 2.1, SQLite Serverless Data API Azure Functions via Azure Portal Integrate with Azure Cosmos DB
  2. üCreate a new character with just a name üCreate a

    new character with name and entrance üInsert a full character graph as a [valid] JSON object üAdd a quote to an existing character üAdd or replace an entrance to an existing character üRetrieve a list of character names with ID üRetrieve a full set of data for a single character Actions I Want My API to Enable
  3. A Trio of Azure Functions HTTPTrigger Body: Phone # Output

    to Collection 1: SampsonAte Collection 2: Subscribers HTTPTrigger Body: He Ate! Output to Cosmos DB Trigger Read from subscriber collection SMS to subscribers Cosmos DB Database
  4. Resources The code from this demo will be at github.com/julielerman/2018DataApi

    Julie’s Pluralsight Author Page bit.ly/2t6m83w (newest courses: EF Core 2: Getting Started, EF Core 2: Mappings) ASPNetCore: dot.net EF Core: docs.microsoft.com/efcore January 2018 MSDN Magazine Data Points column: Creating Azure Functions to Interact with Cosmos DB Azure CosmosDb: aka.ms/CosmosDb Azure Functions: aka.ms/Azure/Functions Julie Lerman thedatafarm.com @julielerman about.me/julielerman