Documentation
Bolt Protocol
Connection — Bolt Protocol
JetGraph speaks the Bolt binary protocol on port 7687, the same protocol used by Neo4j. Compatible Neo4j drivers can connect on port 7687 and run the supported openCypher subset. Unsupported Cypher and Neo4j-only procedures will not run.
What is Bolt?
Bolt is a binary, connection-oriented protocol optimized for graph databases. It supports efficient serialisation of Cypher queries and results, pipelining, and authentication. Because JetGraph speaks Bolt, you can use drivers for Python, JavaScript, Java, Go, .NET, and more for the supported subset.
Connection Details
| Parameter | Value (demo mode) |
|---|---|
| URL | bolt://localhost:7687 |
| Username | "" (empty) |
| Password | "" (empty) |
Python Example
python
from neo4j import GraphDatabase
driver = GraphDatabase.driver("bolt://localhost:7687", auth=("", ""))
with driver.session() as session:
# Create a node
session.run(
"CREATE (u:USER {external_id: $id})",
id="user-bolt-001"
)
# Query nodes
result = session.run("MATCH (u:USER) RETURN u.external_id AS id LIMIT 5")
for record in result:
print(record["id"])
driver.close()
JavaScript (Node.js) Example
javascript
const neo4j = require('neo4j-driver');
const driver = neo4j.driver(
'bolt://localhost:7687',
neo4j.auth.basic('', '')
);
const session = driver.session();
const result = await session.run(
'MATCH (u:USER) RETURN u.external_id AS id LIMIT 10'
);
result.records.forEach(r => console.log(r.get('id')));
await session.close();
await driver.close();