Class API.SetProperty

java.lang.Object
com.shaft.properties.internal.API.SetProperty
All Implemented Interfaces:
EngineProperties.SetProperty
Enclosing interface:
API

public static class API.SetProperty extends Object implements EngineProperties.SetProperty
Fluent builder that allows programmatic override of individual API configuration properties. All setter methods return this to support method chaining.

Example:

SHAFT.Properties.api.set()
    .swaggerValidationEnabled(true)
    .swaggerValidationUrl("https://petstore.swagger.io/v2/swagger.json");
  • Constructor Details

    • SetProperty

      public SetProperty()
      Creates a new SetProperty instance.
  • Method Details

    • swaggerValidationEnabled

      public API.SetProperty swaggerValidationEnabled(boolean value)
      Overrides the swagger.validation.enabled property at runtime.
      Parameters:
      value - true to enable Swagger/OpenAPI response validation
      Returns:
      this API.SetProperty instance for chaining
    • swaggerValidationUrl

      public API.SetProperty swaggerValidationUrl(String value)
      Overrides the swagger.validation.url property at runtime.
      Parameters:
      value - the URL of the Swagger/OpenAPI specification document
      Returns:
      this API.SetProperty instance for chaining
    • openApiCoverageReportEnabled

      public API.SetProperty openApiCoverageReportEnabled(boolean value)
      Overrides the openapi.coverage.report.enabled property at runtime.
      Parameters:
      value - true to enable OpenAPI coverage reporting
      Returns:
      this API.SetProperty instance for chaining
    • openApiCoverageThreshold

      public API.SetProperty openApiCoverageThreshold(int value)
      Overrides the openapi.coverage.threshold property at runtime.
      Parameters:
      value - required coverage percentage from 0 to 100; 0 disables enforcement
      Returns:
      this API.SetProperty instance for chaining
      Throws:
      IllegalArgumentException - if value is outside 0..100
    • contractSensitiveKeys

      public API.SetProperty contractSensitiveKeys(String value)
      Overrides the HTTP contract sensitive key list.
      Parameters:
      value - comma-separated key fragments to redact
      Returns:
      this API.SetProperty instance for chaining
    • contractVolatileKeys

      public API.SetProperty contractVolatileKeys(String value)
      Overrides the HTTP contract volatile key list.
      Parameters:
      value - comma-separated key names to normalize
      Returns:
      this API.SetProperty instance for chaining