Chapter 21. REST API
Table of Contents
- 21.1. Transactional Cypher HTTP endpoint
- 21.2. Neo4j Status Codes
- 21.3. Authentication and Authorization
- 21.4. Service root
- 21.5. Streaming
- 21.6. Legacy Cypher HTTP endpoint
- 21.7. Property values
- 21.8. Nodes
- 21.9. Relationships
- 21.10. Relationship types
- 21.11. Node properties
- 21.12. Relationship properties
- 21.13. Node labels
- 21.14. Node degree
- 21.15. Indexing
- 21.16. Constraints
- 21.17. Traversals
- 21.18. Graph Algorithms
- 21.19. Batch operations
- 21.20. Legacy indexing
- 21.21. Unique Indexing
- 21.22. Legacy Automatic Indexes
- 21.23. Configurable Legacy Automatic Indexing
- 21.24. WADL Support
- 21.25. Using the REST API from WebLogic
The Neo4j REST API is designed with discoverability in mind, so that you can start with a
GET on the Section 21.4, “Service root” and from there discover URIs to perform other requests.
The examples below uses URIs in the examples; they are subject to change in the future, so for future-proofness discover URIs where possible, instead of relying on the current layout.
The default representation is json, both for responses and for data sent with
Below follows a listing of ways to interact with the REST API. For language bindings to the REST API, see Chapter 6, Languages.
To interact with the JSON interface you must explicitly set the request header
Accept:application/json for those requests that responds with data.
You should also set the header
Content-Type:application/json if your request sends data, for example when you’re creating a relationship.
The examples include the relevant request and response headers.
The server supports streaming results, with better performance and lower memory overhead. See Section 21.5, “Streaming” for more information.