-
Notifications
You must be signed in to change notification settings - Fork 13.3k
Open
Labels
type: featurePull requests that introduces new featurePull requests that introduces new feature
Description
Description
The legacy users REST API endpoints currently lack explicit schema validation. Inputs are weakly typed or imperatively checked inside the handlers, which can lead to runtime regressions.
The following endpoints need to be formally typed and migrated using ajv via @rocket.chat/rest-typings:
users.getAvatarusers.deleteOwnAccountusers.resetAvatarusers.forgotPassword
Proposed Solution
- Add TypeBox/Ajv JSON schemas to
packages/rest-typings. - Export the typing boundaries.
- Attach the
validateParamsoption onto theAPI.v1.addRouteconfig block for these endpoints.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
type: featurePull requests that introduces new featurePull requests that introduces new feature