{"id":16544530,"url":"https://github.com/msoedov/coorl","last_synced_at":"2026-05-16T11:04:14.111Z","repository":{"id":74829801,"uuid":"120974347","full_name":"msoedov/coorl","owner":"msoedov","description":"A coooool curl command from net/http","archived":false,"fork":false,"pushed_at":"2018-02-12T22:14:10.000Z","size":9,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"master","last_synced_at":"2025-10-12T02:17:04.859Z","etag":null,"topics":["curl","golang","net-http"],"latest_commit_sha":null,"homepage":"","language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/msoedov.png","metadata":{"files":{"readme":"Readme.md","changelog":null,"contributing":null,"funding":null,"license":null,"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":"2018-02-10T01:41:34.000Z","updated_at":"2019-02-23T02:01:15.000Z","dependencies_parsed_at":null,"dependency_job_id":"0e0f3b6d-8462-4c09-80aa-5db64c660784","html_url":"https://github.com/msoedov/coorl","commit_stats":{"total_commits":8,"total_committers":1,"mean_commits":8.0,"dds":0.0,"last_synced_commit":"113ac92666cd1dc38c445211c6cdcf5ae70179b1"},"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/msoedov/coorl","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/msoedov%2Fcoorl","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/msoedov%2Fcoorl/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/msoedov%2Fcoorl/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/msoedov%2Fcoorl/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/msoedov","download_url":"https://codeload.github.com/msoedov/coorl/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/msoedov%2Fcoorl/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":33100319,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-16T04:41:52.686Z","status":"ssl_error","status_checked_at":"2026-05-16T04:41:52.009Z","response_time":115,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: 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":["curl","golang","net-http"],"created_at":"2024-10-11T19:03:07.871Z","updated_at":"2026-05-16T11:04:14.084Z","avatar_url":"https://github.com/msoedov.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Coorl\n\nTranslates `net/http` to a coooool curl command for debugging and troubleshooting\n\n## Getting Started\n\nExample\n\n```go\nurl := \"http://restapi3.apiary.io/notes\"\njsonStr := []byte(`{\"title\":\"Buy cheese and bread for breakfast.\"}`)\nb := bytes.NewReader(jsonStr)\nreq, err := http.NewRequest(\"POST\", url, b)\nreq.Header.Set(\"X-Custom-Header\", \"myvalue\")\nreq.Header.Set(\"Content-Type\", \"application/json\")\nclient := \u0026http.Client{}\n_, err = client.Do(req)\nif err != nil {\n    panic(err)\n}\n\nfmt.Printf(\"%s\\n\", coorl.AsCurl(req, b))\n\n```\n\nOutput\n```bash\ncurl -v  --request POST -H 'X-Custom-Header: myvalue' -H 'Content-Type: application/json' --data '{\\\"title\\\":\\\"Buy cheese and bread for breakfast.\\\"}' http://restapi3.apiary.io/notes\n```\n\nTranslate to `httpie`\n\n```go\nfmt.Printf(\"%s\\n\", coorl.AsHttpie(req, b))\n```\n\n```shell\necho '{\\\"title\\\":\\\"Buy cheese and bread for breakfast.\\\"}' | http -v POST http://restapi3.apiary.io/notes X-Custom-Header:myvalue Content-Type:application/json\n```\n### Prerequisites\n```go\npackage coorl // import \"github.com/msoedov/coorl\"\n\nfunc AsCurl(r *http.Request, body io.ReadSeeker) (cmd string)\nfunc AsHttpie(r *http.Request, body io.ReadSeeker) (cmd string)\n```\n\n### Installing\n\nA step by step series of examples that tell you have to get a development env running\n\n```shell\ngo get -u github.com/msoedov/coorl\n```\n\n## Running the tests\n\n```\ngo test\n```\n\n\n## License\n\nThis project is licensed under the MIT License - see the [LICENSE.md](LICENSE.md) file for details\n\n## Acknowledgments\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmsoedov%2Fcoorl","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmsoedov%2Fcoorl","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmsoedov%2Fcoorl/lists"}