Skip to content
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

Set permissions #19

Open
mausch opened this issue Aug 14, 2015 · 1 comment
Open

Set permissions #19

mausch opened this issue Aug 14, 2015 · 1 comment

Comments

@mausch
Copy link
Owner

mausch commented Aug 14, 2015

Use the Drive API to set permissions for documents created through GDataDB, so they can be shared with personal accounts and thus opened with the Drive web UI.

@fabriciogd
Copy link

I make a method that add permission in the file

var request = _requestFactory.CreateRequest();
request.Headers.Set("Content-Type", "application/json");
var data = JsonConvert.SerializeObject(new {
        role = role,
        type = type,
        value = email
});
request.UploadString(string.Format("https://www.googleapis.com/drive/v2/files/{0}/permissions", this._id), data);

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants