postmanlabs/openapi-to-postman là dự án API trên GitHub, viết chủ yếu bằng JavaScript, với 1.1k sao. Plugin for converting OpenAPI 3.0 specs to the Postman Collection (v2) format
Tóm tắt dựng từ metadata GitHub của chính dự án — chưa có bài review TopGit. Trang sẽ tự động cập nhật khi bài review đầy đủ được xuất bản.
VÌ SAO CHƯA CÓ REVIEW
TopGit viết bài đầy đủ cho repo có nhiều sao nhất và được yêu cầu nhiều nhất. Trang này là snapshot trong thời gian chờ — xem README gốc ở tab READ ME.
Supercharge your API workflow.Modern software is built on APIs. Postman helps you develop APIs faster.
OpenAPI 3.0, 3.1 and Swagger 2.0 to Postman Collection
Contents
Getting Started
Command Line Interface
Options
Usage
Syncing Collections
Using the converter as a NodeJS module
Convert Function
Sync Collection Function
Options
ConversionResult
Sample usage
Validate function
Conversion Schema
🚀 We now also support OpenAPI 3.1 and Swagger 2.0 along with OpenAPI 3.0.
💭 Getting Started
To use the converter as a Node module, you need to have a copy of the NodeJS runtime. The easiest way to do this is through npm. If you have NodeJS installed you have npm installed as well.
$ npm install openapi-to-postmanv2
If you want to use the converter in the CLI, install it globally with NPM:
$ npm i -g openapi-to-postmanv2
📖 Command Line Interface
The converter can be used as a CLI tool as well. The following command line options are available.
openapi2postmanv2 [options]
Options
-s <source>, --spec <source>
Used to specify the OpenAPI specification (file path) which is to be converted
-o <destination>, --output <destination>
Used to specify the destination file in which the collection is to be written
-p, --pretty
Used to pretty print the collection object while writing to a file
-i, --interface-version
Specifies the interface version of the converter to be used. Value can be 'v2' or 'v1'. Default is 'v2'.
-O, --options
Used to supply options to the converter, for complete options details see here
-c, --options-config
Used to supply options to the converter through config file, for complete options details see here
-t, --test
Used to test the collection with an in-built sample specification
-v, --version
Specifies the version of the converter
-h, --help
Specifies all the options along with a few usage examples on the terminal
--sync <collectionFile>
Sync spec changes with an existing Postman Collection file
--sync-options <syncOptions>
Comma-separated list of sync options (e.g., syncExamples=true)
Takes a specification (spec.yaml) as an input and writes to a file (collection.json) with pretty printing and using provided options (Also avoids any "<Error: Too many levels of nesting to fake this schema>" kind of errors present in converted collection)
Whether to sync response examples from the OpenAPI specification to the collection. When enabled, response examples in the spec are synced with existing collection responses.
deleteOrphanedRequests
boolean
false
Whether to delete requests and folders that exist in the collection but no longer exist in the OpenAPI specification. When disabled (default), such orphans are preserved to avoid unintentional data loss.
For a complete list of sync options and their usage, see SYNC_OPTIONS.md
🛠 Using the converter as a NodeJS module
In order to use the convert in your node application, you need to import the package using require.
var Converter = require('openapi-to-postmanv2')
The converter provides the following functions:
Convert
The convert function takes in your OpenAPI 3.0, 3.1 and Swagger 2.0 specification (YAML / JSON) and converts it to a Postman collection.
Signature: convert (data, options, callback);
data:
{ type: 'file', data: 'filepath' }
OR
{ type: 'string', data: '<entire OpenAPI string - JSON or YAML>' }
OR
{ type: 'json', data: OpenAPI-JS-object }
options:
{
schemaFaker: true,
requestNameSource: 'fallback',
indentCharacter: ' '
}
/*
All three properties are optional. Check the options section below for possible values for each option.
*/
Note: All possible values of options and their usage can be found over here: OPTIONS.md
The validate function is meant to ensure that the data that is being passed to the convert function is a valid JSON object or a valid (YAML/JSON) string.
The validate function is synchronous and returns a status object which conforms to the following schema
postmanlabs/openapi-to-postman thuộc nhóm API trên TopGit, cùng 3 topic GitHub. Trang Trending và Topics liệt kê các repo cùng số sao và cùng ngôn ngữ để so sánh.
Đọc thêm về postmanlabs/openapi-to-postman ở đâu?
Trang TopGit này là một snapshot — tab "Readme" hiển thị nguyên văn README của repo (đã bỏ link, giữ ảnh). Repo GitHub ở github.com/postmanlabs/openapi-to-postman là nguồn chính thức.
postmanlabs/openapi-to-postman có phải mã nguồn mở không?
Có — postmanlabs/openapi-to-postman phát hành theo license Apache-2.0, nghĩa là mã nguồn mở để đọc, fork và (tùy license) tái sử dụng. Mã: github.com/postmanlabs/openapi-to-postman.
postmanlabs/openapi-to-postman có website riêng không?
TopGit chưa ghi nhận URL trang chủ cho postmanlabs/openapi-to-postman. Phần README ở tab phía trên thường có link demo, hoặc xem mô tả GitHub của repo.
postmanlabs/openapi-to-postman dùng license gì?
postmanlabs/openapi-to-postman phát hành theo license Apache-2.0. Nên mở file LICENSE trên GitHub để xác nhận — license metadata đôi khi lệch với thực tế dự án.
postmanlabs/openapi-to-postman là gì?
postmanlabs/openapi-to-postman (postmanlabs/openapi-to-postman) là dự án JavaScript trên GitHub. Theo mô tả gốc: Plugin for converting OpenAPI 3.0 specs to the Postman Collection (v2) format
Vì sao postmanlabs/openapi-to-postman được xếp vào nhóm API?
TopGit xếp postmanlabs/openapi-to-postman vào nhóm API dựa trên GitHub topics và mô tả của repo (gắn thẻ: "openapi", "openapi3", "postman-collection"). Việc phân loại dựa trên metadata thật của repo, không phải đoán theo cảm tính biên tập.
Đọc đầy đủ README ở tab phía trên.
Vẫn đang phân vân về openapi-to-postman?
Một cú bấm sẽ gửi câu hỏi kèm trang này cho AI — xem AI nói gì về openapi-to-postman.