Sign in to the API Publisher and click ADD NEW API.
The WSDL URL and WSDL Archive/File options that are shown in the following screenshot, which allow you to modify API resources, are only available as a WUM update and is effective from 18th October 2018 (2018-10-18). For more information on updating WSO2 API Manager, see Updating WSO2 API Manager.
Select I Have a SOAP Endpoint in order to design an API with an existing SOAP endpoint, and thereafter, select Pass Through, and select one of the following options:
WSDL URL - If you select this option, you need to provide an endpoint URL.
WSDL Archive/File - If you select this option, click Browse and upload either an individual WSDL file or a WSDL archive, which is a WSDL project that has multiple WSDLs.
When uploading a WSDL archive, all the dependent wsdls/xsds that are referred in the parent WSDL file should reside inside the WSDL archive itself. If not, the validation will fail at the point of API creation.
This example uses the following WSDL URL from CDYNE as the endpoint here, but you can use any SOAP backend of your choice.
Click Start Creating.
Proceed to finish creating and publishing the API.
The Design tab of the API opens. Give the information in the table below and click Next: Implement > to proceed to the implementation phase.FieldSample value
Name PhoneVerification Context
- Click the Managed API option.
- Select HTTP/SOAP Endpoint, provide the production endpoint (in this example,
In the Manage tab, select the Gold tier, scroll down and click Save & Publish.
If you wish to add scopes to the resources that were created, click Add Scopes and specify the scopes you want to add. If you specify a scope, you need to use the same scope when generating access tokens for the subscribed application and when invoking the API. For more information on working with the scopes, see OAuthscopes.
Note that when creating this API, the default option, Apply per Resource, was selected under Advanced Throttling Policies. For more information on setting advanced throttling policies, see Enforce Throttling and Resource Access Policies.
For more information on API authentication (e.g., non authentic API invocation), see HTTP methods.
You have now published the SOAP API to the API Store. Let's subscribe to it.
When prompted, choose to open the newly published API in the API Store.
The API (namely the SoapTest API) opens.
If you click on the Overview tab with regard to a SOAP API, you will be able to download the WSDL for the API.
Select an application (e.g., DefaultApplication), the Gold tier and subscribe to the API.
- Click the View Subscriptions button when prompted. The Subscriptions tab opens.
- Click the Production Keys tab and click Generate Keys to create an application access token. If you have already generated keys before, click Regenerate. By default, access tokens expire an hour after creation, unless you change the expiration time.
Let's invoke the API.
- On the APIs menu, select the API and click the API Console tab.
Expand the POST method and click Try it out. Enter the following, and click Execute to invoke the API.
SOAP Request Code Block
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:quer="http://ws.cdyne.com/PhoneVerify/query"> <soapenv:Header/> <soapenv:Body> <quer:CheckPhoneNumber> <!--Optional:--> <quer:PhoneNumber>18006785432</quer:PhoneNumber> <!--Optional:--> <quer:LicenseKey>0</quer:LicenseKey> </quer:CheckPhoneNumber> </soapenv:Body> </soapenv:Envelope>
Note the API response that appears on the console.