{"id":31159549,"url":"https://github.com/blockful/ccip-express","last_synced_at":"2025-09-19T01:48:50.486Z","repository":{"id":248933795,"uuid":"830003264","full_name":"blockful/ccip-express","owner":"blockful","description":"CCIP-Read Express router implementation","archived":false,"fork":false,"pushed_at":"2024-07-17T21:14:18.000Z","size":32,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2025-07-11T15:54:14.963Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"TypeScript","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/blockful.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":"2024-07-17T12:21:42.000Z","updated_at":"2024-07-17T21:14:22.000Z","dependencies_parsed_at":"2024-07-18T01:42:42.331Z","dependency_job_id":null,"html_url":"https://github.com/blockful/ccip-express","commit_stats":null,"previous_names":["blockful-io/ccip-express","blockful/ccip-express"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/blockful/ccip-express","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/blockful%2Fccip-express","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/blockful%2Fccip-express/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/blockful%2Fccip-express/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/blockful%2Fccip-express/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/blockful","download_url":"https://codeload.github.com/blockful/ccip-express/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/blockful%2Fccip-express/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":275867689,"owners_count":25542804,"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-09-18T02:00:09.552Z","response_time":77,"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":"2025-09-19T01:48:46.728Z","updated_at":"2025-09-19T01:48:50.447Z","avatar_url":"https://github.com/blockful.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# CCIP Express\n\nExpress CCIP-Read handler.\n\n## Motivation\n\nThis lib was created with the purpose of making it easier to implement APIs that are fully  compliant with the [EIP-3668](https://eips.ethereum.org/EIPS/eip-3668) specification.\nIts differential is that it is capable of handling middlewares per function by attaching any given number of endpoints to an Express router.\n\n## Usage\n\nThe supported request looks like the following:\n\n```shell\n# abi.encodeWithSelector(0x59d1d43c, 'com.twitter', '@blockful')\nCALLDATA='0x59d1d43c194774734a8c16665005fd2c68cb7cc80b5aa6ffcb0c56ace654bc614902cf7f00000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000008626c6f636b66756c000000000000000000000000000000000000000000000000'\n\ncurl -X GET http://127.0.0.1/0x6AEBB4AdC056F3B01d225fE34c20b1FdC21323A2/$(CALLDATA)\n\ncurl -X POST http://127.0.0.1 -H \"Content-Type: application/json\" \\\n-d '{\"sender\": \"0x6AEBB4AdC056F3B01d225fE34c20b1FdC21323A2\", \"calldata\": $(CALLDATA)}'\n```\n\n### Single handler with no middlewares\n\n```ts\nconst handlers : FunctionHandler[] = [\n  {\n    signature: 'function text(bytes32 node, string key) view returns (string)',\n    handlers: [\n      (_: Request, res: Response, __: NextFunction) =\u003e {\n        const { node, key } = res.locals\n        res.json({ node, key })\n      }\n    ]\n  }\n]\n\napp.use(CCIPHandler(handlers))\n```\n\n### Multiple handlers with not middlewares\n\n```ts\nconst handlers : FunctionHandler[] = [\n  {\n    signature: 'function text(bytes32 node, string key) view returns (string)',\n    handlers: [\n      (_: Request, res: Response, __: NextFunction) =\u003e {\n        const { node, key } = res.locals\n        res.json({ node, key })\n      }\n    ]\n  },\n  {\n    signature: 'function setText(bytes32 node, string calldata key, string calldata value)',\n    handlers: [\n      (_: Request, res: Response, __: NextFunction) =\u003e {\n        const { node, key } = res.locals\n        res.json({ node, key })\n      }\n    ]\n  }\n]\n\napp.use(CCIPHandler(handlers))\n```\n\n### Single handler with middlewares\n\n```ts\nconst handlers : FunctionHandler[] = [\n  {\n    signature: 'function text(bytes32 node, string key) view returns (string)',\n    handlers: [\n      (_: Request, res: Response, next: NextFunction) =\u003e {\n        next()\n      },\n      (_: Request, res: Response, __: NextFunction) =\u003e {\n        const { node, key } = res.locals\n        res.json({ node, key })\n      },\n      (_: Request, res: Response, next: NextFunction) =\u003e {\n        next()\n      },\n    ]\n  }\n]\n\napp.use(CCIPHandler(handlers))\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fblockful%2Fccip-express","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fblockful%2Fccip-express","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fblockful%2Fccip-express/lists"}