Wilson Mar bio photo

Wilson Mar

Hello. Hire me!

Email me Calendar Skype call 310 320-7878

LinkedIn Twitter Gitter Google+ Youtube

Github Stackoverflow Pinterest

SaaS-only, proprietary. Get it for .NET


Overview

Microsoft on Azure is one of several API management/governance vendors I evaluated.

“Publish, manage, secure, and analyze your APIs in minutes” is Microsoft’s tag line at Microsoft’s API Management home page (Service Overview).

Microsoft’s service is based on its October 23, 2013 acquisition of APIphany (based in Wash. DC).

Documentation is published from markup text in a GitHub which directs people to the classic portal at manage.windowsazure.com rather than the newer portal.azure.com site using Azure Resource Manager (ARM).

NOTE: There is no Issues tab in their GitHub.

  • The roadmap is not public.

  • Issues with the API service where each public can allocate 25 voting points among proposals.

    The top request (May 2016) is Web Hooks in ASP.NET, a set of Nuget packages for web apps to send and receive WebHooks from external services using a common HTTP pattern. http://neelbhatt2015.blogspot.in/2015/12/webhooks-in-aspnet-visual-studio.html This won’t get the scale, performance, or analytics Azure Event Hubs provides, though.

  • The pricing page states there is no on-premises deployment option available at this time.

Create Publisher portal

  1. Get a Microsoft Azure account
  2. Create a Resource (Free trial)
  3. Specify Scale: Developer or Standard.

    Standard tier can go up to 4 instances to handle 800 million calls/month. QUESTION: No auto-scaling?

  4. TODO: Custom SSL cert
  5. TODO: Custom domain (developer.itworks.com)

Create service

  1. Select service:

    azure-api-create-2154x508

  2. Click Create.
  3. Specify the prefix to .azure-api.net (such as itw1).
  4. Select subscription (Free Trial, etc.).
  5. Select Region.

  6. Specify Organization name.
  7. Specify Administrator Email.
  8. Click check icon.

  9. Use browser to visit the page, such as https://itw1.portal.azure-api.net

  10. Edit look and feel by clicking on the edit icon at the upper left.

    api-azure-styling

  11. TODO: Edit site title (instead of “Azure Api Management API”).

    api-azure-admin

Create Gateway

  1. Click Import API in publisher portal dashboard.
  2. Select From URL.
  3. Select Specification format: Swagger (no RAML).
  4. In Specification document URL field, paste http://calcapi.cloudapp.net/calcapi.json.
  5. Provide a Web API URL suffix, e.g. ‘calc’.
  6. Type ‘Starter’ in the products field to add your API to the ‘Starter’ product.

    NOTICE:

    https://itw1.azure-api.net/calc

  7. Click Save.
  8. Click Operations tab.

    Notice the GET Add, Divide, Multiply, Substract two integers.

Policy scope

  • Policy statements
  • Allow cross domain calls
  • Authenticate with Basic
  • Authenticate with client certificate
  • Check HTTP header
  • Control flow
  • Convert JSON to XML
  • Convert XML to JSON
  • CORS
  • Find and replace string in body
  • Forward request to backend service
  • Get from cache
  • Get value from cache
  • JSONP
  • Limit call rate per key
  • Limit call rate per subscription
  • Log to EventHub
  • Mask URLs in content
  • Remove value from cache
  • Restrict caller IPs
  • Return response
  • Rewrite URL
  • Send one way request
  • Send request
  • Set backend service
  • Set body
  • Set context variable
  • Set HTTP header
  • Set query string parameter
  • Set request method
  • Set status code
  • Set usage quota per key
  • Set usage quota per subscription
  • Store to cache
  • Store value in cache
  • Validate JWT
  • Wait for…

Examples:

https://github.com/Azure/api-management-samples/tree/master/policies

  • Hide response data based on product name.policy.xml
  • Pre-authorize requests using validate-jwt.policy.xml
  • Send context information to the backend service.policy.xml
  • Set cache duration using cache control header.policy.xml

Open the developer portal

  1. Click on APIs.
  2. Pick Calculator API from the list on the left.
  3. Click on Open Console for any API.
  4. In the console, enter values for the parameters and hit the HTTP button.

  5. Search

    NOTE: API Management is in category “Web + Mobile”.

“Take any API and publish it to developers and partners in minutes

  • Provide API documentation and an interactive console
  • Throttle, rate limit and quota your APIs
  • Monitor the health of your APIs and quickly identify errors
  • Bring modern formats like JSON and REST to existing APIs
  • Connect to on-premises systems and publish globally
  • Gain analytic insights on how your APIs are being used

