Contents

bow-swift/bow-openapi

🌐 Functional HTTP client generator from an OpenAPI/Swagger specification.

Installation guide

Bow OpenAPI is compatible with Unix systems.

πŸ’» OS X users

You can install Bow OpenAPI using Homebrew. Its formula is not still in the main repository; therefore, you need to tap it first, before installing it:

brew tap bow-swift/bow
brew install bow-openapi

🐧 Linux users

curl -s https://api.github.com/repos/bow-swift/bow-openapi/releases/latest \
 | grep -oP '"tag_name": "\K(.*)(?=")' \
 | xargs -I {} wget -O - https://github.com/bow-swift/bow-openapi/archive/{}.tar.gz \
 | tar xz \
 && sudo make linux -C bow-openapi-*

It will install the last stable version.

Bow OpenAPI depends on Java 8+ and swagger-codegen; both will be installed from Makefile. After the installation, you can type bow-openapi -h in a new termintal to check it.

βš™οΈ Usage

You can invoke the tool with the following parameters:

bow-openapi --name <NAME> --schema <YAML | JSON> --output <FOLDER>
  • name is the name for the generated module in the resulting Swift Package. You will have to import it in your code using import <NAME>.
  • schema is the path to the OpenAPI / Swagger specification file. It accepts both YAML or JSON formats.
  • output is the folder where the result will be saved.

❀️ Contributing to the project

We welcome your contributions! Help us make Bow OpenAPI better:

πŸ› File an issue if you find a bug.

πŸ†• Suggest a new feature for Bow OpenAPI.

➑️ Open a Pull Request fixing a problem or adding new functionality.

πŸ’¬ Discuss with us in our Gitter channel to help us shape the future of Bow OpenAPI.

Copyright (C) 2020-2021 The Bow Authors

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

Package Metadata

Repository: bow-swift/bow-openapi

Homepage: https://openapi.bow-swift.io

Stars: 52

Forks: 1

Open issues: 7

Default branch: master

Primary language: swift

License: Other

Topics: bow, effects, functional-programming, hacktoberfest, http-client, networking, openapi, swagger, swift, swift-package-manager

README: README.md