6.3.2 • Published 2 years ago

bedrock-account v6.3.2

Weekly downloads
266
License
SEE LICENSE IN LI...
Repository
github
Last release
2 years ago

bedrock-account

User accounts for Bedrock Applications

API Reference

bedrock-account

bedrock-account.insert(options) ⇒ Promise

Inserts a new account. The account must contain id.

Kind: static method of bedrock-account
Returns: Promise - Resolves to the database account record.

ParamTypeDescription
optionsobjectThe options to use.
options.accountobjectThe account containing at least the minimum required data.
options.metaobjectThe meta information to include.

bedrock-account.exists(options) ⇒ Promise

Check for the existence of an account.

Kind: static method of bedrock-account
Returns: Promise - Resolves to a boolean indicating account existence.

ParamTypeDefaultDescription
optionsobjectThe options to use.
options.idstringThe ID of the account to check.
options.emailstringThe email address for the account.
options.statusstring"active"The status to check for (options: 'active', deleted').

bedrock-account.get(options) ⇒ Promise

Retrieves an account.

Kind: static method of bedrock-account
Returns: Promise - Resolves to {account, meta}.

ParamTypeDescription
optionsobjectThe options to use.
options.idstringThe ID of the account to retrieve.

bedrock-account.getAll(options) ⇒ Promise

Retrieves all accounts matching the given query.

Kind: static method of bedrock-account
Returns: Promise - Resolves to the records that matched the query.

ParamTypeDefaultDescription
optionsobjectThe options to use.
options.queryobject{}The query to use.
options.optionsobject{}The options (eg: 'sort', 'limit').

bedrock-account.update(options) ⇒ Promise

Updates an account.

Kind: static method of bedrock-account
Returns: Promise - Resolves once the operation completes.

ParamTypeDescription
optionsobjectThe options to use.
options.idstringThe ID of the account to update.
options.patchArrayA JSON patch for performing the update.
options.sequencenumberThe sequence number that must match the current record prior to the patch.

bedrock-account.setStatus(options) ⇒ Promise

Sets an account's status.

Kind: static method of bedrock-account
Returns: Promise - Resolves once the operation completes.

ParamTypeDescription
optionsobjectThe options to use.
options.idstringThe account ID.
options.statusstringThe status.
6.1.0

2 years ago

6.0.0

2 years ago

6.3.0

2 years ago

6.2.0

2 years ago

6.3.2

2 years ago

6.3.1

2 years ago

5.0.0

3 years ago

4.2.0

4 years ago

4.1.0

4 years ago

4.0.0

4 years ago

3.0.1

4 years ago

3.0.0

4 years ago

2.2.0

4 years ago

2.1.3

4 years ago

2.1.2

5 years ago

2.1.1

5 years ago

2.1.0

5 years ago

2.0.0

6 years ago

1.0.0

6 years ago

0.1.0

6 years ago