FxaRelierClient (start here) Class
The entry point. Create and use an instance of the FxaRelierClient.
Constructor
FxaRelierClient (start here)
                                
                                        
                                            (
                                
                                
                                
                                
                                
                                
                                
                                
                                    
                                
                                    - 
                                                        clientId
- 
                                                        [options={}]
Parameters:
- 
                                                        clientIdString- the OAuth client ID for the relier
 
- 
                                                        [options={}]Object optional- configuration
 - 
                                                                    [clientSecret]String optionalClient secret. Required to use the Token API. 
- 
                                                                    [contentHost]String optionalFirefox Accounts Content Server host 
- 
                                                                    [oauthHost]String optionalFirefox Accounts OAuth Server host 
- 
                                                                    [profileHost]String optionalFirefox Accounts Profile Server host 
- 
                                                                    [window]Object optionalwindow override, used for unit tests 
- 
                                                                    [lightbox]Object optionallightbox override, used for unit tests 
- 
                                                                    [channel]Object optionalchannel override, used for unit tests 
 
Example:
var fxaRelierClient = new FxaRelierClient(<client_id>);
                                Properties
auth
                                                Object
                                            
                                            
                                            
                                            
                                            
                                                
                                            
                                                Authenticate users in the browser. Implements AuthAPI.
Example:
var fxaRelierClient = new FxaRelierClient('<client_id>');
                                            fxaRelierClient.auth.signIn({
                                              state: <state>,
                                              redirectUri: <redirect_uri>,
                                              scope: 'profile'
                                            });
                                            profile
                                                Object
                                            
                                            
                                            
                                            
                                            
                                                
                                            
                                                Fetch profile information on the server. Implements ProfileAPI.
Example:
var fxaRelierClient = new FxaRelierClient('<client_id>', {
                                              clientSecret: <client_secret>
                                            });
                                            fxaRelierClient.token.tradeCode(<code>)
                                              .then(function (token) {
                                                return fxaRelierClient.fetch(token);
                                              })
                                              .then(function (profile) {
                                                // display some profile info.
                                              });
                                            token
                                                Object
                                            
                                            
                                            
                                            
                                            
                                                
                                            
                                                Manage tokens on the server. Implements TokenAPI.
Example:
var fxaRelierClient = new FxaRelierClient('<client_id>', {
                                              clientSecret: <client_secret>
                                            });
                                            fxaRelierClient.token.tradeCode(<code>)
                                              .then(function (token) {
                                                // do something awesome with the token like get
                                                // profile information. See profile.
                                              });
                                            version
                                                String
                                            
                                            
                                            
                                            
                                            
                                                
                                            
                                                FxaRelierClient version
