All Projects → kielabokkie → Blueman

kielabokkie / Blueman

Licence: mit
Convert a generated API Blueprint JSON file into a Postman collection

Projects that are alternatives of or similar to Blueman

Pmtoapib
Tool to convert Postman collection exports to Api Blueprint documentation
Stars: ✭ 34 (-76.55%)
Mutual labels:  api-blueprint, postman
Apiary2postman
Tool for generating a Postman collection from Blueprint API markup or the Apiary API
Stars: ✭ 194 (+33.79%)
Mutual labels:  api-blueprint, postman
Postman Sandbox
Sandbox for Postman Scripts to run in Node.js or browser
Stars: ✭ 47 (-67.59%)
Mutual labels:  postman
Flask2postman
🚀 Generate a Postman collection from your Flask application
Stars: ✭ 120 (-17.24%)
Mutual labels:  postman
Dredd Example
Example application using Dredd and CI
Stars: ✭ 79 (-45.52%)
Mutual labels:  api-blueprint
Postman
1.12.2 anarchy client :)
Stars: ✭ 54 (-62.76%)
Mutual labels:  postman
Swaggman
OpenAPI Spec SDK and Converter for OpenAPI 3.0 and 2.0 Specs to Postman 2.0 Collections. Example RingCentral spec included.
Stars: ✭ 94 (-35.17%)
Mutual labels:  postman
Python Api Development Fundamentals
Develop a full-stack web application with Python and Flask
Stars: ✭ 44 (-69.66%)
Mutual labels:  postman
Grpcui
An interactive web UI for gRPC, along the lines of postman
Stars: ✭ 2,490 (+1617.24%)
Mutual labels:  postman
Health Checks Api
Standardize the way services and applications expose their status in a distributed application
Stars: ✭ 78 (-46.21%)
Mutual labels:  api-blueprint
Wechatpay Postman Script
微信支付API v3的调试工具
Stars: ✭ 112 (-22.76%)
Mutual labels:  postman
Xcodeserver Api Docs
Unofficial documentation of the Xcode Server API (Xcode 7 edition)
Stars: ✭ 71 (-51.03%)
Mutual labels:  api-blueprint
Httplive
HTTP Request & Response Service, Mock HTTP
Stars: ✭ 1,094 (+654.48%)
Mutual labels:  postman
Apifuzzer
Fuzz test your application using your OpenAPI or Swagger API definition without coding
Stars: ✭ 101 (-30.34%)
Mutual labels:  api-blueprint
Drafter.js
API Blueprint parser in JS
Stars: ✭ 50 (-65.52%)
Mutual labels:  api-blueprint
Rocket Api
API敏捷开发框架,用于API接口功能的快速开发。不再定义Controller,Service,Dao,Mybatis,xml,Entity,VO等对象和方法.以springboot starter 形式集成使用
Stars: ✭ 122 (-15.86%)
Mutual labels:  postman
Apib Mode
Emacs API Blueprint major mode
Stars: ✭ 44 (-69.66%)
Mutual labels:  api-blueprint
Api Blueprint Boilerplate
Minimalistic boilerplate to quick-start API specification using API Blueprint description language.
Stars: ✭ 71 (-51.03%)
Mutual labels:  api-blueprint
Androidhttp
Android Http网络开发神兵利器
Stars: ✭ 88 (-39.31%)
Mutual labels:  postman
Postman Bdd
A BDD test framework for Postman and Newman
Stars: ✭ 139 (-4.14%)
Mutual labels:  postman

Blueman

Author Build Status Code Coverage Codacy Badge Packagist Version Software License Gitter

Convert an API Blueprint JSON file into a Postman collection.

Install Blueman as a Phar (recommended)

Use the installer to download Blueman:

$ curl -sS http://blueman.pixelfusion.co.nz/installer.php | php

This will grab the latest version of Blueman and copy it to your current directory. We recommend moving it to the bin directory so you can run the Blueman from anywhere:

$ mv blueman.phar /usr/local/bin/blueman

Whenever there is a new version of Blueman you can run self-update to update to the latest version:

$ blueman self-update

Install using Composer

Blueman can also be installed using Composer if you prefer that:

$ composer create-project pixelfusion/blueman your-project-name

Prerequisites

The API Blueprint JSON file that you want to convert with Blueman should be created using Drafter. By default Drafter creates refract formatted JSON files but Blueman only supports the AST format. You will have to force Drafter to use AST by passing the -t parameter, for example:

drafter -f json -t ast -o api.json api.md

Note: As of December 2015 the API Blueprint AST format has been deprecated. The API Blueprint AST has been superseded by API Description Refract Namespace. At this point Blueman only supports the AST format so as soon as Drafter drops support for generating AST formatted files, Blueman won't work anymore. Pull Requests to add support for the refract format are highly appreciated!

Usage

To generate a Postman collection you run the convert command. For example, if the API Blueprint JSON file you generated is called api.json you would execute the following command:

$ blueman convert api.json

Note: If you installed Blueman using Composer you have to replace blueman with ./bin/console in all the example commands, e.g.:

$ ./bin/console convert api.json

This command will generate a file called collection.json, which you can import in Postman.

By default Blueman will look for the JSON file in the same location as where you are running the command. If your file is in another directory, you need to specify the path:

$ blueman convert api.json --path=/Users/wouter/Desktop

Specify output file

By default Blueman will create a collection.json file in the current directory. You can save the file to a different folder and change the output filename by passing the output parameter:

$ blueman convert api.json --output=/Users/wouter/Desktop/postman_collection.json

Setting the host

The base host of your API can be set in a couple of different ways.

First of all you can specify it in your API Blueprint as metadata by adding the following line to the top of your API Blueprint Markdown file:

HOST: https://api.example.com/v1

If your Markdown file doesn't have the host metadata or if you want to overwrite it, you can specify the host when executing the convert command:

$ blueman convert api.json --host=https://api.example.com/v1

Lastly, if you don't do either of the above you'll be prompted to set the host when you execute the convert command.

TIP: If you use environments in Postman to test your API on different servers (sandbox, user acceptance testing, etc.) you can use the host option to specify your placeholder keys that you've setup in Postman's environment config:

$ blueman convert api.json --host=https://api.{{host}}/v1

Postman tests

Blueman also allows you to define Postman tests.

To use this feature you have to create a Markdown file in your path where api.json is located (see --path option). By default, Blueman will try to read a file called blueman.tests.md. Check the test/api.test.md file for an example of the syntax. You can use a different name if you like but you will need to specify the --test-filename parameter when you run the convert command.

Usage example

$ blueman convert api.json --include-tests 

If the name of your test file is not blueman.tests.md then specify the filename:

$ blueman convert api.json --include-tests --tests-filename=<YOUR_FILNAME>.md
Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].