-
Notifications
You must be signed in to change notification settings - Fork 55
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
join or create message? #4
Comments
Idealy, we should perhaps just have one message: {
command: 'join',
documentId: '...',
createIfNotExists: true || false,
token: '...',
userId: '...'
} With a response: {
responseType: 'document',
error: "" || null,
version: 1,
document: {documentId: '...', content: '...'},
readOnly: true || false
} So you call with Otherwise clients have to know if they are allowed to join a document readonly or read/write... And this complicates things, especially since there aren't any formal error codes to rely on. We could add a property |
This seems reasonable. I'm marking this as a bug since confusing APIs aren't an intended feature! The internal workings of leaps have changed significantly since the client API was first slapped together so it might be worth completely reworking them, possibly with respect to some of the other issues you've raised (like user IDs vs auth tokens etc). |
This should probably be tackled after #8 is resolved. |
Looking at the clientside API, it's really hard to:
I propose we add a method to
join-or-create
a document with a given id.The text was updated successfully, but these errors were encountered: