Skip to main content

payload-verification-valid-message-template

Overview

This rule belongs to the apimatic-codegen-validation ruleset and states that:

The messageTemplate field must only use supported placeholders. Webhook templates support {$request.body}, {$method}, {$request.header.<HeaderName>}, {$request.body#/property}. Callback templates support additional placeholders including {$url}, {$request.path}, {$request.query.<ParamName>}. If no value is specified, '{$request.body}' is used as the default.

PropertyValue
EnabledYes
Maximum SeverityError
MessagePayload verification messageTemplate contains invalid placeholders.
CodeAPIMATICCODEGEN_V530
TypeValidation
Rule SystemSemantic
Broad CategoryWebhooks
Products ImpactedCode Generation, Developer Experience Portal
Tagsapimatic code generation codegen sdks portal docs validation apimatic webhook callback payload verification message template template validation placeholders

Suggested Fixes

  • Use only supported placeholders for the respective type (webhook vs callback).
  • Replace <HeaderName> with actual header name (for example {$request.header.Authorization}).
  • Use JSON pointer syntax for body properties (for example {$request.body#/user/id}).
  • Remove the messageTemplate field to use the default value '{$request.body}'.
  • Ensure all placeholders are properly formatted with curly braces.

For More Information