<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title> Module: Auth0::Api::AuthenticationEndpoints — Documentation by YARD 0.8.7.6 </title> <link rel="stylesheet" href="../../css/style.css" type="text/css" charset="utf-8" /> <link rel="stylesheet" href="../../css/common.css" type="text/css" charset="utf-8" /> <script type="text/javascript" charset="utf-8"> hasFrames = window.top.frames.main ? true : false; relpath = '../../'; framesUrl = "../../frames.html#!Auth0/Api/AuthenticationEndpoints.html"; </script> <script type="text/javascript" charset="utf-8" src="../../js/jquery.js"></script> <script type="text/javascript" charset="utf-8" src="../../js/app.js"></script> </head> <body> <div id="header"> <div id="menu"> <a href="../../_index.html">Index (A)</a> » <span class='title'><span class='object_link'><a href="../../Auth0.html" title="Auth0 (module)">Auth0</a></span></span> » <span class='title'><span class='object_link'><a href="../Api.html" title="Auth0::Api (module)">Api</a></span></span> » <span class="title">AuthenticationEndpoints</span> <div class="noframes"><span class="title">(</span><a href="." target="_top">no frames</a><span class="title">)</span></div> </div> <div id="search"> <a class="full_list_link" id="class_list_link" href="../../class_list.html"> Class List </a> <a class="full_list_link" id="method_list_link" href="../../method_list.html"> Method List </a> <a class="full_list_link" id="file_list_link" href="../../file_list.html"> File List </a> </div> <div class="clear"></div> </div> <iframe id="search_frame"></iframe> <div id="content"><h1>Module: Auth0::Api::AuthenticationEndpoints </h1> <dl class="box"> <dt class="r1 last">Defined in:</dt> <dd class="r1 last">lib/auth0/api/authentication_endpoints.rb</dd> </dl> <div class="clear"></div> <h2>Overview</h2><div class="docstring"> <div class="discussion"> <p><a href="https://auth0.com/docs/auth-api" target="_parent" title="https://auth0.com/docs/auth-api">https://auth0.com/docs/auth-api</a> Describing functionality of auth0 authentication endpoints</p> </div> </div> <div class="tags"> </div> <h2> Instance Method Summary <small>(<a href="#" class="summary_toggle">collapse</a>)</small> </h2> <ul class="summary"> <li class="public "> <span class="summary_signature"> <a href="#change_password-instance_method" title="#change_password (instance method)">- (Object) <strong>change_password</strong>(email, password, connection_name = "Username-Password-Authentication") </a> </span> <span class="summary_desc"><div class='inline'> <p><a href="https://auth0.com/docs/auth-api#!#post–dbconnections-change_password" target="_parent" title="https://auth0.com/docs/auth-api#!#post–dbconnections-change_password">https://auth0.com/docs/auth-api#!#post–dbconnections-change_password</a>.</p> </div></span> </li> <li class="public "> <span class="summary_signature"> <a href="#delegation-instance_method" title="#delegation (instance method)">- (Object) <strong>delegation</strong>(id_token, target, scope = "open_id") </a> </span> <span class="summary_desc"><div class='inline'> <p><a href="https://auth0.com/docs/auth-api#!#post–delegation" target="_parent" title="https://auth0.com/docs/auth-api#!#post–delegation">https://auth0.com/docs/auth-api#!#post–delegation</a>.</p> </div></span> </li> <li class="public "> <span class="summary_signature"> <a href="#login-instance_method" title="#login (instance method)">- (Object) <strong>login</strong>(username, password, scope = "openid", id_token = nil, connection_name = "Username-Password-Authentication") </a> </span> <span class="summary_desc"><div class='inline'> <p><a href="https://auth0.com/docs/auth-api#!#post–oauth-ro" target="_parent" title="https://auth0.com/docs/auth-api#!#post–oauth-ro">https://auth0.com/docs/auth-api#!#post–oauth-ro</a>.</p> </div></span> </li> <li class="public "> <span class="summary_signature"> <a href="#obtain_access_token-instance_method" title="#obtain_access_token (instance method)">- (Object) <strong>obtain_access_token</strong> </a> </span> <span class="summary_desc"><div class='inline'> <p><a href="https://auth0.com/docs/auth-api#!#post–oauth-access_token" target="_parent" title="https://auth0.com/docs/auth-api#!#post–oauth-access_token">https://auth0.com/docs/auth-api#!#post–oauth-access_token</a>.</p> </div></span> </li> <li class="public "> <span class="summary_signature"> <a href="#signup-instance_method" title="#signup (instance method)">- (Object) <strong>signup</strong>(email, password, connection_name = "Username-Password-Authentication") </a> </span> <span class="summary_desc"><div class='inline'> <p><a href="https://auth0.com/docs/auth-api#!#post–dbconnections-signup" target="_parent" title="https://auth0.com/docs/auth-api#!#post–dbconnections-signup">https://auth0.com/docs/auth-api#!#post–dbconnections-signup</a>.</p> </div></span> </li> <li class="public "> <span class="summary_signature"> <a href="#token_info-instance_method" title="#token_info (instance method)">- (Object) <strong>token_info</strong>(id_token) </a> </span> <span class="summary_desc"><div class='inline'> <p><a href="https://auth0.com/docs/auth-api#!#post–tokeninfo" target="_parent" title="https://auth0.com/docs/auth-api#!#post–tokeninfo">https://auth0.com/docs/auth-api#!#post–tokeninfo</a>.</p> </div></span> </li> </ul> <div id="instance_method_details" class="method_details_list"> <h2>Instance Method Details</h2> <div class="method_details first"> <h3 class="signature first" id="change_password-instance_method"> - (<tt>Object</tt>) <strong>change_password</strong>(email, password, connection_name = "Username-Password-Authentication") </h3><div class="docstring"> <div class="discussion"> <p><a href="https://auth0.com/docs/auth-api#!#post–dbconnections-change_password" target="_parent" title="https://auth0.com/docs/auth-api#!#post–dbconnections-change_password">https://auth0.com/docs/auth-api#!#post–dbconnections-change_password</a></p> </div> </div> <div class="tags"> </div><table class="source_code"> <tr> <td> <pre class="lines"> 54 55 56 57 58 59 60 61 62</pre> </td> <td> <pre class="code"><span class="info file"># File 'lib/auth0/api/authentication_endpoints.rb', line 54</span> <span class='kw'>def</span> <span class='id identifier rubyid_change_password'>change_password</span><span class='lparen'>(</span><span class='id identifier rubyid_email'>email</span><span class='comma'>,</span> <span class='id identifier rubyid_password'>password</span><span class='comma'>,</span> <span class='id identifier rubyid_connection_name'>connection_name</span> <span class='op'>=</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>Username-Password-Authentication</span><span class='tstring_end'>"</span></span><span class='rparen'>)</span> <span class='id identifier rubyid_request_params'>request_params</span> <span class='op'>=</span> <span class='lbrace'>{</span> <span class='label'>client_id:</span> <span class='ivar'>@client_id</span><span class='comma'>,</span> <span class='label'>email:</span> <span class='id identifier rubyid_email'>email</span><span class='comma'>,</span> <span class='label'>connection:</span> <span class='id identifier rubyid_connection_name'>connection_name</span><span class='comma'>,</span> <span class='label'>password:</span> <span class='id identifier rubyid_password'>password</span> <span class='rbrace'>}</span> <span class='id identifier rubyid_post'>post</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>/dbconnections/change_password</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='id identifier rubyid_request_params'>request_params</span><span class='rparen'>)</span> <span class='kw'>end</span></pre> </td> </tr> </table> </div> <div class="method_details "> <h3 class="signature " id="delegation-instance_method"> - (<tt>Object</tt>) <strong>delegation</strong>(id_token, target, scope = "open_id") </h3><div class="docstring"> <div class="discussion"> <p><a href="https://auth0.com/docs/auth-api#!#post–delegation" target="_parent" title="https://auth0.com/docs/auth-api#!#post–delegation">https://auth0.com/docs/auth-api#!#post–delegation</a></p> </div> </div> <div class="tags"> </div><table class="source_code"> <tr> <td> <pre class="lines"> 17 18 19 20 21 22 23 24 25 26</pre> </td> <td> <pre class="code"><span class="info file"># File 'lib/auth0/api/authentication_endpoints.rb', line 17</span> <span class='kw'>def</span> <span class='id identifier rubyid_delegation'>delegation</span><span class='lparen'>(</span><span class='id identifier rubyid_id_token'>id_token</span><span class='comma'>,</span> <span class='id identifier rubyid_target'>target</span><span class='comma'>,</span> <span class='id identifier rubyid_scope'>scope</span> <span class='op'>=</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>open_id</span><span class='tstring_end'>"</span></span><span class='rparen'>)</span> <span class='id identifier rubyid_request_params'>request_params</span> <span class='op'>=</span> <span class='lbrace'>{</span> <span class='label'>client_id:</span> <span class='ivar'>@client_id</span><span class='comma'>,</span> <span class='label'>grant_type:</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>urn:ietf:params:oauth:grant-type:jwt-bearer</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='label'>id_token:</span> <span class='id identifier rubyid_id_token'>id_token</span><span class='comma'>,</span> <span class='label'>target:</span> <span class='id identifier rubyid_target'>target</span><span class='comma'>,</span> <span class='label'>scope:</span> <span class='id identifier rubyid_scope'>scope</span> <span class='rbrace'>}</span> <span class='id identifier rubyid_post'>post</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>/delegation</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='id identifier rubyid_request_params'>request_params</span><span class='rparen'>)</span> <span class='kw'>end</span></pre> </td> </tr> </table> </div> <div class="method_details "> <h3 class="signature " id="login-instance_method"> - (<tt>Object</tt>) <strong>login</strong>(username, password, scope = "openid", id_token = nil, connection_name = "Username-Password-Authentication") </h3><div class="docstring"> <div class="discussion"> <p><a href="https://auth0.com/docs/auth-api#!#post–oauth-ro" target="_parent" title="https://auth0.com/docs/auth-api#!#post–oauth-ro">https://auth0.com/docs/auth-api#!#post–oauth-ro</a></p> </div> </div> <div class="tags"> </div><table class="source_code"> <tr> <td> <pre class="lines"> 29 30 31 32 33 34 35 36 37 38 39 40</pre> </td> <td> <pre class="code"><span class="info file"># File 'lib/auth0/api/authentication_endpoints.rb', line 29</span> <span class='kw'>def</span> <span class='id identifier rubyid_login'>login</span><span class='lparen'>(</span><span class='id identifier rubyid_username'>username</span><span class='comma'>,</span> <span class='id identifier rubyid_password'>password</span><span class='comma'>,</span> <span class='id identifier rubyid_scope'>scope</span> <span class='op'>=</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>openid</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='id identifier rubyid_id_token'>id_token</span><span class='op'>=</span><span class='kw'>nil</span><span class='comma'>,</span> <span class='id identifier rubyid_connection_name'>connection_name</span><span class='op'>=</span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>Username-Password-Authentication</span><span class='tstring_end'>"</span></span><span class='rparen'>)</span> <span class='id identifier rubyid_request_params'>request_params</span> <span class='op'>=</span> <span class='lbrace'>{</span> <span class='label'>client_id:</span> <span class='ivar'>@client_id</span><span class='comma'>,</span> <span class='label'>username:</span> <span class='id identifier rubyid_username'>username</span><span class='comma'>,</span> <span class='label'>password:</span> <span class='id identifier rubyid_password'>password</span><span class='comma'>,</span> <span class='label'>scope:</span> <span class='id identifier rubyid_scope'>scope</span><span class='comma'>,</span> <span class='label'>connection:</span> <span class='id identifier rubyid_connection_name'>connection_name</span><span class='comma'>,</span> <span class='label'>grand_type:</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>password</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='label'>id_token:</span> <span class='id identifier rubyid_id_token'>id_token</span> <span class='rbrace'>}</span> <span class='id identifier rubyid_post'>post</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>/oauth/ro</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='id identifier rubyid_request_params'>request_params</span><span class='rparen'>)</span> <span class='kw'>end</span></pre> </td> </tr> </table> </div> <div class="method_details "> <h3 class="signature " id="obtain_access_token-instance_method"> - (<tt>Object</tt>) <strong>obtain_access_token</strong> </h3><div class="docstring"> <div class="discussion"> <p><a href="https://auth0.com/docs/auth-api#!#post–oauth-access_token" target="_parent" title="https://auth0.com/docs/auth-api#!#post–oauth-access_token">https://auth0.com/docs/auth-api#!#post–oauth-access_token</a></p> </div> </div> <div class="tags"> </div><table class="source_code"> <tr> <td> <pre class="lines"> 7 8 9 10 11 12 13 14</pre> </td> <td> <pre class="code"><span class="info file"># File 'lib/auth0/api/authentication_endpoints.rb', line 7</span> <span class='kw'>def</span> <span class='id identifier rubyid_obtain_access_token'>obtain_access_token</span> <span class='id identifier rubyid_request_params'>request_params</span> <span class='op'>=</span> <span class='lbrace'>{</span> <span class='label'>client_id:</span> <span class='ivar'>@client_id</span><span class='comma'>,</span> <span class='label'>client_secret:</span> <span class='ivar'>@client_secret</span><span class='comma'>,</span> <span class='label'>grant_type:</span> <span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>client_credentials</span><span class='tstring_end'>'</span></span> <span class='rbrace'>}</span> <span class='id identifier rubyid_post'>post</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>/oauth/token</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='id identifier rubyid_request_params'>request_params</span><span class='rparen'>)</span><span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>access_token</span><span class='tstring_end'>"</span></span><span class='rbracket'>]</span> <span class='kw'>end</span></pre> </td> </tr> </table> </div> <div class="method_details "> <h3 class="signature " id="signup-instance_method"> - (<tt>Object</tt>) <strong>signup</strong>(email, password, connection_name = "Username-Password-Authentication") </h3><div class="docstring"> <div class="discussion"> <p><a href="https://auth0.com/docs/auth-api#!#post–dbconnections-signup" target="_parent" title="https://auth0.com/docs/auth-api#!#post–dbconnections-signup">https://auth0.com/docs/auth-api#!#post–dbconnections-signup</a></p> </div> </div> <div class="tags"> </div><table class="source_code"> <tr> <td> <pre class="lines"> 43 44 45 46 47 48 49 50 51</pre> </td> <td> <pre class="code"><span class="info file"># File 'lib/auth0/api/authentication_endpoints.rb', line 43</span> <span class='kw'>def</span> <span class='id identifier rubyid_signup'>signup</span><span class='lparen'>(</span><span class='id identifier rubyid_email'>email</span><span class='comma'>,</span> <span class='id identifier rubyid_password'>password</span><span class='comma'>,</span> <span class='id identifier rubyid_connection_name'>connection_name</span><span class='op'>=</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>Username-Password-Authentication</span><span class='tstring_end'>"</span></span><span class='rparen'>)</span> <span class='id identifier rubyid_request_params'>request_params</span> <span class='op'>=</span> <span class='lbrace'>{</span> <span class='label'>client_id:</span> <span class='ivar'>@client_id</span><span class='comma'>,</span> <span class='label'>email:</span> <span class='id identifier rubyid_email'>email</span><span class='comma'>,</span> <span class='label'>connection:</span> <span class='id identifier rubyid_connection_name'>connection_name</span><span class='comma'>,</span> <span class='label'>password:</span> <span class='id identifier rubyid_password'>password</span> <span class='rbrace'>}</span> <span class='id identifier rubyid_post'>post</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>/dbconnections/signup</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='id identifier rubyid_request_params'>request_params</span><span class='rparen'>)</span> <span class='kw'>end</span></pre> </td> </tr> </table> </div> <div class="method_details "> <h3 class="signature " id="token_info-instance_method"> - (<tt>Object</tt>) <strong>token_info</strong>(id_token) </h3><div class="docstring"> <div class="discussion"> <p><a href="https://auth0.com/docs/auth-api#!#post–tokeninfo" target="_parent" title="https://auth0.com/docs/auth-api#!#post–tokeninfo">https://auth0.com/docs/auth-api#!#post–tokeninfo</a></p> </div> </div> <div class="tags"> </div><table class="source_code"> <tr> <td> <pre class="lines"> 65 66 67 68</pre> </td> <td> <pre class="code"><span class="info file"># File 'lib/auth0/api/authentication_endpoints.rb', line 65</span> <span class='kw'>def</span> <span class='id identifier rubyid_token_info'>token_info</span><span class='lparen'>(</span><span class='id identifier rubyid_id_token'>id_token</span><span class='rparen'>)</span> <span class='id identifier rubyid_request_params'>request_params</span> <span class='op'>=</span> <span class='lbrace'>{</span> <span class='label'>id_token:</span> <span class='id identifier rubyid_id_token'>id_token</span><span class='rbrace'>}</span> <span class='id identifier rubyid_post'>post</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>/tokeninfo</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='id identifier rubyid_request_params'>request_params</span><span class='rparen'>)</span> <span class='kw'>end</span></pre> </td> </tr> </table> </div> </div> </div> <div id="footer"> Generated on Mon Feb 23 01:12:53 2015 by <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a> 0.8.7.6 (ruby-2.0.0). </div> </body> </html>