oute-services-workspace-sdk
v0.0.27
Published
- Initialization
Downloads
10
Readme
This module expose helper functions
- Initialization
var params = {
url: @server url
token: @access token
}
var Workspace = require("oute-services-workspace-sdk")
var workspace_instance = new Workspace(params)
Cache functions
Core functions
- Invite members
body = {
"workspace_id": "ZzBfJMpfQ",
"notify": false,
"message": "Hi this is imp",
"invitees": [
{
"email_id": "[email protected]",
"role": "VIEWER" //posible values VIEWER, EDITOR, PERMANENT_DELETED
}
]
}
await workspace_instance.inviteMembers(body)
- Save workspace
body = {
"_id" : "ZzBfJMpfQ",
"name": "test",
"src": "test",
"is_discoverable": false,
"is_default": false
}
await workspace_instance.save(body)
- find one
query = {
"_id" : "ZzBfJMpfQ"
}
await workspace_instance.findOne(query)