Class: Nimbus::V4::ServicesController
- Inherits:
-
BaseController
- Object
- BaseController
- Nimbus::V4::ServicesController
- Defined in:
- app/controllers/mno_enterprise/nimbus/v4/services_controller.rb
Instance Method Summary collapse
-
#schema ⇒ Object
GET nimbus/v4/service/schema Return the API.
-
#status ⇒ Object
GET nimbus/v4/service/status Return service status.
Instance Method Details
#schema ⇒ Object
GET nimbus/v4/service/schema Return the API
7 8 9 10 11 |
# File 'app/controllers/mno_enterprise/nimbus/v4/services_controller.rb', line 7 def schema render 'schema_dev', formats: [:json] if Rails.env.test? || Rails.env.development? render 'schema_uat', formats: [:json] if Rails.env.uat? render 'schema', formats: [:json] if Rails.env.production? end |
#status ⇒ Object
GET nimbus/v4/service/status Return service status
15 16 17 18 |
# File 'app/controllers/mno_enterprise/nimbus/v4/services_controller.rb', line 15 def status @start_time = Time.now render json: {data: {available: true, response_time: ((Time.now - @start_time)*1000).round}} end |