{"id":20492488,"url":"https://github.com/mumez/scypher","last_synced_at":"2025-07-23T11:33:18.706Z","repository":{"id":40303291,"uuid":"265853041","full_name":"mumez/SCypher","owner":"mumez","description":"An extensible, dynamic Cypher query builder. Usable with Neo4reSt and SmallBolt.","archived":false,"fork":false,"pushed_at":"2023-02-16T08:56:20.000Z","size":168,"stargazers_count":2,"open_issues_count":0,"forks_count":3,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-04-07T03:42:38.926Z","etag":null,"topics":["cypher","neo4j","pharo"],"latest_commit_sha":null,"homepage":"","language":"Smalltalk","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/mumez.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":"2020-05-21T13:16:43.000Z","updated_at":"2021-11-10T00:40:55.000Z","dependencies_parsed_at":"2024-11-15T17:33:27.854Z","dependency_job_id":"912c186d-b8d0-4948-b079-dffd37afe816","html_url":"https://github.com/mumez/SCypher","commit_stats":null,"previous_names":[],"tags_count":7,"template":false,"template_full_name":null,"purl":"pkg:github/mumez/SCypher","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mumez%2FSCypher","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mumez%2FSCypher/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mumez%2FSCypher/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mumez%2FSCypher/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/mumez","download_url":"https://codeload.github.com/mumez/SCypher/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mumez%2FSCypher/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":266669225,"owners_count":23965704,"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-07-23T02:00:09.312Z","response_time":66,"last_error":null,"robots_txt_status":null,"robots_txt_updated_at":null,"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":["cypher","neo4j","pharo"],"created_at":"2024-11-15T17:29:21.465Z","updated_at":"2025-07-23T11:33:18.669Z","avatar_url":"https://github.com/mumez.png","language":"Smalltalk","funding_links":[],"categories":[],"sub_categories":[],"readme":"# SCypher\n\nAn extensible, dynamic Cypher query builder. Usable with [Neo4reSt](https://github.com/mumez/Neo4reSt) and [SCypherGraph](https://github.com/mumez/SCypherGraph).\n\n## Installation\n\n```smalltalk\nMetacello new\n  baseline: 'SCypher';\n  repository: 'github://mumez/SCypher/repository';\n  load.\n```\n\n## Examples\n\n### 1: Basic MATCH query\n\n```smalltalk\nnode := CyNode name: 'n' label: 'Movie' props: {'released'-\u003e2000}.\nquery := (CyQuery match: node) return: (node @ #title), (node @ #summary) in: [ :ret |\n  ret orderBy: (node @ #released); skip: 2; limit: 10 \n].\nquery cypherString. \"print it\"\n```\n\n=\u003e\n\n```cypher\nMATCH (n:Movie {released:2000})\nRETURN n.title, n.summary ORDER BY n.released SKIP 2 LIMIT 10 \n```\n\n### 2 MATCH using WITH\n\n```smalltalk\nuser := 'user' asCypherIdentifier.\nfriend := 'friend' asCypherIdentifier.\nfriends := 'friends' asCypherIdentifier.\nquery := (CyQuery match: ((user asNode -- friend asNode) type: 'FRIEND')).\nquery where: (user @ #name = 'name' asCypherParameter);\n with: (user, (friend count as: friends));\n where: (friends \u003e 10);\n return: user.\nquery cypherString.\n```\n\n=\u003e\n\n```cypher\nMATCH (user)-[:FRIEND]-(friend)\nWHERE (user.name = $name)\nWITH user, count(friend) AS friends \nWHERE (friends \u003e 10)\nRETURN user \n```\n\n### 3: MATCH using RELATIONSHIPS\n\n```smalltalk\nmovie := 'm' asCypherIdentifier.\nperson1 := 'p' asCypherIdentifier.\nperson2 := 'p2' asCypherIdentifier.\nmovieNode := CyNode name: movie label: 'Movie' props: {'released'-\u003e2000}.\nperson1Node := CyNode name: person1 label: 'Person'.\nperson2Node := CyNode name: person2 label: 'Person'.\npath := person1Node - ('acted_in' asCypherIdentifier rel: 'ACTED_IN') -\u003e movieNode \u003c- ('acted_in2' asCypherIdentifier rel: 'ACTED_IN') - person2Node.\nquery := (CyQuery match: path) return: movie, person1, person2 in: [ :ret |\n ret orderBy: (movie @ #name), (person1 @ #name) desc, (person2 @ #name) desc; limit: 10 \n].\nquery cypherString.\n```\n\n=\u003e\n\n```cypher\nMATCH (p:Person)-[`acted_in`:ACTED_IN]-\u003e(m:Movie\n{released:2000})\u003c-[`acted_in2`:ACTED_IN]-(p2:Person)\nRETURN m, p, p2 ORDER BY m.name, p.name DESC, p2.name DESC LIMIT 10 \n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmumez%2Fscypher","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmumez%2Fscypher","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmumez%2Fscypher/lists"}