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

Return mocked value in specified format #79

Open
javier-sierra-sngular opened this issue Nov 21, 2023 · 0 comments
Open

Return mocked value in specified format #79

javier-sierra-sngular opened this issue Nov 21, 2023 · 0 comments

Comments

@javier-sierra-sngular
Copy link

It would be nice if the application returns the mocked data, taking into account the format parameter (if specified).

https://spec.openapis.org/oas/v3.1.0#dataTypeFormat
https://ajv.js.org/packages/ajv-formats.html#formats

Currently, type: string is always returning 'string' regardless of the specified format.

If the type is string and the format is date, a more appropriate response would be '2023-11-17'.

I am going to link a PR to this issue.

Thanks

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant