Skip to main content

required-request-server-base-url

Overview

This rule belongs to the postman-validation ruleset and states that:

The URL defined for a Postman Collection request must be non-empty and an absolute path. This is essential for determining the base URLs of one or more servers that serve the current API. If a base URL cannot be determined, a default dummy value for base URL will be assumed automatically during import/transformations in APIMatic.

PropertyValue
EnabledYes
Maximum SeverityError
MessageServer base URL could not be determined from any Postman Collection request.
CodePOSTMAN_V150
TypeValidation
Rule SystemSemantic
Broad CategoryAPI Servers
Products ImpactedAPI Transformer, Code Generation, Developer Experience Portal
Tagspostman api semantic validation base url url server request

Suggested Fixes

  • For Postman Collections v1.0, ensure that every request definition has a non-empty absolute URL path set for the url property.
  • For Postman Collection v2.0 and above, ensure that the url property in an item's request definition is not empty or null.
  • For Postman Collection v2.0 and above, if the URL is defined as a string value in the item's request, ensure that it is non-empty and an absolute URL path.
  • For Postman Collection v2.0 and above, if the URL is defined as an object, ensure that information for protocol and host is provided and is valid.
  • In the Postman application, open each request and ensure that value for its URL is set as an absolute path in the input field next to the HTTP method, save and export the collection and then try again.

For More Information