Skip to main content
Update an existing mocking rule. Changes may take a few seconds to take effect.
External DocumentationTo learn more, visit the Beeceptor documentation.

Parameters

ParameterDescription
DelayThe response delay in milliseconds before returning the mocked response.
DescriptionAn optional description to help identify and organize the rule.
EnabledSelect Enabled to activate the rule or Disabled to deactivate it. Disabled rules are not applied to incoming requests.
Endpoint Match - HTTP MethodThe HTTP method that incoming requests must match.
Endpoint Match - OperatorSelect how the rule matches incoming requests against the specified value.
Endpoint Match - ValueThe value to match against incoming requests, based on the selected operator (path, regex pattern, body content, or header value).
Endpoint NameThe name of the endpoint to update the rule of.
MockSelect Enabled to enable mocking for this rule or Disabled or disabled to disable mocking for this rule. When enabled, the rule will intercept matching requests and return the configured response.
Random ResponsesA list of response objects with percentage weights as JSON array.

Each response must comply with the required response object properties. For more details please see Beeceptor’s API documentation.
Response BodyThe response body content to return (JSON or text).

For example:
{
“status”: “Awesome!”
}
Response HeadersThe response headers to send as a JSON object.

For example:
{
“Content-Type”: “application/json”
}
Response StatusThe HTTP status code to return when this rule matches.
Rule IDThe ID of the required rule.
Send TypeThe response type for the rule. Choose send for a fixed response or sendRandom for randomly selected responses.
Templated ResponseSelect true to enable HandleBar templating in the mocked response for dynamic content.

For more information about the Templated Response parameter please visit Beeceptor documentation.

Example Output

{
	"enabled": true,
	"mock": true,
	"delay": 31000,
	"match": {
		"method": "POST",
		"value": "/customers",
		"operator": "SW"
	},
	"send": {
		"status": 200,
		"body": "{ }",
		"headers": {
			"Content-Type": "application/json",
			"my-custom-header": "some-data"
		},
		"templated": false
	}
}

Workflow Library Example

Update Rule with Beeceptor and Send Results Via Email
Workflow LibraryPreview this Workflow on desktop
I