new GMEAuth(session, gmeConfig) → {Object}
Parameters:
Name | Type | Description |
---|---|---|
session |
||
gmeConfig |
- Source:
Returns:
- Type
- Object
Methods
(inner) addMongoOpsToPromize()
'_organizations' collection has these fields: _id: username projects: map from project name to object {read:, write:, delete: }
(inner) addOrganization(orgId, callbackopt) → {*}
Parameters:
Name | Type | Attributes | Description |
---|---|---|---|
orgId |
string | ||
callback |
function |
<optional> |
Returns:
- Type
- *
(inner) addUser(userId, email, password, canCreateopt, options, callbackopt) → {*}
Parameters:
Name | Type | Attributes | Default | Description |
---|---|---|---|---|
userId |
string | |||
email |
string | |||
password |
string | |||
canCreate |
boolean |
<optional> |
false | |
options |
object | |||
callback |
function |
<optional> |
Returns:
- Type
- *
(inner) addUserToOrganization(userId, orgId, callbackopt) → {*}
Parameters:
Name | Type | Attributes | Description |
---|---|---|---|
userId |
string | ||
orgId |
string | ||
callback |
function |
<optional> |
Returns:
- Type
- *
(inner) connect(callbackopt) → {*}
Parameters:
Name | Type | Attributes | Description |
---|---|---|---|
callback |
function |
<optional> |
Returns:
- Type
- *
(inner) deleteUser(userId, force, callbackopt) → {*}
Parameters:
Name | Type | Attributes | Description |
---|---|---|---|
userId |
string | ||
force |
boolean | removes the user from the db completely |
|
callback |
function |
<optional> |
Returns:
- Type
- *
(inner) getOrganization(orgId, queryopt, callbackopt) → {*}
Parameters:
Name | Type | Attributes | Description |
---|---|---|---|
orgId |
string | ||
query |
object |
<optional> |
|
callback |
function |
<optional> |
Returns:
- Type
- *
(inner) getUser(userId, queryopt, callbackopt) → {*}
Parameters:
Name | Type | Attributes | Description |
---|---|---|---|
userId |
string | ||
query |
object |
<optional> |
|
callback |
function |
<optional> |
Returns:
- Type
- *
(inner) listOrganizations(queryopt, callbackopt) → {*}
Parameters:
Name | Type | Attributes | Description |
---|---|---|---|
query |
object |
<optional> |
|
callback |
function |
<optional> |
Returns:
- Type
- *
(inner) listUsers(queryopt, projectionopt, callbackopt) → {*}
Parameters:
Name | Type | Attributes | Description |
---|---|---|---|
query |
object |
<optional> |
|
projection |
object |
<optional> |
|
callback |
function |
<optional> |
Returns:
- Type
- *
(inner) reEnableUser(userId, callbackopt) → {*}
Parameters:
Name | Type | Attributes | Description |
---|---|---|---|
userId |
string | ||
callback |
function |
<optional> |
Returns:
- Type
- *
(inner) removeOrganizationByOrgId(orgId, forceopt, callbackopt) → {*}
Parameters:
Name | Type | Attributes | Default | Description |
---|---|---|---|---|
orgId |
string | |||
force |
boolean |
<optional> |
false | delete organization from db. |
callback |
function |
<optional> |
Returns:
- Type
- *
(inner) removeUserFromOrganization(userId, orgId, callbackopt) → {*}
Parameters:
Name | Type | Attributes | Description |
---|---|---|---|
userId |
|||
orgId |
|||
callback |
function |
<optional> |
Returns:
- Type
- *
(inner) setAdminForUserInOrganization(userId, orgId, makeAdmin, callbackopt) → {*}
Parameters:
Name | Type | Attributes | Description |
---|---|---|---|
userId |
string | ||
orgId |
string | ||
makeAdmin |
boolean | ||
callback |
function |
<optional> |
Returns:
- Type
- *
(inner) unload(callbackopt) → {*}
Parameters:
Name | Type | Attributes | Description |
---|---|---|---|
callback |
function |
<optional> |
Returns:
- Type
- *
(inner) updateOrganizationInfo(orgId, info, callbackopt) → {*}
Parameters:
Name | Type | Attributes | Description |
---|---|---|---|
orgId |
string | ||
info |
object | ||
callback |
function |
<optional> |
Returns:
- Type
- *
(inner) updateUser(userId, userData, callbackopt) → {*}
Updates/overwrites provided fields for the userData.
Parameters:
Name | Type | Attributes | Description |
---|---|---|---|
userId |
string | ||
userData |
object | ||
callback |
function |
<optional> |
Returns:
- Type
- *
(inner) updateUserComponentSettings(userId, componentId, settings, overwriteopt, callbackopt) → {*}
Updates the provided fields in the settings stored at given componentId.
Parameters:
Name | Type | Attributes | Description |
---|---|---|---|
userId |
string | ||
componentId |
string | ||
settings |
object | ||
overwrite |
boolean |
<optional> |
if true the settings for the key will be overwritten. |
callback |
function |
<optional> |
Returns:
- Type
- *
(inner) updateUserDataField(userId, data, overwriteopt, callbackopt) → {*}
Updates the provided fields in data (recursively) within userData.data.
Parameters:
Name | Type | Attributes | Description |
---|---|---|---|
userId |
string | ||
data |
object | ||
overwrite |
boolean |
<optional> |
if true the settings for the key will be overwritten. |
callback |
function |
<optional> |
Returns:
- Type
- *
(inner) updateUserSettings(userId, settings, overwriteopt, callbackopt) → {*}
Updates the provided fields in the settings.
Parameters:
Name | Type | Attributes | Description |
---|---|---|---|
userId |
string | ||
settings |
object | ||
overwrite |
boolean |
<optional> |
if true the settings for the key will be overwritten. |
callback |
function |
<optional> |
Returns:
- Type
- *