Class: SMARTAppLaunch::MockSMARTServer::IntrospectionEndpoint

Inherits:
Inferno::DSL::SuiteEndpoint
  • Object
show all
Includes:
SMARTIntrospectionResponseCreation
Defined in:
lib/smart_app_launch/endpoints/mock_smart_server/introspection_endpoint.rb

Instance Method Summary collapse

Methods included from SMARTIntrospectionResponseCreation

#make_smart_introspection_response

Instance Method Details

#make_responseObject



15
16
17
18
19
20
21
22
# File 'lib/smart_app_launch/endpoints/mock_smart_server/introspection_endpoint.rb', line 15

def make_response
  response.body = make_smart_introspection_response.to_json
  response.headers['Cache-Control'] = 'no-store'
  response.headers['Pragma'] = 'no-cache'
  response.headers['Access-Control-Allow-Origin'] = '*'
  response.content_type = 'application/json'
  response.status = 200
end

#tagsObject



28
29
30
# File 'lib/smart_app_launch/endpoints/mock_smart_server/introspection_endpoint.rb', line 28

def tags
  [INTROSPECTION_TAG, SMART_TAG]
end

#test_run_identifierObject



11
12
13
# File 'lib/smart_app_launch/endpoints/mock_smart_server/introspection_endpoint.rb', line 11

def test_run_identifier
  MockSMARTServer.issued_token_to_client_id(request.params[:token])
end

#update_resultObject



24
25
26
# File 'lib/smart_app_launch/endpoints/mock_smart_server/introspection_endpoint.rb', line 24

def update_result
  nil # never update for now
end