Omniauth_step_by_step is a project mainly written in RUBY and JAVASCRIPT, it's free.
Example of building up authentication with omniauth around a simple rails app
404: Not Found