Module 5 - Developer Portal

Note

If you remember, we deployed 3 instances. One for the WebApp, one for the APIs and another one for the DevPortal. We will use the latest in this lab.

When we uploaded the OAS3 file, this file included the API documentation as well. There is only one step to publish the documentation into the DevPortal instance.

Step 1 - Create a Dev Portal object

  1. In APIs, then Dev Portals create a new Dev Portal object

    ../../_images/create.png
  2. Configure the object as below
    1. Name: devportal

    2. Display Name: Dev Portal Arcadia

    3. Environment: Production Environment

    4. Gateway: Gateway Dev Portal

    5. Published API: prod-api

      ../../_images/config.png
    6. Click Next

  3. Give a Brand name like API for Arcadia Application, and upload any logo if you want

  4. Click Next and Submit

Step 2 - Navigate to the Developer Portal

  1. RDP to Jumphost as user/user

  2. Open Chrome and click on bookmark Dev Portal APIm
    1. Click on Explore API and Get Started

      ../../_images/devportal.png

Note

Navigate in the Developer Portal. As you can notice, this has been populated automatically thanks to the OAS file. As a reminder, the OAS file looks like that (this is an extract for the buy stock API).

/trading/rest/buy_stocks.php:
  post:
    summary: Add stocks to your portfolio
    requestBody:
      required: true
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/buy'
          example:
            trans_value: '312'
            qty: '16'
            company: MSFT
            action: buy
            stock_price: '198'
    responses:
      '200':
        description: 200 response
        content:
          application/json:
            example:
              status: success
              name: Microsoft
              qty: '16'
              amount: '312'
              transid: '855415223'