{"id":16390321,"url":"https://github.com/qertis/request-json-rpc2","last_synced_at":"2026-01-26T04:07:52.910Z","repository":{"id":65184922,"uuid":"584336766","full_name":"qertis/request-json-rpc2","owner":"qertis","description":"Simplified JSON-RPC2 request client.","archived":false,"fork":false,"pushed_at":"2025-02-10T17:30:20.000Z","size":229,"stargazers_count":1,"open_issues_count":0,"forks_count":1,"subscribers_count":0,"default_branch":"master","last_synced_at":"2025-09-08T20:33:07.698Z","etag":null,"topics":["json-rpc-api","json-rpc-client","json-rpc2","json-rpc2-client","jsonrpc-client","jsonrpc2","rpc"],"latest_commit_sha":null,"homepage":"https://www.npmjs.com/package/request-json-rpc2","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/qertis.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,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2023-01-02T09:22:13.000Z","updated_at":"2025-02-10T17:30:23.000Z","dependencies_parsed_at":"2025-09-08T20:32:34.791Z","dependency_job_id":"f4afd425-6731-4d0a-98c8-5f0a5352ae26","html_url":"https://github.com/qertis/request-json-rpc2","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/qertis/request-json-rpc2","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/qertis%2Frequest-json-rpc2","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/qertis%2Frequest-json-rpc2/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/qertis%2Frequest-json-rpc2/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/qertis%2Frequest-json-rpc2/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/qertis","download_url":"https://codeload.github.com/qertis/request-json-rpc2/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/qertis%2Frequest-json-rpc2/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28766472,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-26T03:54:34.369Z","status":"ssl_error","status_checked_at":"2026-01-26T03:54:33.031Z","response_time":59,"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":["json-rpc-api","json-rpc-client","json-rpc2","json-rpc2-client","jsonrpc-client","jsonrpc2","rpc"],"created_at":"2024-10-11T04:42:50.589Z","updated_at":"2026-01-26T04:07:52.896Z","avatar_url":"https://github.com/qertis.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# REQUEST JSON RPC2\n\u003e Simplified JSON-RPC 2.0 CJS and ESM client\n\n## Examples\n\nSuper simple to use request JSON-RPC 2 is designed to be the simplest way possible to make JSON-RPC 2 calls.\n\n```javascript\nimport requestJsonRpc2 from 'request-json-rpc2';\n\nconst result = await requestJsonRpc2({\n  url: String,\n  body: {\n    method: String,\n    params: Array | Object,\n  },\n});\n```\n\nPowerful sample\n\n```javascript\nconst result = await requestJsonRpc2({\n  url: '/api',\n  body: {\n    id: '1234567890',\n    method: 'record',\n    params: {\n      \"$schema\": \"http://json-schema.org/draft-04/schema#\",\n      \"$id\": \"https://example.com/employee.schema.json\",\n      \"title\": \"Record of employee\",\n      \"description\": \"This document records the details of an employee\",\n      \"type\": \"object\",\n      \"properties\": {\n        \"id\": {\n          \"description\": \"A unique identifier for an employee\",\n          \"type\": \"number\",\n        },\n      },\n    },\n  },\n  headers: {\n    'Accept': 'application/schema+json',\n  },\n});\n```\n\n### HTTP Authentication\n\nIncludes basic or bearer.\n\n```javascript\nconst result = await requestJsonRpc2({\n  url: '/api',\n  body: {\n    method: 'YOUR_METHOD',\n    params: ['auth hello world'],\n  }, \n  auth: {\n    'user': 'username',\n    'pass': 'password',\n    'sendImmediately': false,\n  },\n});\n```\n\n### JWT\n\nJSON Web Token example.\n\n```javascript\nconst result = await requestJsonRpc2({\n  url: '/api',\n  body: {\n    method: 'YOUR_METHOD',\n    params: ['JWT hello world'],\n  },\n  headers: {\n    'Authorization': 'Bearer ewogICJhbGciOiAiSFMyNTYiLAogICJ0eXAiOiAiSldUIgp9.ewogICJuYW1lIjogIlJlcXVlc3QgSlNPTi1SUEMgMi4wIgp9',\n  },\n});\n```\n\n### Ed25519Signature2018\n\n```javascript\nconst result = await requestJsonRpc2({\n  url: '/api',\n  body: {\n    method: 'YOUR_METHOD',\n    params: ['signature hello world'],\n  },\n  signature: {\n    \"@context\": [\"https://w3id.org/security/v2\"],\n    \"id\": \"did:example:123456789abcdefghi#keys-1\",\n    \"type\": \"Ed25519VerificationKey2018\",\n    \"controller\": \"did:example:123456789abcdefghi\",\n    \"expires\": \"2023-01-08T16:02:20Z\",\n    \"publicKeyBase58\": \"H3C2AVvLMv6gmMNam3uVAjZpfkcJCwDwnZn6z3wXmqPV\",\n  },\n});\n```\n\n## Testing\n\nSee [tests directory](https://github.com/qertis/request-json-rpc2/tree/master/tests).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fqertis%2Frequest-json-rpc2","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fqertis%2Frequest-json-rpc2","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fqertis%2Frequest-json-rpc2/lists"}