{"id":13414033,"url":"https://github.com/rbretecher/go-postman-collection","last_synced_at":"2026-03-11T02:28:05.787Z","repository":{"id":36197600,"uuid":"222094288","full_name":"rbretecher/go-postman-collection","owner":"rbretecher","description":"Go module to work with Postman Collections","archived":false,"fork":false,"pushed_at":"2024-05-17T11:59:02.000Z","size":88,"stargazers_count":86,"open_issues_count":2,"forks_count":19,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-08-14T19:18:35.977Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"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/rbretecher.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}},"created_at":"2019-11-16T12:13:32.000Z","updated_at":"2025-07-28T23:37:15.000Z","dependencies_parsed_at":"2024-10-26T09:44:57.561Z","dependency_job_id":null,"html_url":"https://github.com/rbretecher/go-postman-collection","commit_stats":null,"previous_names":[],"tags_count":11,"template":false,"template_full_name":null,"purl":"pkg:github/rbretecher/go-postman-collection","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rbretecher%2Fgo-postman-collection","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rbretecher%2Fgo-postman-collection/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rbretecher%2Fgo-postman-collection/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rbretecher%2Fgo-postman-collection/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/rbretecher","download_url":"https://codeload.github.com/rbretecher/go-postman-collection/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rbretecher%2Fgo-postman-collection/sbom","scorecard":{"id":764197,"data":{"date":"2025-08-11","repo":{"name":"github.com/rbretecher/go-postman-collection","commit":"093c43487f1d8ca71ffcb5826874124f468fb768"},"scorecard":{"version":"v5.2.1-40-gf6ed084d","commit":"f6ed084d17c9236477efd66e5b258b9d4cc7b389"},"score":3,"checks":[{"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":"Pinned-Dependencies","score":-1,"reason":"no dependencies found","details":null,"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":"Code-Review","score":1,"reason":"Found 3/21 approved changesets -- score normalized to 1","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":"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":"Token-Permissions","score":-1,"reason":"No tokens found","details":null,"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":"Dangerous-Workflow","score":-1,"reason":"no workflows found","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":"Maintained","score":0,"reason":"0 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project is \"actively maintained\".","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#maintained"}},{"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":"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":"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":"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":"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 15 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":9,"reason":"1 existing vulnerabilities detected","details":["Warn: Project is vulnerable to: GO-2022-0603 / GHSA-hp87-p4gw-j4gq"],"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-23T00:18:26.753Z","repository_id":36197600,"created_at":"2025-08-23T00:18:26.753Z","updated_at":"2025-08-23T00:18:26.753Z"},"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":30367814,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-03-10T21:41:54.280Z","status":"online","status_checked_at":"2026-03-11T02:00:07.027Z","response_time":84,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"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":[],"created_at":"2024-07-30T20:01:55.841Z","updated_at":"2026-03-11T02:28:05.750Z","avatar_url":"https://github.com/rbretecher.png","language":"Go","funding_links":[],"categories":["Third-party APIs","第三方api","第三方API`第三方API 汇总`","第三方API","Utility"],"sub_categories":["Utility/Miscellaneous","实用程序/Miscellaneous","查询语","Fail injection","HTTP Clients"],"readme":"# go-postman-collection\n\n[![Mentioned in Awesome Go](https://awesome.re/mentioned-badge.svg)](https://github.com/avelino/awesome-go)\n[![GoDoc](https://img.shields.io/badge/godoc-reference-blue.svg)](https://godoc.org/github.com/rbretecher/go-postman-collection)\n[![Build Status](https://travis-ci.org/rbretecher/go-postman-collection.svg?branch=master)](https://travis-ci.org/rbretecher/go-postman-collection)\n[![Report](https://goreportcard.com/badge/github.com/rbretecher/go-postman-collection)](https://goreportcard.com/report/github.com/rbretecher/go-postman-collection)\n[![Code coverage](https://codecov.io/gh/rbretecher/go-postman-collection/branch/master/graph/badge.svg)](https://codecov.io/gh/rbretecher/go-postman-collection)\n\nGo module to work with Postman Collections.\n\nThis module aims to provide a simple way to work with Postman collections. Using this module, you can create collections, update them and export them into the Postman Collection format v2 (compatible with Insomnia)\n\nPostman Collections are a group of saved requests you can organize into folders. For more information about Postman Collections, you can visit the [official documentation](https://www.getpostman.com/collection).\n\n## Examples\n\n### Collections\n\n#### Read a Postman Collection\n\n```go\npackage main\n\nimport (\n\t\"os\"\n\n\tpostman \"github.com/rbretecher/go-postman-collection\"\n)\n\nfunc main() {\n\tfile, err := os.Open(\"postman_collection.json\")\n\tdefer file.Close()\n\n\tif err != nil {\n\t\tpanic(err)\n\t}\n\n\tc, err := postman.ParseCollection(file)\n\n\t_ = c\n}\n```\n\n#### Create and save a Postman Collection\n\n```go\npackage main\n\nimport (\n\t\"os\"\n\n\tpostman \"github.com/rbretecher/go-postman-collection\"\n)\n\nfunc main() {\n    c := postman.CreateCollection(\"My collection\", \"My awesome collection\")\n\n    c.AddItemGroup(\"A folder\").AddItem(\u0026postman.Item{\n        Name:    \"This is a request\",\n        Request: Request{\n            URL: \u0026URL{\n                Raw: \"http://www.google.fr\",\n            },\n            Method: postman.Get,\n        },\n    })\n\n    file, err := os.Create(\"postman_collection.json\")\n    defer file.Close()\n\n    if err != nil {\n        panic(err)\n    }\n\n    err = c.Write(file)\n\n    if err != nil {\n        panic(err)\n    }\n}\n```\n\n### Items\n\n`Items` are the basic unit for a Postman collection, it can either be a request (`Item`) or a folder (`ItemGroup`).\n\n```go\n// Create a simple item.\nitem := postman.CreateItem(postman.Item{\n    Name:    \"A basic request\",\n    Request: Request{\n        URL: \u0026URL{\n            Raw: \"http://www.google.fr\",\n        },\n        Method: postman.Get,\n    }\n})\n\n// Create a simple folder.\nfolder := postman.CreateItemGroup(postman.ItemGroup{\n    Name: \"A folder\",\n})\n\n// Add the item to the folder\nfolder.AddItem(item)\n```\n\n### Request\n\nPart of the `Item`, a `Request` represents an HTTP request.\n\n```go\n// Basic request\nreq := Request{\n    URL: \u0026URL{\n        Raw: \"http://www.google.fr\",\n    },\n    Method: postman.Get,\n}\n\n// Complex request\nreq := postman.Request{\n    URL: \u0026postman.URL{\n        Raw: \"http://www.google.fr\",\n    },\n    Method: postman.Post,\n    Body: \u0026postman.Body{\n        Mode: \"raw\",\n        Raw:  \"{\\\"key\\\": \\\"value\\\"}\",\n    },\n}\n```\n\n### Auth\n\n`Auth` can be added to a `Request` or an `ItemGroup`.\n\n```go\n// Create basic auth with username and password\nauth := postman.CreateAuth(postman.Basic, postman.CreateAuthParam(\"username\", \"password\"))\n```\n\n### Variable\n\n`Variable` can be added to `Collection`, `Item`, `ItemGroup` and `URL`.\n\n```go\nv := postman.CreateVariable(\"env\", \"prod\")\n```\n\n## Current support\n\nFor now, it does not offer support all objects. Feel free to submit a pull request if you want to add support for one of those objects.\n\n|  Object            | v2.0.0 | v2.1.0 |\n| ------------------ | ------ | ------ |\n| Collection         | Yes    | Yes    |\n| ItemGroup (Folder) | Yes    | Yes    |\n| Item               | Yes    | Yes    |\n| Request            | Yes    | Yes    |\n| Response           | Yes    | Yes    |\n| Event              | Yes    | Yes    |\n| Variable           | Yes    | Yes    |\n| Auth               | Yes    | Yes    |\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frbretecher%2Fgo-postman-collection","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Frbretecher%2Fgo-postman-collection","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frbretecher%2Fgo-postman-collection/lists"}