{"id":13895009,"url":"https://github.com/Integralist/carbon","last_synced_at":"2025-07-17T10:32:00.131Z","repository":{"id":57547882,"uuid":"81642496","full_name":"Integralist/carbon","owner":"Integralist","description":"HTTP Response Header Sorting and Filtering","archived":false,"fork":false,"pushed_at":"2022-01-19T17:14:21.000Z","size":277,"stargazers_count":4,"open_issues_count":0,"forks_count":2,"subscribers_count":3,"default_branch":"main","last_synced_at":"2024-11-16T11:10:32.798Z","etag":null,"topics":["go","golang","http","http-client","http-header","http-response","open-source"],"latest_commit_sha":null,"homepage":"","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/Integralist.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}},"created_at":"2017-02-11T09:11:43.000Z","updated_at":"2023-03-21T23:30:42.000Z","dependencies_parsed_at":"2022-09-26T18:41:03.013Z","dependency_job_id":null,"html_url":"https://github.com/Integralist/carbon","commit_stats":null,"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Integralist%2Fcarbon","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Integralist%2Fcarbon/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Integralist%2Fcarbon/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Integralist%2Fcarbon/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Integralist","download_url":"https://codeload.github.com/Integralist/carbon/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":226255253,"owners_count":17595859,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","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":["go","golang","http","http-client","http-header","http-response","open-source"],"created_at":"2024-08-06T18:01:55.694Z","updated_at":"2024-11-25T00:30:28.832Z","avatar_url":"https://github.com/Integralist.png","language":"Go","readme":"# Carbon\n\nCarbon is a tool that issues HTTP requests, then parses, sorts and displays relevant HTTP response headers. \n\n\u003e **NOTE**: The name 'carbon' comes from carbon filtering: method of filtering impurities.\n\nBy default it will display all response headers with coloured keys, but headers can also be filtered, as well as parsed into JSON for easier piping/analysis...\n\n![Example output of running the carbon executable](./carbon.png)\n\n## Install\n\n```bash\ngo install github.com/integralist/carbon@latest\n```\n\n## Build\n\nTo build and install the `carbon` executable locally, then run:\n\n```bash\nmake install\n```\n\n## Usage\n\n```bash\ncarbon -help\n\nUsage of carbon:\n  -filter string\n        comma-separated list of headers to be displayed\n        e.g. cache,vary\n  -help\n        show available flags\n  -json\n        output is formatted into JSON for easy parsing\n  -plain\n    \t  output is formatted without any extraneous spacing or ANSI colour codes\n```\n\nNo filter...\n\n```bash\ncarbon https://www.fastly.com/\n\nAccept-Ranges:\n  [bytes]\n\nCache-Control:\n  [max-age=0, private, must-revalidate]\n\nContent-Type:\n  [text/html]\n\nDate:\n  [Tue, 27 Oct 2020 09:55:39 GMT]\n\nEtag:\n  [\"c248491ee6293167e071523b47b4625e\"]\n\nServer:\n  [Artisanal bits]\n\nStrict-Transport-Security:\n  [max-age=31536000]\n\nVary:\n  [Accept-Encoding]\n\nX-Cache:\n  [HIT]\n\nX-Content-Type-Options:\n  [nosniff]\n\nX-Frame-Options:\n  [DENY]\n\nX-Xss-Protection:\n  [1; mode=block]\n\nStatus Code: 200 OK\n```\n\nWith filter...\n\n```bash\ncarbon -filter cache,vary https://www.fastly.com\n\nCache-Control:\n  [max-age=0, private, must-revalidate]\n\nVary:\n  [Accept-Encoding]\n\nX-Cache:\n  [HIT]\n\nStatus Code: 200 OK\n```\n\nWith filter AND json...\n\n```bash\ncarbon -filter cache,vary --json https://www.fastly.com\n\n[{\"Key\":\"Cache-Control\",\"Val\":[\"max-age=0, private, must-revalidate\"]},{\"Key\":\"Vary\",\"Val\":[\"Accept-Encoding\"]},{\"Key\":\"X-Cache\",\"Val\":[\"HIT\"]},{\"Key\":\"X-Cache-Hits\",\"Val\":[\"2\"]}]\n```\n\nPlain...\n\n```bash\ncarbon -filter cache,vary -plain https://www.fastly.com\n\nCache-Control: max-age=0, private, must-revalidate\nVary: Accept-Encoding\nX-Cache: HIT\nStatus Code: 200 OK\n```\n\n## Tests?\n\nNope. This was just a quick hack\n\n## Bash Alternative?\n\nHere's an official repo for the [Bash version](https://github.com/Integralist/Bash-Headers) (if you're interested, although it's a lot more basic but was the starting point that motivated me to do this go version).\n","funding_links":[],"categories":["Go"],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FIntegralist%2Fcarbon","html_url":"https://awesome.ecosyste.ms/projects/github.com%2FIntegralist%2Fcarbon","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FIntegralist%2Fcarbon/lists"}