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

OpenAPI IP address support #441

Closed
FallingSnow opened this issue Dec 5, 2022 · 2 comments · Fixed by #442
Closed

OpenAPI IP address support #441

FallingSnow opened this issue Dec 5, 2022 · 2 comments · Fixed by #442
Labels
enhancement New feature or request

Comments

@FallingSnow
Copy link
Contributor

OpenAPI IP addresses should be supported as a format (in poem-openapi as a type).

OpenAPI does not make reference to them in the specification but they seem to be supported.
See swagger-api/swagger-ui#5033 for support on this point.

I recommend adding type support for Ipv4Addr as it is an existing struct.

@FallingSnow FallingSnow added the enhancement New feature or request label Dec 5, 2022
@sunli829
Copy link
Collaborator

sunli829 commented Dec 5, 2022

It's easy, do it like below, would you like to open a PR to help me with this? 🙂

https://github.com/poem-web/poem/blob/master/poem-openapi/src/types/external/uuid.rs

@FallingSnow
Copy link
Contributor Author

I tried it, mostly just replaced anywhere it says uuid. Not sure if I did it right.

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

Successfully merging a pull request may close this issue.

2 participants