More importantly, APOC also contains a procedure to import data from JSON, which is not possible yet with vanilla Cypher. The structure of the query is as follows:
CALL apoc.load.json('http://...') AS value
UNWIND value.items AS item
CREATE (:Node {name: item.name}
As an example, we will import some data from GitHub using the GitHub API: https://developer.github.com/v3/.
We can get the list of repositories owned by the organization Neo4j with this request:
curl -u "<your_github_username>" https://api.github.com/orgs/neo4j/repos
Here is a sample of the data you can get for the given repository (with chosen fields):
{
"id": 34007506,
"node_id": "MDEwOlJlcG9zaXRvcnkzNDAwNzUwNg==",
"name": "neo4j-java-driver",
"full_name": "neo4j/neo4j-java-driver",
"private": false,
"owner": {
"login": "neo4j",
"id": 201120...