Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[eem] convert route validation to zod #188171

Closed
klacabane opened this issue Jul 12, 2024 · 1 comment · Fixed by #188691
Closed

[eem] convert route validation to zod #188171

klacabane opened this issue Jul 12, 2024 · 1 comment · Fixed by #188691
Assignees
Labels
Feature:EEM Elastic Entity Model Team:obs-knowledge Observability Experience Knowledge team

Comments

@klacabane
Copy link
Contributor

Convert route validation to zod. This should help https://github.com/elastic/kibana/blob/main/packages/kbn-zod-helpers/src/build_route_validation_with_zod.ts

@klacabane klacabane added Team:obs-knowledge Observability Experience Knowledge team Feature:EEM Elastic Entity Model labels Jul 12, 2024
@elasticmachine
Copy link
Contributor

Pinging @elastic/obs-knowledge-team (Team:obs-knowledge)

@simianhacker simianhacker self-assigned this Jul 18, 2024
simianhacker added a commit that referenced this issue Jul 22, 2024
## Summary

This PR closes #188171 by
converting the route validate to Zod for `get`, `reset`, and `delete`
APIs. This also changes the validation for the `create` API to use
`buildRouteValidationWithZod` along with adding `strict()` to each of
the schemas.

Closes elastic/elastic-entity-model#103

---------

Co-authored-by: Kevin Lacabane <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Feature:EEM Elastic Entity Model Team:obs-knowledge Observability Experience Knowledge team
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants