{"id":16966962,"url":"https://github.com/cyberboysumanjay/carbon-api","last_synced_at":"2025-07-29T16:04:59.623Z","repository":{"id":46681934,"uuid":"267670106","full_name":"cyberboysumanjay/Carbon-API","owner":"cyberboysumanjay","description":"Unofficial API for generating beautiful images of your source code using Carbon.","archived":false,"fork":false,"pushed_at":"2023-09-26T10:12:59.000Z","size":101,"stargazers_count":190,"open_issues_count":8,"forks_count":46,"subscribers_count":5,"default_branch":"master","last_synced_at":"2025-04-01T16:11:18.720Z","etag":null,"topics":["api","beautiful","beautiful-code","carbon","carbonnowsh","code","flask","get","heroku","image","post","pyppeteer","python","python3","snippet"],"latest_commit_sha":null,"homepage":"https://carbonnowsh.herokuapp.com/","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"lgpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/cyberboysumanjay.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":"2020-05-28T18:49:01.000Z","updated_at":"2025-04-01T12:00:02.000Z","dependencies_parsed_at":"2024-10-26T21:19:51.103Z","dependency_job_id":"d69a0366-b5bc-4f64-9602-e32416a33436","html_url":"https://github.com/cyberboysumanjay/Carbon-API","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/cyberboysumanjay/Carbon-API","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cyberboysumanjay%2FCarbon-API","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cyberboysumanjay%2FCarbon-API/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cyberboysumanjay%2FCarbon-API/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cyberboysumanjay%2FCarbon-API/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/cyberboysumanjay","download_url":"https://codeload.github.com/cyberboysumanjay/Carbon-API/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cyberboysumanjay%2FCarbon-API/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":267716435,"owners_count":24133143,"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","status":"online","status_checked_at":"2025-07-29T02:00:12.549Z","response_time":2574,"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":["api","beautiful","beautiful-code","carbon","carbonnowsh","code","flask","get","heroku","image","post","pyppeteer","python","python3","snippet"],"created_at":"2024-10-14T00:06:52.687Z","updated_at":"2025-07-29T16:04:59.588Z","avatar_url":"https://github.com/cyberboysumanjay.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Carbon API [Unofficial]\n---\n\u003cp align=\"center\"\u003e\n    \u003ca href=\"https://github.com/carbon-app/carbon\"\u003e\n        \u003cimg src=\"resources/carbon.png\" alt=\"Carbon\"\u003e\n    \u003c/a\u003e\n    \u003cbr\u003e\n    \u003cb\u003eUnofficial API\u003c/b\u003e\n    \u003cbr\u003e\n\u003c/p\u003e\n\n### Show some :heart: and :star: the repo\n\n[![GitHub stars](https://img.shields.io/github/stars/cyberboysumanjay/Carbon-API.svg?style=social\u0026label=Star)](https://github.com/cyberboysumanjay/JioSaavnAPI)\n![GitHub followers](https://img.shields.io/github/followers/cyberboysumanjay.svg?style=social\u0026label=Follow)\n[![Telegram Channel](https://img.shields.io/badge/Telegram-Channel-orange)](https://t.me/sjprojects)\n\n## Carbon API written in Python using Flask and Pyppeteer\n[![made-with-python](https://img.shields.io/badge/Made%20with-Python-1f425f.svg)](https://www.python.org/) [![Open Source Love svg1](https://badges.frapsoft.com/os/v1/open-source.svg?v=103)](https://github.com/ellerbrock/open-source-badges/)\n\n\u003e **Carbon**  makes it easy to create and share beautiful images of your source code\n\n#### Usage\nYou can use the API by sending a GET or a POST request using these params\n\n| parameter              | default                    | type    | description                                      |\n| ---------------------- | -------------------------- | ------- | ------------------------------------------------ |\n| `code` (required)      |                            | string  | Code snippet                                     |\n| `backgroundColor`      | `\"rgba(171, 184, 195, 1)\"` | string  | Hex or rgba color                                |\n| `dropShadow`           | `true`                     | boolean | Turn on/off shadow                               |\n| `dropShadowBlurRadius` | `\"68px\"`                   | string  | shadow blur radius                               |\n| `dropShadowOffsetY`    | `\"20px\"`                   | string  | shadow offset y                                  |\n| `exportSize`           | `\"2x\"`                     | string  | resolution of exported image, e.g. `1x`, `3x`    |\n| `fontSize`             | `\"14px\"`                   | string  | font size                                        |\n| `fontFamily`           | `\"Hack\"`                   | string  | font family, e.g. `JetBrains Mono`, `Fira Code`. |\n| `firstLineNumber`      | `1`                        | number  | first line number                                |\n| `language`             | `\"auto\"`                   | string  | programing language for properly highlighting    |\n| `lineNumbers`          | `false`                    | boolean | turn on/off line number                          |\n| `paddingHorizontal`    | `\"56px\"`                   | string  | horizontal padding                               |\n| `paddingVertical`      | `\"56px\"`                   | string  | vertical padding                                 |\n| `theme`                | `\"seti\"`                   | string  | code theme                                       |\n| `watermark`            | `false`                    | boolean | turn on/off watermark                            |\n| `widthAdjustment`      | `true`                     | boolean | turn on/off width adjustment                     |\n| `windowControls`       | `true`                     | boolean | turn on/off window controls                      |\n| `windowTheme`          | `\"none\"`                   | string  | window theme                                     |\n\n### GET `/`\nParams are encoded in url\n```bash\nhttps://carbonnowsh.herokuapp.com/?code=Made+with+Love+in+India+by+Sumanjay\u0026theme=darcula\u0026backgroundColor=rgba(144, 19, 254, 100)\n```\n\n### POST `/`\n\n**Body** is JSON with these params:\n\n```json\n{\n    \"backgroundColor\": \"rgba(144, 19, 254, 100)\",\n    \"code\": \"Made with Love in India by Sumanjay\",\n    \"theme\": \"dracula\"\n}\n```\n\n### RESPONSE\n**Response** is an image of a code or text snippet.\n\u003cp align=\"center\"\u003e\n    \u003ca href=\"https://github.com/cyberboysumanjay\"\u003e\n        \u003cimg src=\"resources/response.png\" alt=\"Response\"\u003e\n    \u003c/a\u003e\n\u003c/p\u003e\n\n#### Deploy Option\n\n* **[Heroku](https://www.heroku.com/) Method** \n  [![Deploy](https://www.herokucdn.com/deploy/button.svg)](https://heroku.com/deploy?template=https://github.com/cyberboysumanjay/Carbon-API/tree/master)\n\n* **Other Method** \n\n  ```bash\n  # Clone the repo\n  git clone https://github.com/cyberboysumanjay/Carbon-API\n  cd Carbon-API\n\n  # Create virtualenv\n  virtualenv -p /usr/bin/python3 venv\n  ../venv/bin/activate\n\n  # Install requirements\n  pip3 install -r requirements.txt\n\n  # Finally run the app\n  python3 app.py\n  ```\n### Made with ❤️️ in India\n### Copyright \u0026 License \n\n* Copyright (C) 2020 by [Sumanjay](https://github.com/cyberboysumanjay)\n* Licensed under the terms of the [GNU GPL Version 3](https://github.com/cyberboysumanjay/Carbon-API/blob/master/LICENSE)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcyberboysumanjay%2Fcarbon-api","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcyberboysumanjay%2Fcarbon-api","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcyberboysumanjay%2Fcarbon-api/lists"}