Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/softprops/openapi

openapi schema serialization for rust
https://github.com/softprops/openapi

openapi rust-library

Last synced: 7 days ago
JSON representation

openapi schema serialization for rust

Awesome Lists containing this project

README

        

# open api [![Build Status](https://travis-ci.org/softprops/openapi.svg?branch=master)](https://travis-ci.org/softprops/openapi) [![Software License](https://img.shields.io/badge/license-MIT-brightgreen.svg)](LICENSE) [![crates.io](http://meritbadge.herokuapp.com/openapi)](https://crates.io/crates/openapi)

> Rust crate for serializing and deserializing [open api](http://swagger.io/specification/) documents

[Documentation](https://softprops.github.io/openapi)

## install

add the following to your `Cargo.toml` file

```toml
[dependencies]
openapi = "0.1"
```

## usage

```rust
extern crate openapi;

fn main() {
match openapi::from_path("path/to/openapi.yaml") {
Ok(spec) => println!("spec: {:?}", spec),
Err(err) => println!("error: {}", err)
}
}
```

Doug Tangren (softprops) 2017