feat: get, add, & delete user's inbox api tokens (#50)
* feat: get, add, & delete user's inbox api tokens * inbox: generate inbox api key on the server * inbox: use nanoid to generate api key && set created date on server * inbox: set api key in constructor && increase default expiry date to 1 year
This commit is contained in:
@@ -169,7 +169,8 @@ namespace Notesnook.API
|
||||
|
||||
services.AddRepository<UserSettings>("user_settings", "notesnook")
|
||||
.AddRepository<Monograph>("monographs", "notesnook")
|
||||
.AddRepository<Announcement>("announcements", "notesnook");
|
||||
.AddRepository<Announcement>("announcements", "notesnook")
|
||||
.AddRepository<InboxApiKey>(Collections.InboxApiKeysKey, "notesnook");
|
||||
|
||||
services.AddMongoCollection(Collections.SettingsKey)
|
||||
.AddMongoCollection(Collections.AttachmentsKey)
|
||||
@@ -182,7 +183,8 @@ namespace Notesnook.API
|
||||
.AddMongoCollection(Collections.ShortcutsKey)
|
||||
.AddMongoCollection(Collections.TagsKey)
|
||||
.AddMongoCollection(Collections.ColorsKey)
|
||||
.AddMongoCollection(Collections.VaultsKey);
|
||||
.AddMongoCollection(Collections.VaultsKey)
|
||||
.AddMongoCollection(Collections.InboxApiKeysKey);
|
||||
|
||||
services.AddScoped<ISyncItemsRepositoryAccessor, SyncItemsRepositoryAccessor>();
|
||||
services.AddScoped<IUserService, UserService>();
|
||||
|
||||
Reference in New Issue
Block a user