{"id":14986643,"url":"https://github.com/grokify/spectrum","last_synced_at":"2026-03-17T23:35:41.716Z","repository":{"id":37896729,"uuid":"88514826","full_name":"grokify/spectrum","owner":"grokify","description":"OpenAPI Spec SDK and Converter for OpenAPI 3.0 and 2.0 Specs to Postman 2.0 Collections. Example RingCentral spec included.","archived":false,"fork":false,"pushed_at":"2026-01-12T04:57:34.000Z","size":2511,"stargazers_count":117,"open_issues_count":7,"forks_count":28,"subscribers_count":2,"default_branch":"master","last_synced_at":"2026-01-12T14:05:04.374Z","etag":null,"topics":["glip","golang","postman","postman-collection","ringcentral","swagger","swagger-specification"],"latest_commit_sha":null,"homepage":"https://pkg.go.dev/github.com/grokify/spectrum","language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/grokify.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2017-04-17T14:15:12.000Z","updated_at":"2026-01-12T04:56:50.000Z","dependencies_parsed_at":"2023-11-18T05:26:13.532Z","dependency_job_id":"c85e7b14-f846-4e81-8ac7-9ca6d1d8de09","html_url":"https://github.com/grokify/spectrum","commit_stats":null,"previous_names":["grokify/swaggman"],"tags_count":96,"template":false,"template_full_name":null,"purl":"pkg:github/grokify/spectrum","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/grokify%2Fspectrum","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/grokify%2Fspectrum/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/grokify%2Fspectrum/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/grokify%2Fspectrum/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/grokify","download_url":"https://codeload.github.com/grokify/spectrum/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/grokify%2Fspectrum/sbom","scorecard":{"id":446131,"data":{"date":"2025-08-11","repo":{"name":"github.com/grokify/spectrum","commit":"ceb9b38412735b97995fda663d65f0ce829032aa"},"scorecard":{"version":"v5.2.1-40-gf6ed084d","commit":"f6ed084d17c9236477efd66e5b258b9d4cc7b389"},"score":4.4,"checks":[{"name":"Code-Review","score":0,"reason":"Found 0/10 approved changesets -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project requires human code review before pull requests (aka merge requests) are merged.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#code-review"}},{"name":"Maintained","score":10,"reason":"30 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 10","details":null,"documentation":{"short":"Determines if the project is \"actively maintained\".","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#maintained"}},{"name":"Packaging","score":-1,"reason":"packaging workflow not detected","details":["Warn: no GitHub/GitLab publishing workflow detected."],"documentation":{"short":"Determines if the project is published as a package that others can easily download, install, easily update, and uninstall.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#packaging"}},{"name":"Dangerous-Workflow","score":10,"reason":"no dangerous workflow patterns detected","details":null,"documentation":{"short":"Determines if the project's GitHub Action workflows avoid dangerous patterns.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#dangerous-workflow"}},{"name":"Token-Permissions","score":0,"reason":"detected GitHub workflow tokens with excessive permissions","details":["Warn: no topLevel permission defined: .github/workflows/ci.yaml:1","Warn: no topLevel permission defined: .github/workflows/lint.yaml:1","Info: no jobLevel write permissions found"],"documentation":{"short":"Determines if the project's workflows follow the principle of least privilege.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#token-permissions"}},{"name":"Binary-Artifacts","score":10,"reason":"no binaries found in the repo","details":null,"documentation":{"short":"Determines if the project has generated executable (binary) artifacts in the source repository.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#binary-artifacts"}},{"name":"CII-Best-Practices","score":0,"reason":"no effort to earn an OpenSSF best practices badge detected","details":null,"documentation":{"short":"Determines if the project has an OpenSSF (formerly CII) Best Practices Badge.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#cii-best-practices"}},{"name":"Pinned-Dependencies","score":0,"reason":"dependency not pinned by hash detected -- score normalized to 0","details":["Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/ci.yaml:20: update your workflow using https://app.stepsecurity.io/secureworkflow/grokify/spectrum/ci.yaml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/ci.yaml:24: update your workflow using https://app.stepsecurity.io/secureworkflow/grokify/spectrum/ci.yaml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/lint.yaml:12: update your workflow using https://app.stepsecurity.io/secureworkflow/grokify/spectrum/lint.yaml/master?enable=pin","Warn: third-party GitHubAction not pinned by hash: .github/workflows/lint.yaml:14: update your workflow using https://app.stepsecurity.io/secureworkflow/grokify/spectrum/lint.yaml/master?enable=pin","Info:   0 out of   3 GitHub-owned GitHubAction dependencies pinned","Info:   0 out of   1 third-party GitHubAction dependencies pinned"],"documentation":{"short":"Determines if the project has declared and pinned the dependencies of its build process.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#pinned-dependencies"}},{"name":"Security-Policy","score":0,"reason":"security policy file not detected","details":["Warn: no security policy file detected","Warn: no security file to analyze","Warn: no security file to analyze","Warn: no security file to analyze"],"documentation":{"short":"Determines if the project has published a security policy.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#security-policy"}},{"name":"Fuzzing","score":0,"reason":"project is not fuzzed","details":["Warn: no fuzzer integrations found"],"documentation":{"short":"Determines if the project uses fuzzing.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#fuzzing"}},{"name":"License","score":10,"reason":"license file detected","details":["Info: project has a license file: LICENSE:0","Info: FSF or OSI recognized license: MIT License: LICENSE:0"],"documentation":{"short":"Determines if the project has defined a license.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#license"}},{"name":"Signed-Releases","score":-1,"reason":"no releases found","details":null,"documentation":{"short":"Determines if the project cryptographically signs release artifacts.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#signed-releases"}},{"name":"Branch-Protection","score":0,"reason":"branch protection not enabled on development/release branches","details":["Warn: branch protection not enabled for branch 'master'"],"documentation":{"short":"Determines if the default and release branches are protected with GitHub's branch protection settings.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#branch-protection"}},{"name":"SAST","score":0,"reason":"SAST tool is not run on all commits -- score normalized to 0","details":["Warn: 0 commits out of 20 are checked with a SAST tool"],"documentation":{"short":"Determines if the project uses static code analysis.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#sast"}},{"name":"Vulnerabilities","score":10,"reason":"0 existing vulnerabilities detected","details":null,"documentation":{"short":"Determines if the project has open, known unfixed vulnerabilities.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#vulnerabilities"}}]},"last_synced_at":"2025-08-19T06:46:17.105Z","repository_id":37896729,"created_at":"2025-08-19T06:46:17.105Z","updated_at":"2025-08-19T06:46:17.105Z"},"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28760642,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-25T20:56:06.009Z","status":"ssl_error","status_checked_at":"2026-01-25T20:54:48.203Z","response_time":113,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["glip","golang","postman","postman-collection","ringcentral","swagger","swagger-specification"],"created_at":"2024-09-24T14:13:16.485Z","updated_at":"2026-01-25T22:07:01.997Z","avatar_url":"https://github.com/grokify.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"Spectrum - OpenAPI Spec SDK and Postman Converter\n=================================================\n\n[![Build Status][build-status-svg]][build-status-url]\n[![Lint Status][lint-status-svg]][lint-status-url]\n[![Go Report Card][goreport-svg]][goreport-url]\n[![Docs][docs-godoc-svg]][docs-godoc-url]\n[![License][license-svg]][license-url]\n\nSpectrum is a multi-purpose OpenAPI Spec SDK that includes enhanced Postman conversion. Most of the OpenAPI Spec SDK is designed to support OAS3. Some functionality for OAS2 exists.\n\nThe following article provides an overview of OpenAPI spec to Postman conversion:\n\n1. [Blog Introduction](https://medium.com/ringcentral-developers/using-postman-with-swagger-and-the-ringcentral-api-523712f792a0)\n\n## Use Cases\n\n1. Converting from OpenAPI Spec to Postman where `x-tagGroups` are converted to Postman folders.\n1. Programmatically editing specs for reproducible results, typically when source spec is maintained.\n1. Merging multiple specs when a single spec is desired.\n1. Splitting a spec by tags when multiple specs are desired.\n\n## Packages and Major Features\n\n* openapi2 ([godoc](https://pkg.go.dev/github.com/grokify/spectrum/openapi2))\n  1. Support for OpenAPI 2 files, including serialization, deserialization, and validation.\n  1. Merging of multiple specs\n  1. Postman 2 Collection conversion\n* openapi3 ([godoc](https://pkg.go.dev/github.com/grokify/spectrum/openapi3))\n  1. Support for OpenAPI 3 files, including serialization, deserialization, and validation.\n  1. Merging of multiple specs\n  1. Splitting specs by tag\n  1. Output of spec to tabular format to HTML (API Registry), CSV, XLSX. HTML API Registry has a bonus feature that makes each line clickable. Click any line here: http://ringcentral.github.io/api-registry/\n  1. Programmatic API to modify OpenAPI specs using rules\n  1. [Programmatic ability to \"fix\" spec, e.g. change response Content Type to match output (needed for Engage Voice)](docs/openapi3_fix.md)\n  1. [OpenAPI 3 linter](openapi3/openapi3lint)\n  1. Statistics: Counts operations, schemas, properties \u0026 parameters (with and without descriptions), etc.\n  1. Postman 2 Collection conversion\n  1. Ability to merge in Postman request body examples into Postman 2 Collection\n  1. Functionality is built on *kin-openapi*: https://github.com/getkin/kin-openapi\n* openapi3edit ([godoc](https://pkg.go.dev/github.com/grokify/spectrum/openapi3edit))\n  1. Programmatic SDK-based editor for OAS3 specifications.\n* openapi3lint ([godoc](https://pkg.go.dev/github.com/grokify/spectrum/openapi3lint))\n  1. Extensible linter for OAS3 specifications.\n* postman2 ([godoc](https://pkg.go.dev/github.com/grokify/spectrum/postman2))\n  1. Support for Postman 2 Collection files, including serialization and deserialization.\n  1. CLI and library to Convert OpenAPI Specs to Postman Collection\n  1. Add Postman environment variables to URLs, e.g. Server URLs like `https://{{HOSTNAME}}/restapi`\n  1. Add headers, such as environment variable based Authorization headers, such as `Authorization: Bearer {{myAccessToken}}`\n  1. Utilize baseline Postman collection to add Postman-specific functionality including Postman `prerequest` scripts.\n  1. Add example request bodies, e.g. JSON bodies with example parameter values.\n* raml08\n  1. Support for parsing RAML v0.8\n  1. Limited functionality to extracting OpenAPI v3 `description` and `summary` from `description` and `displayName` respectively.\n\n## Notes\n\n* Postman 4.10.7 does not natively support JSON requests so request bodies need to be entered using the raw body editor. A future task is to add Swagger request examples as default Postman request bodies.\n* Postman 2.0 spec supports polymorphism and doesn't have a canonical schema. For example, the `request.url` property can be populated by a URL string or a URL object. Spectrum uses the URL object since it is more flexible. The function `simple.NewCanonicalCollectionFromBytes(bytes)` can be used to read either a simple or object based spec into a canonical object spec.\n* This has only been used on the RingCentral Swagger spec to date but will be used for more in the future. Please feel free to use and contribute. Examples are located in the `examples` folder.\n\n## Installation\n\nThe following command will install the executable binary `spectrum` into the `~/go/bin` directory.\n\n```bash\n$ go get github.com/grokify/spectrum\n```\n\n## Usage\n\n### Simple Usage\n\n```\n// Instantiate a converter with default configuration\nconv := spectrum.NewConverter(spectrum.Configuration{})\n\n// Convert a Swagger spec\nerr := conv.Convert(\"path/to/swagger.json\", \"path/to/pman.out.json\")\n```\n\n### Usage with Features\n\nThe following can be added which are especially useful to use with environment variables.\n\n* Custom Hostname\n* Custom Headers\n\n```\n// Instantiate a converter with overrides (using Postman environment variables)\ncfg := spectrum.Configuration{\n\tPostmanURLBase: \"{{RINGCENTRAL_SERVER_URL}}\",\n\tPostmanHeaders: []postman2.Header{\n\t\t{\n\t\t\tKey:   \"Authorization\",\n\t\t\tValue: \"Bearer {{my_access_token}}\",\n\t\t},\n\t},\n}\nconv = spectrum.NewConverter(cfg)\n\n// Convert a Swagger spec with a default Postman spec\nerr := conv.MergeConvert(\"path/to/swagger.json\", \"path/to/pman.base.json\", \"path/to/pman.out.json\")\n```\n\n### Example\n\nAn example conversion is included, [`examples/ringcentral/convert.go`](https://github.com/grokify/spectrum/blob/master/examples/ringcentral/convert.go) which creates a Postman 2.0 spec for the [RingCentral REST API](https://developers.ringcentral.com) using a base Postman 2.0 spec and the RingCentral basic Swagger 2.0 spec.\n\n[A video of importing the resulting Postman collection is available on YouTube](https://youtu.be/5kE4UPXJ-5Q).\n\nExample files include:\n\n* [RingCentral Swagger 2.0 spec](https://github.com/grokify/spectrum/blob/master/examples/ringcentral/ringcentral.spec.swagger2.2019110220191017-1140.json)\n* [RingCentral Postman 2.0 base](https://github.com/grokify/spectrum/blob/master/examples/ringcentral/ringcentral.postman2.base.json)\n* [RingCentral Postman 2.0 spec](https://github.com/grokify/spectrum/blob/master/examples/ringcentral/ringcentral.spec.postman2.2019110220191017-1140.json) - Import this into Postman\n\nThe RingCentral spec uses the following environment variables. The following is the Postman bulk edit format:\n\n```\nRC_SERVER_HOSTNAME:platform.devtest.ringcentral.com\nRC_APP_KEY:myAppKey\nRC_APP_SECRET:myAppSecret\nRC_USERNAME:myMainCompanyPhoneNumber\nRC_EXTENSION:myExtension\nRC_PASSWORD:myPassword\n```\n\nFor multiple apps or users, simply create a different Postman environment for each.\n\nTo set your environment variables, use the Settings Gear icon and then click \"Manage Environments\"\n\n## Articles and Links\n\n* Medium: [Using Postman, Swagger and the RingCentral API](https://medium.com/ringcentral-developers/using-postman-with-swagger-and-the-ringcentral-api-523712f792a0)\n* YouTube: [Getting Started with RingCentral APIs using Postman](https://youtu.be/5kE4UPXJ-5Q)\n\n [build-status-svg]: https://github.com/grokify/spectrum/actions/workflows/ci.yaml/badge.svg?branch=master\n [build-status-url]: https://github.com/grokify/spectrum/actions/workflows/ci.yaml\n [lint-status-svg]: https://github.com/grokify/spectrum/actions/workflows/lint.yaml/badge.svg?branch=master\n [lint-status-url]: https://github.com/grokify/spectrum/actions/workflows/lint.yaml\n [goreport-svg]: https://goreportcard.com/badge/github.com/grokify/spectrum\n [goreport-url]: https://goreportcard.com/report/github.com/grokify/spectrum\n [docs-godoc-svg]: https://pkg.go.dev/badge/github.com/grokify/spectrum\n [docs-godoc-url]: https://pkg.go.dev/github.com/grokify/spectrum\n [loc-svg]: https://tokei.rs/b1/github/grokify/spectrum\n [repo-url]: https://github.com/grokify/spectrum\n [license-svg]: https://img.shields.io/badge/license-MIT-blue.svg\n [license-url]: https://github.com/grokify/spectrum/blob/master/LICENSE\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgrokify%2Fspectrum","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fgrokify%2Fspectrum","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgrokify%2Fspectrum/lists"}