Adds threads endpoint to API