Expand description
Model-derived input validation for AWS IoT Wireless operations.
The rules are generated from the Smithy model (see src/generated.rs):
for every top-level input member the generator records its wire location
(@httpLabel / @httpQuery / @httpHeader / body), whether it is
@required, and its @length / @range / @enum constraints. This
validator enforces exactly those constraints — mirroring the model — so a
request that satisfies the model is accepted and one that violates a
declared constraint is rejected with the operation’s declared client error
(InvalidRequestException, falling back to ValidationException or the
operation’s first declared error when InvalidRequestException is not in
its Smithy errors list). @pattern is intentionally not enforced:
IoT Wireless patterns are not part of the constraint set exercised here and
enforcing them would reject otherwise-valid inputs.
Structs§
- Inputs
- The request inputs, already split by wire location.
Functions§
- invalid
- validate
- Validate a request against the operation’s model-derived constraints.
- validation_
error_ code - Pick the client-error code this operation should use for an input-validation
failure:
InvalidRequestExceptionwhen declared, elseValidationException, else the operation’s first declared error, elseInvalidRequestException.