Skip to content

Commit

Permalink
updating navigation and simplifyin challenges
Browse files Browse the repository at this point in the history
  • Loading branch information
ferantoMSFT committed Sep 7, 2021
1 parent 40c8082 commit 6bd30b7
Show file tree
Hide file tree
Showing 28 changed files with 799 additions and 723 deletions.
23 changes: 0 additions & 23 deletions apim-lab/0-labPrerequisites/apimanagement-prerequisites.md

This file was deleted.

15 changes: 14 additions & 1 deletion apim-lab/0-labPrerequisites/index.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,22 @@
---
title: Prerequisites
has_children: true
has_children: false
nav_order: 1
---


## Check you have everything ready to do the workshop

Please check that you have the following requirements to complete the Hands on Lab:

- Azure requirements
- Access to the [Azure Portal](https://www.portal.azure.com)
- Access to an active [Azure subscription](https://portal.azure.com/#blade/Microsoft_Azure_Billing/SubscriptionsBlade)
- Contributor Role in a resource group to be able to deploy an api management instance
- During Part 3 of this lab, we will add existing apis to our api management instance. The following apis/websites should be available:
- [Colors api](https://markcolorapi.azurewebsites.net/swagger/), in case this website is down you can deploy your own api using the following [instructions](apimanagement-A.md).
- [Colors web](https://markcolorweb.azurewebsites.net/), in case this website is down you can deploy your own api using the following [instructions](apimanagement-A.md).
- [Starwars api](https://swapi.dev/)
- [Calculator api](http://calcapi.cloudapp.net/calcapi.json)
- For part 8 you need to have access to a valid Azure Devops organization [azure devops](https://dev.azure.com)

34 changes: 0 additions & 34 deletions apim-lab/1-apimCreation/apimanagement-1.md

This file was deleted.

26 changes: 25 additions & 1 deletion apim-lab/1-apimCreation/index.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,33 @@
---
title: Azure Apim Creation
has_children: true
has_children: false
nav_order: 2
---

## Create an API Management instance

An instance can take sometime to provision - so have one created in advance of any demo.

[![Deploy to Azure](https://azuredeploy.net/deploybutton.png)](https://portal.azure.com/#create/Microsoft.ApiManagement)

![Deploy blade](../../assets/images/APIMDeployBlade.png)

Use appropriate values and hit [Create] to provision the service.

- The service name must be unique.
- For demo purposes, use the Developer tier.

![API Management](../../assets/images/APIManagement.png)

Once the service has been provisioned, there will be:

- Publisher Administration - (now located in the Azure Management Portal - the older Publisher portal has now been deprecated)
- Developer portal
- Gateway


The link to the developer portal is at the top of the Overview blade.

![](../../assets/images/APIMOverviewBlade.png)


Original file line number Diff line number Diff line change
@@ -1,13 +1,10 @@
---
title: Getting started
title: Publishing Developer Portal
parent: Developer Portal
has_children: false
nav_order: 1
---

## Developer Portal

The developer portal is an automatically generated, fully customizable website with the documentation of your APIs. It is where API consumers can discover your APIs, learn how to use them, request access, and try them out.

### Publishing the developer portal

Expand Down Expand Up @@ -85,58 +82,7 @@ It's now time to test one of the published APIs. Open the APIs page and look at

![](../../assets/images/APIMDevTryAPI2.png)

### Customising the Developer Portal

#### Site Configuration

The developer portal is based on a fork of the Paperbits Web framework <https://paperbits.io/>, and is enriched with API Management-specific features. The fork resides at <https://github.com/Azure/api-management-developer-portal>.

It is possible to self-host, and manage your own developer portal outside of an API Management instance. It's an advanced option, which allows you to edit the portal's codebase and extend the provided core functionality. This is documented at <https://github.com/Azure/api-management-developer-portal/wiki>/ and <https://docs.microsoft.com/en-us/azure/api-management/api-management-howto-developer-portal>.

Before you make your portal available to the visitors, you should personalize the automatically generated content. Recommended changes include the layouts, styles, and the content of the home page. This is documented at <https://docs.microsoft.com/en-us/azure/api-management/api-management-howto-developer-portal-customize>

Video on customization is available at <https://www.youtube.com/watch?v=5mMtUSmfUlw>

![](../../assets/images/APIMDevConfig.png)

![](../../assets/images/APIDevConfig2.png)

![](../../assets/images/APIMDevStyles.png)

#### Email Configuration

The templates for the email notifications are managed from the Azure Management Portal, directly on the blade's side menu.
Look at the available notifications and notifications templates which are customizable

![](../../assets/images/APIMNotifications.png)

![](../../assets/images/APIMNotificationTemplates.png)

![](../../assets/images/APIMNotificationEdit.png)


### Product Management

A product contains one or more APIs as well as a usage quota and the terms of use. Once a product is published, developers can subscribe to the product and begin to use the product's APIs.

#### Product definition

Again in the Azure Management portal, open the left menu `Products `

![](../../assets/images/APIMProducts.png)

Add a new product - for example a Gold tier - change its visibility (Published) and click on the [Create] button

![](../../assets/images/APIMAddProduct.png)

![](../../assets/images/APIMAddProduct2.png)

Set Access Controls to allow access to developers and guests

![](../../assets/images/APIMAddProductsAccess.png)

Once saved, see the new Gold Tier product in the Developer portal

![](../../assets/images/APIMAddProductsDevPortal.png)


36 changes: 36 additions & 0 deletions apim-lab/2-developerPortal/apimanagement-2-2-Customization.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
---
title: Customizing Developer Portal
parent: Developer Portal
has_children: false
nav_order: 2
---


### Customising the Developer Portal

#### Site Configuration

The developer portal is based on a fork of the Paperbits Web framework <https://paperbits.io/>, and is enriched with API Management-specific features. The fork resides at <https://github.com/Azure/api-management-developer-portal>.

It is possible to self-host, and manage your own developer portal outside of an API Management instance. It's an advanced option, which allows you to edit the portal's codebase and extend the provided core functionality. This is documented at <https://github.com/Azure/api-management-developer-portal/wiki>/ and <https://docs.microsoft.com/en-us/azure/api-management/api-management-howto-developer-portal>.

Before you make your portal available to the visitors, you should personalize the automatically generated content. Recommended changes include the layouts, styles, and the content of the home page. This is documented at <https://docs.microsoft.com/en-us/azure/api-management/api-management-howto-developer-portal-customize>

Video on customization is available at <https://www.youtube.com/watch?v=5mMtUSmfUlw>

![](../../assets/images/APIMDevConfig.png)

![](../../assets/images/APIDevConfig2.png)

![](../../assets/images/APIMDevStyles.png)

#### Email Configuration

The templates for the email notifications are managed from the Azure Management Portal, directly on the blade's side menu.
Look at the available notifications and notifications templates which are customizable

![](../../assets/images/APIMNotifications.png)

![](../../assets/images/APIMNotificationTemplates.png)

![](../../assets/images/APIMNotificationEdit.png)
32 changes: 32 additions & 0 deletions apim-lab/2-developerPortal/apimanagement-2-3-ProductManagement.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
---
title: Product Management
parent: Developer Portal
has_children: false
nav_order: 3
---


### Product Management

A product contains one or more APIs as well as a usage quota and the terms of use. Once a product is published, developers can subscribe to the product and begin to use the product's APIs.

#### Product definition

Again in the Azure Management portal, open the left menu `Products `

![](../../assets/images/APIMProducts.png)

Add a new product - for example a Gold tier - change its visibility (Published) and click on the [Create] button

![](../../assets/images/APIMAddProduct.png)

![](../../assets/images/APIMAddProduct2.png)

Set Access Controls to allow access to developers and guests

![](../../assets/images/APIMAddProductsAccess.png)

Once saved, see the new Gold Tier product in the Developer portal

![](../../assets/images/APIMAddProductsDevPortal.png)

2 changes: 2 additions & 0 deletions apim-lab/2-developerPortal/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@ has_children: true
nav_order: 3
---

## Developer Portal

The developer portal is an automatically generated, fully customizable website with the documentation of your APIs. It is where API consumers can discover your APIs, learn how to use them, request access, and try them out.


62 changes: 62 additions & 0 deletions apim-lab/3-addingApis/apimanagement-3-1.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,62 @@
---
title: Add API from scratch
parent: Adding API's
has_children: false
nav_order: 1
---



#### APIs

On the left menu, open the [APIs] blade. You will see all APIs, the possibility to add new ones but also to customize existing ones

![](../../assets/images/APIMListAPIs.png)

![](../../assets/images/APIMAddAPIs.png)

#### Add API from scratch

Instead of coding an API, for this lab you will use the existing *Star Wars API* <https://swapi.dev>.

- Click on [Add API]
- Select [Add Blank API]
- Select the [Full] option at the top of the dialog
- Enter Display name, name and description
- Enter back end Web Service - this is <https://swapi.dev/api>
- Set API URL suffice to "sw"
- Assign Products - Starter and Unlimited
- Create

![](../../assets/images/APIMAddBlankAPI.png)

Once created, select [Start Wars API]

![](../../assets/images/APIMAddStarWars.png)

Lets declare two operations
- **GetPeople** GET /people/ ... use lowercase
- **GetPeopleById** GET /people/{id}/ ... use lowercase

![](../../assets/images/APIMAddSWGetPeople.png)

![](../../assets/images/APIMAddSWGetPeopleById.png)

![](../../assets/images/APIMAddSWOperations.png)

Switch now to the Developer Portal
- Sign in as a developer with a subscription
- Select [Start Wars API]

![](../../assets/images/APIMSWTryIt1.png)

- Try the "GetPeople" operation
- Try the "GetPeopleById" operation ... with id = 2

![](../../assets/images/APIMSWTryIt2.png)

Examine Response and more detailed Trace information
- Response 200 successful
- Information about C-3PO in the Response body payload.

![](../../assets/images/APIMSWTryIt3.png)
Loading

0 comments on commit 6bd30b7

Please sign in to comment.