{"id":28384927,"url":"https://github.com/foufoujoujou/jeeson","last_synced_at":"2026-05-18T14:02:54.799Z","repository":{"id":240110114,"uuid":"785163006","full_name":"FouFouJouJou/jeeson","owner":"FouFouJouJou","description":"Json parsing library","archived":false,"fork":false,"pushed_at":"2025-06-20T12:14:07.000Z","size":81,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-06-20T12:19:59.183Z","etag":null,"topics":["json","jsonparser","parser"],"latest_commit_sha":null,"homepage":"","language":"C","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/FouFouJouJou.png","metadata":{"files":{"readme":"README.org","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}},"created_at":"2024-04-11T10:22:01.000Z","updated_at":"2025-06-20T12:14:11.000Z","dependencies_parsed_at":"2024-05-16T19:56:37.961Z","dependency_job_id":"0355c600-e1b5-49fd-96c8-8f5bdcb8afbf","html_url":"https://github.com/FouFouJouJou/jeeson","commit_stats":null,"previous_names":["foufoujoujou/json-parser","foufoujoujou/jeeson"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/FouFouJouJou/jeeson","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/FouFouJouJou%2Fjeeson","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/FouFouJouJou%2Fjeeson/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/FouFouJouJou%2Fjeeson/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/FouFouJouJou%2Fjeeson/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/FouFouJouJou","download_url":"https://codeload.github.com/FouFouJouJou/jeeson/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/FouFouJouJou%2Fjeeson/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32312235,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-26T19:15:34.056Z","status":"ssl_error","status_checked_at":"2026-04-26T19:15:15.467Z","response_time":129,"last_error":"SSL_read: 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","jsonparser","parser"],"created_at":"2025-05-30T09:40:24.340Z","updated_at":"2026-04-26T20:31:58.117Z","avatar_url":"https://github.com/FouFouJouJou.png","language":"C","funding_links":[],"categories":[],"sub_categories":[],"readme":"* Jeeson\nA json parsing library. Nothing special really. Got a json file you want to use in your program\nand your program is written in C? Well then give this one a go.\n\n* Resource\nThe [[https://www.json.org/][json specification]] was the only needed resource to get an implementation up and running.\nIt is short and concise, having excellent graph visualization to fully grasp the format.\nEasily a 10/10 as far as format grammar documentation goes.\n\n* Instructions\nBuilding the project requires [[https://command-not-found.com/cmake][cmake]]. It is desirable to create a build directory to have a cleaner file tree.\nMy personal choice is almost always =bin=.\n#+begin_src shell\n  mkdir bin\n  cd bin\n  cmake ..\n  make\n#+end_src\n\n* Parser features [6/8]\n- [X] objects\n- [X] arrays\n- [X] string\n- [X] number\n- [X] array\n- [X] boolean\n- [ ] escape characters and unicode\n- [ ] null\n\n* Documentation\n- To load a json file into your program and then print it.\n#+begin_src c\n  struct json_object_t *object=json_to_object(path_to_json);\n  printf_object(*object, 0);\n#+end_src\n\n- To check if a json object contains a key. the =has_key= function returns the index of the key that can then be used to index into the internal key structure.\n#+begin_src c\n  struct json_object_t *object=json_to_object(path_to_json);\n  char *key_to_look_for = \"your\";\n  ssize_t idx = has_key(object, key_to_look_for);\n  if (idx == -1) {\n    printf(\"(◞‸◟)\\n\");\n  }else {\n    printf(\"( ˶ˆᗜˆ˵ )\\n\");\n  }\n#+end_src\n\n- In order to get the value associate with a key in an object, one needs to know in advance what the type of the value is.\n#+begin_src c\n  struct json_object_t *object=json_to_object(path_to_json);\n  char *key = \"your\";\n\n  // fetching string\n  char *mama = get_string(object, key);\n\n  // fetching number\n  double weight = get_number(object, key);\n\n  // fetching array element\n  struct json_array_t *mamas = get_array(object, key);\n  printf_array(*array, 0);\n\n  // fetching object element\n  struct json_object_t *obj = get_object(object, key);\n  printf_object(*obj, 0);\n#+end_src\n\n- Indexing values inside array values is similar to fetching values associated with keys in an object, any time you want to get a value from JSON you have to know in advance what the type of that data is to use the corresponding function.\n#+begin_src c\n  struct json_object_t *object=json_to_object(path_to_json);\n  char *key = \"your\";\n\n  struct json_array_t *mamas = get_array(object, key);\n  printf_array(*array, 0);\n\n  size_t name_idx = 0;\n  size_t weight_idx = 1;\n  size_t kids_idx = 2;\n\n  // fetching string element\n  char *name = get_array_string_element(mamas, name_idx);\n\n  // fetching an infinitely big number element\n  long double weight = get_array_number_element(mamas, weight_idx);\n\n  // fetching object element\n  struct json_object_t *kids = get_array_object_element(mamas, kids_idx);\n#+end_src\n\n- Any memory, inevitably, must be freed.\n#+begin_src c\n  struct json_object_t *object=json_to_object(path_to_json);\n  // ...\n  free_json_object(object);\n#+end_src\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffoufoujoujou%2Fjeeson","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ffoufoujoujou%2Fjeeson","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffoufoujoujou%2Fjeeson/lists"}