http://azure.microsoft.com/marketplace/partners/microsoft/apimanagement/ marketplace

  • Service Overview
  • Getting Started
  • Documentation
  1. Click Create to open a new window.

When created, the Echo API is created as a sample.

http://apidemo.azure.api.net/echo

http://echo.cloudapi.net/calc/

Authentication

Delegating User Authentication and Product Subscription to a 3rd Party

Developer Portal Setup

  1. Add discussion board and ratings

Swagger import

A Swagger 2.0 doc can be imported, but the doc MUST contain Host, BasePath, Schemes properties. Otherwise, it won’t get imported: No message. It just hangs with “working..”.

Analytics:

In the Summary graph, detail for a point in time can be obtained with mouse-over:

  • Response time (in ms)
  • Bandwidth usage KB
  • Successful? Popular === Volume of calls.
  • Errors === Number of calls blocked due to limits?

Notice the pre-defined filters for Today, yesterday, Last 7 Days, Last 30 Days, Last 90 Days

Activity chart provides reports that drill down on the specific activity by developer, product, API, and operation.

What about:

  • Specific translations performed
  • Specific policies violated
  • metrics by geography
  • Correlation of two metrics (response time vs bandwidth scattergram)

  • Issues over time

Videos

My recommendation for the sequence to view videos about API Management

  1. Introducing Azure API Management TechEd North America 2014 by Josh Twist (@joshtwist)

    • Business models
    • Engaging developers: Time to First Successful call
    • Make legacy API (SOAP XML) modern (REST JSON)
    • Understand their behavior with monitoring
  2. Introduction to API Management on Microsoft Azure at TechEd Europe 2014

  3. Microsoft Azure API Management Master Class: In Depth for Fun and Profit at TechEd North America 2014 by Anton Babadjanov | antonba@ | @antonbaa | https://www.linkedin.com/in/anton-babadjanov-44501b9 and Vlaimir Vinogradsky | vlvinogr@

    This explores the end-to-end workflow of launching a “treasure hunt” API and play a game with it. We’ll also take a peek at what the future holds for this exciting new Azure service.

  4. Azure Api Management by Ajay Solanki

  5. API Management Overview (cartoon) 03-25-2015 Overview video of the Azure API Management service

  6. Adding Developer Portal functionality using Templates in Azure API Management by Matt Farmer

    uses Contoso API:
    http://contosoapim.azure-api.net/calc/add?a=(a)&b=(b)

    Response: { “statusCode”: 404, “message”: “Resource not found” }

  7. Configure your API Management instance using Git 03-12-2016 by Anton Babadjanov | @antonbaa | https://www.linkedin.com/in/anton-babadjanov-44501b9 Access and modify the configuration of your API Management instance using Git. Configure Security > Configuration: This enables scenarios:

    • Managing multiple configuration versions
    • Syncing the configuration of multiple tenants
    • Utilizing the Git workflow for collaborative editing
    • Text-file based configuration for flexibility
  8. API or No API - On Cloud Feb 23, 2016 By: Lachezar Arabadzhiev, Jef King Take reads off data store. Have a worker rule read out From a SQL database every 30 secs to stick into blob storage with CDN fed to users.

  9. API Management in under 5 minutes 06-16-2014 Shows the classic portal to https://wellmark1.portal.azure-api.net/ This video shows how Wellmark Blue Cross & Blue Shield use Azure API Management to accelerate their partners in adopting the Wellmark API,

  10. Episode 177: More API Management Features with Vlad Vinogradsky 06-12-2015 42 min, 07 sec

    In this episode Chris Risner is joined by Vlad Vinogradsky, Principal Program Manager on the Azure API Management Team. Vlad joins us to talk about some of the latest features…

  11. Episode 176: Logic Apps with Stephen Siciliano 05-29-2015

    In this episode Chris Risner and Haishi Bai are joined by Stephen Siciliano, Program Manager on Azure App Service. Stephen joins us to demonstrate Logic Apps.

  12. Getting Started with Azure API Management REST API 12-01-2014 Azure API Management provides a REST API for performing operations on selected entities, such as APIs, users, groups, products, and subscriptions. The API can be used fo…

  13. Integrate Azure API Management with Event Hubs Nov 09, 2015 at 2:01PM By: Miao Jiang This video demonstrates how to use the log-to-eventhub policy to build a custom dashboard with Azure Stream Analytics and PowerBI.

  14. Azure API Management Update BizTalk360

Social media:

  • @AzureAPIMgmt

  • Mailto: apimgmt@microsoft.com

  • https://social.msdn.microsoft.com/Forums/en-US/home?sort=relevancedesc&brandIgnore=True&searchTerm=api+management Microsoft forum topics

