@salesforce/b2c-tooling-sdk / safety / checkSafetyViolation
Function: checkSafetyViolation() ​
checkSafetyViolation(
method,url,config):string|undefined
Defined in: packages/b2c-tooling-sdk/src/safety/safety-middleware.ts:160
Checks if an HTTP operation should be blocked based on safety configuration.
Parameters ​
method ​
string
HTTP method (GET, POST, PUT, PATCH, DELETE)
url ​
string
Request URL
config ​
Safety configuration
Returns ​
string | undefined
Error message if blocked, undefined if allowed
Deprecated ​
Use SafetyGuard.evaluate for full rule-based evaluation.