Refactored api files
Added cypher endpoint