https://www.youtube.com/results?search_query=apimanagement

Conferences

#integrate2016 conference

Partners

@KloudSolutions

https://api.kloud.com.au/

{version}/{entity-set}/{id}/{property}

V1/user/cd1311/files

APIMatic

AutoRest

@infront

@SixPivot

https://twitter.com/SwaggerApi

Scalability

https://social.msdn.microsoft.com/Forums/azure/en-US/97a0b1e9-bdd1-480c-a5c3-f4e3a5e7444f/scale-to-millions-of-api-calls?forum=azureapimgmt

Pricing

http://azure.microsoft.com/pricing/details/api-management/

Stars

Jorge Arteiro

  • http://aka.ms/melgabdev4
  • jorgearterio@hotmail.com
  • @jorgearteiro
  • @Azuretar
  • Azuretar.com

Matthew Snider [masnider@MSFT]

App Fabric Instead

Build your own.

Microsoft Service Fabric (in GA April 2016) has several free “party” clusters that last for less than 4 hours each.

Service Fabric programming model focus on:

  • Reliable Actors,
  • Reliable Services,
  • custom application orchestration, and
  • Service Fabric management tasks.

In order to build and run Azure Service Fabric applications on your development machine, you need to install the runtime, SDK, and tools. You also need to enable execution of the Windows PowerShell 3.0 scripts included in the SDK.

To use Service Fabric PowerShell cmdlets on Windows 7, which includes Windows PowerShell 2.0 by default, download the Windows Management Framework 5.0 which includes PowerShell 3.0 as well as Desired State Configuration (DSC), Windows Remote Management (WinRM), Windows Management Instrumentation (WMI). See http://go.microsoft.com/fwlink/?LinkID=717903

The Party Cluster is created by code at https://github.com/Azure-Samples/service-fabric-dotnet-management-party-cluster

Not AzurePS

The local cluster manager :

“C:\Program Files\Microsoft SDKs\Service Fabric\Tools\ServiceFabricLocalClusterManager\ServiceFabricLocalClusterManager.exe”

Pin this to the taskbar.

Microsoft Service Fabric is about more than API management. Its features and patterns for application development, including:

  1. Stateful Reliable Services with Reliable Collections.
  2. Dependency injection and unit testing with Reliable Services.
  3. How to use Service Fabric configuration packages, both the built-in Settings.xml config and custom JSON configuration, with rolling updates without restarting services.
  4. How to encrypt sensitive data in Service Fabric configuration packages.
  5. Inter-service communication using the Service Fabric remoting stack.
  6. Diagnostics with Elastic Search through ETW event sources.
  7. How to write a stateless Web API front-end service.

https://azure.microsoft.com/en-us/documentation/services/service-fabric/ videos

https://azure.microsoft.com/en-us/documentation/samples/?service=service-fabric Sample apps

Logic Apps

Resources

  • PowerShell Deployment Toolkit (PDT) is a set of scripts and knowledge for automated deployment of System Center 2012 SP1/R2, including SQL and all prerequisites, and all automatable post-setup integration.

More on DevOps

This is one of a series on DevOps:

  1. DevOps_2.0
  2. ci-cd (Continuous Integration and Continuous Delivery)
  3. User Stories for DevOps

  4. Git and GitHub vs File Archival
  5. Git Commands and Statuses
  6. Git Commit, Tag, Push
  7. Git Utilities
  8. Data Security GitHub
  9. GitHub API
  10. TFS vs. GitHub

  11. Choices for DevOps Technologies
  12. Java DevOps Workflow
  13. AWS DevOps (CodeCommit, CodePipeline, CodeDeploy)
  14. AWS server deployment options

  15. Digital Ocean
  16. Cloud regions
  17. AWS Virtual Private Cloud
  18. Azure Cloud Onramp
  19. Azure Cloud
  20. Azure Cloud Powershell

  21. Packer automation to build Vagrant images
  22. Terraform multi-cloud provisioning automation

  23. Powershell Ecosystem
  24. Powershell on MacOS
  25. Powershell Desired System Configuration

  26. Jenkins Server Setup
  27. Jenkins Plug-ins
  28. Jenkins Freestyle jobs
  29. Jenkins2 Pipeline jobs using Groovy code in Jenkinsfile

  30. Dockerize apps
  31. Docker Setup
  32. Docker Build

  33. Maven on MacOSX

  34. Ansible

  35. MySQL Setup

  36. SonarQube static code scan

  37. API Management Microsoft
  38. API Management Amazon

  39. Scenarios for load

More on APIs

This page is one of a series about APIs: