Creating a SOAP API by importing an API from a URL

Before you begin

Make sure that you have

  • The URL from where you want to import the API.
  • Manage APIs or Activate or Deactivate APIs functional privilege.
    Note: If you are an Administrator, you must have this privilege.

About this task

This example explains how you can create the calculator SOAP API by importing from the http://www.dneonline.com/calculator.asmx?wsdl URL.

Procedure

  1. Open the menu options and select APIs.
  2. Click Create API.
  3. Select Import API from URL.
  4. Provide the URL as http://www.dneonline.com/calculato.asmx?wsdl.
    Note: As the provided URL is public, you do not have to select the Protected checkbox. If you have given the restricted access URL and if the URL is protected by a password, then you must select the Protected checkbox. After you select the Protected checkbox, webMethods API Gateway displays the username and password fields. Make sure that you provide the login credentials of the given restricted access URL. Based on the specification used in the imported file, webMethods API Gateway auto populates the Type field. SOAP API supports the WSDL specifications. As the http://www.dneonline.com/calculator.asmx?wsdl URL is a WSDL file, webMethods API Gateway, by default, selects the file type as WSDL.
  5. Provide the API name as Calculator in the Name field.
    • If you provide an API name, webMethods API Gateway overwrites the API name that is specified in the uploaded file.
    • If you do not provide an API name, the webMethods API Gateway retains the API name that is mentioned in the uploaded file.
  6. Provide the version number as 1.0 for the Calculator API in the Version field.
  7. Select the Type as WSDL because the imported Calculator API URL references a WSDL file.
  8. Provide the description as Performs basic calculations on the numbers that are provided in the Description field.
  9. Select the team as TestAPITeam for which you want to assign the Calculator API in the Team field.
    Note: This field appears when the Team feature is enabled. It displays the teams that you are a part of. If you have the User management functional privilege, all teams are displayed. You can select more than one team.
  10. Click Create.

    The Calculator API is created with the following operations:

    • Add
    • Divide
    • Multiply
    • Subtract
  11. Now that you created the Calculator API, you can check whether it is imported properly by using any of the API testing tools. To know more about how to validate the SOAP API, see Testing the imported SOAP API by using SOAPUI.