Patent attributes
A mocking service generates a mock implementation of an API based on a API specification. Request and response behavior of the mock implementation of the API may be controlled by a separate API behavior file. The API behavior file may be parsed by the mocking service to generate behavior logic. When an API request is transmitted to the mock implementation of the API, the behavior logic is invoked and may control execution of the mock implementation of the API and the details of a generated response. Behaviors defined in the API behavior file may be global or resource specific and may include, for example, time delays, error rates, error codes, conditions, response overrides, etc.