{"id":50988303,"url":"https://github.com/hellodword/curl-parser","last_synced_at":"2026-06-19T22:31:35.494Z","repository":{"id":365739967,"uuid":"1273497666","full_name":"hellodword/curl-parser","owner":"hellodword","description":null,"archived":false,"fork":false,"pushed_at":"2026-06-18T16:32:16.000Z","size":127,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"master","last_synced_at":"2026-06-18T18:11:51.662Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"C","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/hellodword.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":"2026-06-18T15:24:13.000Z","updated_at":"2026-06-18T16:30:54.000Z","dependencies_parsed_at":null,"dependency_job_id":null,"html_url":"https://github.com/hellodword/curl-parser","commit_stats":null,"previous_names":["hellodword/curl-parser"],"tags_count":null,"template":false,"template_full_name":null,"purl":"pkg:github/hellodword/curl-parser","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hellodword%2Fcurl-parser","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hellodword%2Fcurl-parser/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hellodword%2Fcurl-parser/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hellodword%2Fcurl-parser/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/hellodword","download_url":"https://codeload.github.com/hellodword/curl-parser/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hellodword%2Fcurl-parser/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":34550858,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-26T15:22:16.424Z","status":"online","status_checked_at":"2026-06-19T02:00:06.005Z","response_time":61,"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":"2026-06-19T22:31:35.423Z","updated_at":"2026-06-19T22:31:35.488Z","avatar_url":"https://github.com/hellodword.png","language":"C","funding_links":[],"categories":[],"sub_categories":[],"readme":"# curl-parser\n\n`curl-parser` parses curl argv into structured JSON by reusing the selected\ncurl command-line parser source. It does not perform network transfers.\n\nScope:\n\n- Parse argv-form curl CLI syntax only.\n- Do not perform network transfers.\n- Do not read host files by default.\n- Use curl source version `curl-8_20_0`.\n- Build native and wasm artifacts through a configurable C compiler. The\n  default `CC`/`WASM_CC` is `zig cc`.\n\nPrimary artifact:\n\n- `dist/curl_parser.wasm`\n\nHost examples:\n\n- `wrappers/node/`\n- `wrappers/python/`\n\nSchemas:\n\n- `schemas/parse-input.schema.json`\n- `schemas/parse-output.schema.json`\n- `schemas/runtime-profile.schema.json`\n\n## Build\n\n```bash\npython scripts/tasks.py bootstrap\npython scripts/tasks.py generate\npython scripts/tasks.py build-wasm\npython scripts/tasks.py test\n```\n\n`bootstrap` downloads the selected curl source into `third_party/`. That\ndirectory is a local build input, not a git-tracked source tree.\n\nTo override the native compiler:\n\n```bash\nCC=clang python scripts/tasks.py build-native\n```\n\nTo override the wasm compiler:\n\n```bash\nWASM_CC=\"zig cc\" python scripts/tasks.py build-wasm\n```\n\n### Nix\n\nThe flake pins nixpkgs and the upstream curl source used by `bootstrap`.\nIt wraps the same `scripts/tasks.py` build and test commands; non-Nix users do\nnot need a separate workflow or any flake-only feature.\n\n```bash\nnix develop\nnix build\nnix flake check\n```\n\n`nix build` compiles the native CLI, shared library, and wasm artifact.\n`nix flake check` runs lint, tests, and the wasm size budget.\n\n## Input\n\nOnly argv input is supported:\n\n```json\n{\n  \"inputMode\": \"argv\",\n  \"argv\": [\"curl\", \"--http3\", \"--json\", \"{\\\"a\\\":1}\", \"https://example.com\"]\n}\n```\n\nShell command strings are intentionally out of scope. Callers that accept a\ncommand line must split it into argv before calling the parser.\n\n## Wasm ABI\n\nThe wasm module exports a stable C ABI:\n\n```c\nuint32_t curlparse_abi_version(void);\nuint32_t curlparse_alloc(uint32_t size);\nvoid curlparse_free(uint32_t ptr, uint32_t size);\nint32_t curlparse_parse(uint32_t input_ptr, uint32_t input_len, uint32_t out_pair_ptr);\n```\n\nThe host writes UTF-8 JSON into wasm memory and receives an output\n`{ptr,len}` pair. curl parse failures are reported in output JSON, not as ABI\nreturn codes.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhellodword%2Fcurl-parser","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fhellodword%2Fcurl-parser","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhellodword%2Fcurl-parser/lists"}