Labs/Bespin/ServerAPI: Difference between revisions

Jump to navigation Jump to search
Line 28: Line 28:
* DELETE /file/[path] to delete a file. file must not be open by anyone.  
* DELETE /file/[path] to delete a file. file must not be open by anyone.  
* POST (or GET) /file/close/[path] to mark the file closed. The server will discard your edit history.  
* POST (or GET) /file/close/[path] to mark the file closed. The server will discard your edit history.  
* GET /file/listopen/ to list open files. a JSON dictionary of {filename: {mode: [user names]}} will be returned. For example, if subdir1/subdir2/test.py is open readonly by bgalbs and read/write by jbellis, openfiles will return <tt>{"subdir1/subdir2/test.py": {"r": ["bgalbs"], "rw": ["jbellis"]}}</tt>
* GET /file/listopen/ to list open files for the current user. a JSON dictionary of <tt>{ project: { filename: mode } }</tt> will be returned. For example, if subdir1/subdir2/test.py is open read/write, openfiles will return <tt>{ "subdir1": { "somedir2/test.py": "rw" } }</tt>


== Settings ==
== Settings ==
123

edits

Navigation menu