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

Add automatic body recognition for rocket #670

Merged
merged 1 commit into from
Jul 12, 2023
Merged

Conversation

juhaku
Copy link
Owner

@juhaku juhaku commented Jul 12, 2023

Add functionality to utoipa to recognize request body from rocket handler function based on data attribute and handler function argument.

#[post("/hello", data = "<hello>")]
fn post_hello(
    hello: Json<Hello>,
) -> String {
    "Hello".to_string()
}

Resolves #591

@juhaku juhaku merged commit 90b875d into master Jul 12, 2023
@juhaku juhaku deleted the feature-rocket-auto-types branch July 12, 2023 20:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: Released
Development

Successfully merging this pull request may close these issues.

Automatic type recognition for path operation handlers
1 participant