openapi-generator/samples/server/petstore/rust-server
wing328 f0b7daeec6 [Rust] rename rust2 to rust-server (#6747)
* rename rust2 to rust-server

* update rust-server batch file to use petstore test spec
2017-10-19 20:17:08 +08:00
..
.cargo [Rust] rename rust2 to rust-server (#6747) 2017-10-19 20:17:08 +08:00
.swagger-codegen [Rust] rename rust2 to rust-server (#6747) 2017-10-19 20:17:08 +08:00
api [Rust] rename rust2 to rust-server (#6747) 2017-10-19 20:17:08 +08:00
examples [Rust] rename rust2 to rust-server (#6747) 2017-10-19 20:17:08 +08:00
src [Rust] rename rust2 to rust-server (#6747) 2017-10-19 20:17:08 +08:00
.gitignore [Rust] rename rust2 to rust-server (#6747) 2017-10-19 20:17:08 +08:00
.swagger-codegen-ignore [Rust] rename rust2 to rust-server (#6747) 2017-10-19 20:17:08 +08:00
Cargo.toml [Rust] rename rust2 to rust-server (#6747) 2017-10-19 20:17:08 +08:00
README.md [Rust] rename rust2 to rust-server (#6747) 2017-10-19 20:17:08 +08:00

Rust API for petstore_api

This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: " \

Overview

This client/server was generated by the [swagger-codegen] (https://github.com/swagger-api/swagger-codegen) project. By using the OpenAPI-Spec from a remote server, you can easily generate a server stub.

To see how to make this your own, look here:

README

  • API version: 1.0.0
  • Build date: 2017-10-19T17:45:37.995+08:00

Examples

Run examples with:

cargo run --example <example-name>

To pass in arguments to the examples, put them after --, for example:

cargo run --example client -- --help

Running the server

To run the server, follow these simple steps:

cargo run --example server

Running a client

To run a client, follow one of the following simple steps:

cargo run --example client TestSpecialTags
cargo run --example client GetXmlFeatures
cargo run --example client PostXmlFeatures
cargo run --example client FakeOuterBooleanSerialize
cargo run --example client FakeOuterCompositeSerialize
cargo run --example client FakeOuterNumberSerialize
cargo run --example client FakeOuterStringSerialize
cargo run --example client TestClientModel
cargo run --example client TestEndpointParameters
cargo run --example client TestEnumParameters
cargo run --example client TestInlineAdditionalProperties
cargo run --example client TestJsonFormData
cargo run --example client TestClassname
cargo run --example client AddPet
cargo run --example client DeletePet
cargo run --example client FindPetsByStatus
cargo run --example client FindPetsByTags
cargo run --example client GetPetById
cargo run --example client UpdatePet
cargo run --example client UpdatePetWithForm
cargo run --example client UploadFile
cargo run --example client DeleteOrder
cargo run --example client GetInventory
cargo run --example client GetOrderById
cargo run --example client PlaceOrder
cargo run --example client CreateUser
cargo run --example client CreateUsersWithArrayInput
cargo run --example client CreateUsersWithListInput
cargo run --example client DeleteUser
cargo run --example client GetUserByName
cargo run --example client LoginUser
cargo run --example client LogoutUser
cargo run --example client UpdateUser

HTTPS

The examples can be run in HTTPS mode by passing in the flag --https, for example:

cargo run --example server -- --https

This will use the keys/certificates from the examples directory. Note that the server chain is signed with CN=localhost.