{"id":15010342,"url":"https://github.com/just-sultanov/elastiq","last_synced_at":"2026-02-01T04:32:50.186Z","repository":{"id":228082566,"uuid":"773094216","full_name":"just-sultanov/elastiq","owner":"just-sultanov","description":"An experimental library for building queries to the Elastic (OpenSearch) Search API","archived":false,"fork":false,"pushed_at":"2024-03-19T20:40:54.000Z","size":19,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-06-10T22:39:24.166Z","etag":null,"topics":["clojure","elasticsearch","opensearch","query-builder"],"latest_commit_sha":null,"homepage":"","language":"Clojure","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/just-sultanov.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":"2024-03-16T18:20:21.000Z","updated_at":"2024-03-16T23:16:40.000Z","dependencies_parsed_at":"2024-10-12T10:20:32.479Z","dependency_job_id":null,"html_url":"https://github.com/just-sultanov/elastiq","commit_stats":null,"previous_names":["just-sultanov/elastiq"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/just-sultanov/elastiq","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/just-sultanov%2Felastiq","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/just-sultanov%2Felastiq/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/just-sultanov%2Felastiq/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/just-sultanov%2Felastiq/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/just-sultanov","download_url":"https://codeload.github.com/just-sultanov/elastiq/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/just-sultanov%2Felastiq/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28967949,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-02-01T03:46:10.227Z","status":"ssl_error","status_checked_at":"2026-02-01T03:46:01.693Z","response_time":56,"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":["clojure","elasticsearch","opensearch","query-builder"],"created_at":"2024-09-24T19:33:39.209Z","updated_at":"2026-02-01T04:32:50.168Z","avatar_url":"https://github.com/just-sultanov.png","language":"Clojure","funding_links":[],"categories":[],"sub_categories":[],"readme":"# elastiq\n\nAn experimental library for building queries to the Elastic (OpenSearch) Search\nAPI.\n\n## How it works\n\n- Provide mappings of your `index`\n- Automatically create a `malli` schema using mappings of your `index`\n- Validate a user request\n- Transform a user request into a request to the Elastic (OpenSearch) Search API\n  using the `malli` scheme created above\n\n**User request**\n\n```jsonc\n{\n  \"from\": 0,\n  \"size\": 100,\n  \"query\": {\n    \"article\": { \"content\": \"clojure\" }, // `content` contains \"clojure\"\n    \"tags\": [\"clojure\", \"clojurescript\"], // `tag` is equal to \"clojure\" or \"clojurescript\"\n    \"author\": \"*\", // `author` is not `empty` or `null`\n    \"public\": true, // only `public` articles\n    \"published_at\": { \"from\": \"2024-01-01\", \"to\": \"now\" } // articles for the specified period\n  }\n}\n```\n\n**Generated query to the Elastic (OpenSearch) Search API**\n\n```clojure\n{:from 0,\n :size 100,\n :query {:bool \n          {:must [{:nested {:path :article\n                            :query {:bool {:must [{:match {:article.content \"clojure\"}}]}}}}\n                  {:bool {:minimum_should_match 1\n                          :should [{:match {:tags {:query \"clojure\"}}}\n                                   {:match {:tags {:query \"clojurescript\"}}}]}}\n                  {:exists {:field :author}}\n                  {:term {:public true}}\n                  {:range {:published_at {:gte \"2024-01-01\", :lte \"now\"}}}]}}}\n```\n\n**Mappings**\n\n```json\n{\n  \"posts\": {\n    \"mappings\": {\n      \"doc\": {\n        \"_meta\": {\n          \"applicationVersion\": \"14.15\"\n        },\n        \"properties\": {\n          \"article\": {\n            \"type\": \"nested\",\n            \"properties\": {\n              \"title\": {\n                \"type\": \"keyword\"\n              },\n              \"content\": {\n                \"type\": \"text\",\n                \"analyzer\": \"some_text_analyzer\"\n              }\n            }\n          },\n          \"tags\": {\n            \"type\": \"keyword\"\n          },\n          \"author\": {\n            \"type\": \"keyword\"\n          },\n          \"public\": {\n            \"type\": \"boolean\"\n          },\n          \"published_at\": {\n            \"type\": \"date\"\n          }\n        }\n      }\n    }\n  }\n}\n```\n\n## License\n\n[Copyright © 2024 Ilshat Sultanov](./license)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjust-sultanov%2Felastiq","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjust-sultanov%2Felastiq","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjust-sultanov%2Felastiq/lists"}