Sha256: 98383d522f890f18fbf5b4e2b73e30a1a847701f45216e84c93975dee73497e1
Contents?: true
Size: 605 Bytes
Versions: 1
Compression:
Stored size: 605 Bytes
Contents
$:.push File.dirname(__FILE__) + '/../lib' require 'omniauth-office365' require 'sinatra' require 'json' set :port, 4200 office365_client_id = ENV['OFFICE365_CLIENT_ID'] office365_client_secret = ENV['OFFICE365_CLIENT_SECRET'] use Rack::Session::Cookie use OmniAuth::Builder do provider :office365, office365_client_id, office365_client_secret end get '/' do "<a href='/auth/office365'>Log in with Office365</a>" end get '/auth/office365/callback' do content_type 'text/plain' request.env['omniauth.auth'].to_json end get '/auth/failure' do content_type 'text/plain' params.to_json end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
omniauth-office365-0.0.1 | example/example.rb |