Authentication Engine for Rails.API based multitenant RESTful APIs