获取上传者名称

时间:2015-03-05 20:36:43

标签: c# dropbox dropbox-api

是否可以在Dropbox中获取文件的上传者名称? (http://i.imgur.com/rFZ8gll.png) 我有以下代码以字符串形式获取文件信息,但需要解析。

    private string GetResponse(Uri uri)
    {
        var oauth = new OAuth();
        var requestUri = oauth.SignRequest(uri, _consumerKey, _consumerSecret, _accessToken);
        var request = (HttpWebRequest)WebRequest.Create(requestUri);
        request.Method = WebRequestMethods.Http.Get;
        var response = request.GetResponse();
        var reader = new StreamReader(response.GetResponseStream());
        return reader.ReadToEnd();
    }

在浏览结果时,上传者名称无法输入。示例文件信息:

    {
        "rev" : "1304014014338",
        "thumb_exists" : true,
        "path" : "/Screenshots/Screenshot 2015-02-09 21.48.41.png",
        "is_dir" : false,
        "client_mtime" : "Mon, 09 Feb 2015 13:48:42 +0000",
        "icon" : "page_white_picture",
        "read_only" : false,
        "modifier" : null,
        "bytes" : 321551,
        "modified" : "Mon, 09 Feb 2015 13:49:10 +0000",
        "size" : "314 KB",
        "root" : "dropbox",
        "mime_type" : "image/png",
        "revision" : 77888
    }

1 个答案:

答案 0 :(得分:0)

modifier字段会告诉您上次更改文件的人员,但前提是该文件位于共享文件夹中。