Web APIs
- Last UpdatedJul 01, 2025
- 3 minute read
Web APIs are frameworks to build HTTP services for browsers and mobile devices. Use Web APIs to customize your business applications.
To add a Web API
-
In the Enterprise Console, click the Menu button, click Settings, and then click Web API.
The Web API List page appears.
-
Click New.
The Web API List Item wizard appears.
-
In the Name box, type a name for the API.
-
In the Description box, type a description for the API.
-
In the Source box, select the generic Web API or the Web API Source List Item.
-
If you select the generic Web API, you need to provide the Base Address, Request URI, and Authentication Mode.
-
If you select the Web API Source List item, the Advanced Option is available. Select Yes to provide the Base Address, Request URI, and Authentication Mode.
The SwaggerUrl is displayed when the Web API is configured from Swagger. The Web API schema is fetched from Swagger file.
-
-
In the Base Address box, type a URL in the format: http://localhost/MySite/.
You can also enter an IPv6 URL for the Base Address. The IPv6 address must be enclosed within square brackets.
Important: To prevent security vulnerabilities such as Server-Side Request Forgery (SSRF), access to the Azure Instance Metadata Service (IMDS) is blocked for the IP addresses 169.254.169.254 and 168.63.129.16. A validation error is displayed, and the Web API configuration cannot be saved with these addresses.
-
In the Request URI box, type a URI. This is an optional parameter.
For example, api/product/1 for http://localhost/MySite/api/product/1 (for Request URI without parameters) or api/{product}/{ID} for http://localhost/MySite/api (for Request URI with parameters).
-
Select one of the following options for Authentication Mode:
-
No Authentication: If the Web API does not require authentication.
-
Windows: If the Web API is Windows authenticated.
-
User Access Token: If the Web API requires the currently logged-in user's access token.
Note: If User Access Token is configured for the Web API and associated with Scheduler Event Association, the workflow fails.
-
Basic Authentication: If the Web API requires basic authentication. Provide the user name with domain and the password.
-
Certificate: If the Web API requires certificate authentication. Provide the certificate store location and the thumbprint. For more information on certificate-based authentication, see Web API Certificate-based Authentication.
Note: The thumbprint should not contain any spaces. In some machines, the characters in thumbprint should be in upper case.
-
Service to Service Access Token: If the Web API requires Service to Service Access Token. To get the Access Token, provide Authority URL, Audience, Client ID, Client Secret, and Scope.
In the Authority URL, provide the token end-point of the respective repository provider. For example,
CONNECT: {authority url}/oauth/token
Microsoft Entra ID: {authority url}/oauth2/v2.0/token
AVEVA Identity Manager: {authority url}/connect/token
-
-
Do one of the following:
-
Test the Web API server connection.
-
Click Test Server. An information message appears.
Note:
- The Request URI and Authentication Mode details are not required to test the Web API connection.
- The Web API connection is successful if the site is pointing to the default IIS port, the Server is running but the Application Pool is stopped.
- The Web API connection is unsuccessful if the Server, Site, or IIS is stopped.
-
-
Preview the data fetched using the Web API.
-
Click Preview. The Preview dialog box appears.
Preview is available only for .json file format.
-
Check the data fetched using the Web API.
-
Click Close (or click the Close button). The Preview dialog box is closed.
-
-
Save the Web API.
-
Click Save & Close. The API is added, and an information message appears.
-
Click OK (or click the Close button). The information message is closed.
-
-
Note:
- You can pass parameters in the Request URI using braces { }.
- For example, api/{product}/{ID} for http://localhost/MySite/api.
- If the Web API is Windows authenticated, then the status of the Windows Authentication must be set to Enabled for the EnterpriseConsole site under AVEVAWorkTasksSites site in the IIS Manager. Also the Web API must always be hosted in the AVEVA Work Tasks web server machine.
- If a Web API method (action) is modified, then you must create the web API List
Item, the Web API Lookup, or the Web API activity again.
- Web APIs can recognize the response received in the ODATA (Open Data Protocol) format.
- The Preview option is available only for Web APIs, which support JSON format.
- The Preview button is enabled only when Request URI is provided.