Skip to main content

Parameters

See plugin common configurations for configuration options available to all plugins.

  • match_all_roles

    boolean

    default: false


    If true, validate messages from all roles. If false, validate the message from user role only.

  • match_all_conversation_history

    boolean

    default: false


    If true, concatenate and check all messages in the conversation history. If false, only check the content of the last message.

    This option does not apply to Responses API requests because instructions and input are parallel fields rather than conversation history.

  • allow_patterns

    array[string]

    default: []


    An array of RegEx patterns that messages should match. When configured, messages must match at least one pattern to be considered valid.

  • deny_patterns

    array[string]

    default: []


    An array of RegEx patterns that messages should not match. If messages match any of the patterns, the request should be rejected.

    If both allow_patterns and deny_patterns are configured, the plugin first ensures that at least one allow_patterns is matched.

  • fail_mode

    string

    default: skip

    vaild vaule:

    skip, warn, or error


    Behavior when the plugin is bound to a Consumer and receives a request whose format it does not recognize, such as a non-AI request. With skip, the unrecognized request is passed through unchecked. With warn, the request is passed through and a warning is logged. With error, the request is rejected with HTTP 400.

    Available in API7 Enterprise from version 3.9.14.

  • max_req_body_size

    integer

    default: 67108864


    Maximum request body size in bytes buffered into memory. Larger request bodies are rejected. Available in API7 Enterprise from version 3.9.17 on the 3.9 line and from version 3.10.4 on the 3.10 line.