{"id":15462892,"url":"https://github.com/gurpreetatwal/incito","last_synced_at":"2025-04-22T10:42:58.298Z","repository":{"id":12569097,"uuid":"72268282","full_name":"gurpreetatwal/incito","owner":"gurpreetatwal","description":"Easiest way to turn a function into a web server!","archived":false,"fork":false,"pushed_at":"2023-12-28T03:03:35.000Z","size":1198,"stargazers_count":4,"open_issues_count":6,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2024-04-15T02:08:43.841Z","etag":null,"topics":["axios","integration","middleware","route","supertest","testing"],"latest_commit_sha":null,"homepage":"","language":"JavaScript","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/gurpreetatwal.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":"2016-10-29T06:11:46.000Z","updated_at":"2024-06-21T16:43:13.937Z","dependencies_parsed_at":"2024-06-21T16:53:06.109Z","dependency_job_id":null,"html_url":"https://github.com/gurpreetatwal/incito","commit_stats":{"total_commits":95,"total_committers":6,"mean_commits":"15.833333333333334","dds":"0.42105263157894735","last_synced_commit":"f889c9dfb14654ef0bfe3e88228586e8f8020a2c"},"previous_names":[],"tags_count":8,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gurpreetatwal%2Fincito","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gurpreetatwal%2Fincito/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gurpreetatwal%2Fincito/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gurpreetatwal%2Fincito/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/gurpreetatwal","download_url":"https://codeload.github.com/gurpreetatwal/incito/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":250222302,"owners_count":21394850,"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":["axios","integration","middleware","route","supertest","testing"],"created_at":"2024-10-02T00:05:35.917Z","updated_at":"2025-04-22T10:42:58.250Z","avatar_url":"https://github.com/gurpreetatwal.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"\u003ch1 align=\"center\"\u003eincito\u003c/h1\u003e\n\n\u003cp align=\"center\"\u003e\n  \u003ca href=\"https://www.npmjs.com/package/incito\"\u003e\u003cimg src=\"https://img.shields.io/npm/v/incito.svg?style=flat-square\" alt=\"NPM Package\"\u003e\u003c/a\u003e\n  \u003ca href=\"https://travis-ci.com/gurpreetatwal/incito\"\u003e\u003cimg src=\"https://img.shields.io/travis/com/gurpreetatwal/incito/master?style=flat-square\" alt=\"Build Status\"\u003e\u003c/a\u003e\n  \u003ca href=\"https://codecov.io/gh/gurpreetatwal/incito\"\u003e\u003cimg src=\"https://img.shields.io/codecov/c/github/gurpreetatwal/incito.svg?style=flat-square\" alt=\"Coverage\"\u003e\u003c/a\u003e\n\u003c/p\u003e\n\n\n## Installation\n\n```sh\nnpm install incito --save\n```\n\n```js\nconst incito = require('incito');\n```\n\n## Usage\n### simple http server\n```js\nconst server = incito();\nconst port = server.port;\n```\n\n### http server with listener\n```js\nfunction handle() {\n  // magical request handling code\n}\n\nconst server = incito(handle);\n```\n\n### express http server\n```js\nconst app = express();\nconst server = incito(app);\n```\n\n### koa http server\n```js\nconst app = new Koa();\nconst server = incito(app.callback());\n```\n\n### other types of servers\n```js\nconst server = incito({\n  type: 'https',\n  listener: app\n  options: {\n    key: fs.readFileSync('test/fixtures/keys/agent2-key.pem'),\n    cert: fs.readFileSync('test/fixtures/keys/agent2-cert.pem'),\n  },\n});\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgurpreetatwal%2Fincito","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fgurpreetatwal%2Fincito","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgurpreetatwal%2Fincito/lists"}