Status Update
Comments
mi...@google.com <mi...@google.com> #2
Hello there!
Thank you for filing this feature request.
Currently Drive does not support changing the ownership for items which are owned by gmail.com
accounts; it's supported for Workspace accounts.
Also, please notice that, since consent from the new owner is required, this transfer most likely cannot be a 1-step process that can be executed solely under the old owner's account.
In any case, can you provide more information about your situation? More specifically:
- What impact (in terms of productivity, costs, etc.) could this feature have in your situation?
- What workaround (if any) are you currently using?
Kind regards.
em...@gmail.com <em...@gmail.com> #3
Hey, thanks for the quick response!
The account which owns these files is a service account from my GCP application. Specifically, this one:
This was working as expected until last week, was something explicitly changed? I am more than fine with it being a multi-step process. It seems quite logical that the service account should be able to initiate the ownership transfer and then only once accepted, the file be transferred to the new owner. At this time, I do not see any API here that exposes this functionality:
The situation is:
- The service account creates a new Google Document on behalf of the user using the application by duplicating an existing template Document, updates the new Document, and then intends to transfer ownership to the requesting user.
- Today, since the service account is unable to transfer ownership, instead I have made the requesting user an editor. This is a workaround.
- The service account is now burdened with owning every single file that is requested by all users of the application. The requesting user can remove it from their Drive but there is no good way to truly delete the file. This uses up space against the Drive allocated to the service account and incurs additional upkeep on my end.
jo...@gmail.com <jo...@gmail.com> #4
mi...@google.com <mi...@google.com> #5
Hi,
Can you please clarify whether the new owner of the file is a gmail.com
account or a Workspace account?
em...@gmail.com <em...@gmail.com> #7
I created a small utility to test this. I get the same error when the new owner is a gmail.com account or one from another domain I own.
mi...@google.com <mi...@google.com> #8
The service account creates a new Google Document on behalf of the user using the application by duplicating an existing template Document, updates the new Document, and then intends to transfer ownership to the requesting user.
Have you considered granting the service account
em...@gmail.com <em...@gmail.com> #9
Unfortunately, while a nice suggestion, this does not help in my case because my application services many users across various domains. These are clients of a service-based web app, and I have no control over their individual emails. Could an endpoint be provided that would send the pending ownership transfer request to the user? Or is there some better way?
mi...@google.com <mi...@google.com> #10
I have requested this internally.
Any public updates about this will be communicated here.
Thank you.
ad...@wearetheloop.org <ad...@wearetheloop.org> #11
I may be wrong, but it now seems the API can now only transfer ownership within a domain. This is a much more restrictive use case than the Google Drive UI. It is also inconsistent with the API documentation and the python client documentation, which do not indicate that gmail-to-gmail ownership transfers are not possible.
nc...@twilio.com <nc...@twilio.com> #12
mi...@google.com <mi...@google.com> #13
Hi, this behavior has already been reported internally, as mentioned in
lu...@gmail.com <lu...@gmail.com> #14
Does that mean that this ticket should be marked as "Won't Fix" too? I hope not. This affects our production app which had this functionality built in for a few years.
It sure would be great to enable transfer Google Docs (as people here have mentioned) from service accounts to Gmail accounts, even if it's a multi-step process as "em" mentioned above.
I would be thrilled if the multi-step process happens over email instead of OAuth. For example, after the service account begins the transfer, the recipient receives an email and can approve the transfer over email. Even better if it would be a 1-time approval rather than the recipient having to approve each transfer.
Thank you for your consideration!
de...@gmail.com <de...@gmail.com> #15
st...@gmail.com <st...@gmail.com> #16
lu...@gmail.com <lu...@gmail.com> #17
Thank you!
em...@gmail.com <em...@gmail.com> #18
Please provide an update on this issue. It is clear that this was unintentionally broken and a behavior change from what was functionally correct and useful. If this is not going to be fixed, please provide a workaround as the request is both reasonable and required for some very standard usability use cases. Thanks, and Merry Christmas.
sp...@gmail.com <sp...@gmail.com> #19
da...@fureyfs.com <da...@fureyfs.com> #20
ke...@maximally.io <ke...@maximally.io> #21
lu...@gmail.com <lu...@gmail.com> #22
is...@google.com <is...@google.com>
br...@gmail.com <br...@gmail.com> #23
bi...@gmail.com <bi...@gmail.com> #24
jp...@google.com <jp...@google.com>
[Deleted User] <[Deleted User]> #25
se...@gmail.com <se...@gmail.com> #26
same issue here, try to change owner on docs.
One user
var permission = {
'role': 'owner'
};
gapi.client.drive.permissions.update({
'fileId': fileId,
'permissionId': permissionId,
'transferOwnership': true,
})
=> 403 : {code: 403, message: "Consent is required to transfer ownership of a file to anoth.....}
When using API explore : Same issue. When doing with UI, everithing run well, second user receive an email/notification, and owner is changed.
Any idea when this functionality will be available?
ca...@gmail.com <ca...@gmail.com> #27
fr...@gmail.com <fr...@gmail.com> #28
¡Gracias!
br...@gmail.com <br...@gmail.com> #29
It seems that there should be way to upload files to basic personal account storage (i.e. no shared drives or business accounts) using an API without being limited to 15GB. Am I missing something?
At the very least it would be nice if there was an easy way to do one or more of the following:
1) Increase the storage on a service account
2) Transfer ownership (manual or otherwise) of an uploaded file from a service account to a personal account (not necessarily same domains)
3) Allow a personal account subscription quota to be used for a service account.
4) Upload a file directly to a personal account (without a service account) using an API
It sounds like setting up impersonation on the service account may be an alternative approach but it also sounds like this only works for business/Google Workspace accounts and my application is intended for regular google account holders. I am hoping that Google Drive can serve as a utilitarian base platform for the average user.
Please let us know if any of the items listed is possible since the only other workaround I have been able to find is to create additional service accounts when storage is needed but that could quickly become unwieldy. Help!!!
Thank you
ma...@yandex.ru <ma...@yandex.ru> #30
hi...@gmail.com <hi...@gmail.com> #31
be...@backmarket.com <be...@backmarket.com> #32
ke...@gmail.com <ke...@gmail.com> #33
any fixes/workarounds or update on this ????
im getting this
{ message: 'Consent is required to transfer ownership of a file to another user.', domain: 'global', reason: 'consentRequiredForOwnershipTransfer' }
pa...@gmail.com <pa...@gmail.com> #34
Same issue, API Drive V3
def return_folder_id():
query = f"name='{CRNT_MTHYR}'"
current_month_folder = drive.files().list(q=query).execute()['files']
if bool(current_month_folder):
return current_month_folder[0]['id']
else:
print("creating new folder")
req_body = {
"name": CRNT_MTHYR,
"mimeType": "application/vnd.google-apps.folder",
"parents": [DRIVE_FOLDER_ID],
}
new_folder = drive.files().create(body=req_body).execute()
permissions={"type":"user", "emailAddress":"example@gmail.com","role":"owner"}
drive.permissions().create(fileId=new_folder['id'],
transferOwnership=True,
body=permissions).execute()
return new_folder['id']
al...@gmail.com <al...@gmail.com> #35
zu...@gmail.com <zu...@gmail.com> #36
I had a similar situation where this would come in very handy: I'm part of a small non-profit organisation that uses Google Drive for file management. The organisation has its own gmail and a Drive which is shared with all members (not using Google Workspaces). Historically, the members were using their private emails to upload files to the shared Drive. Now we have an issue where users complain about their personal drive spaces being "used up" by files that should belong to the organisation. An ownership migration script would be super handy, otherwise each member would have to manually transfer ownership for each file, which becomes cumbersome as some members own more than 100 files :( I would like to be able to run this script as the organisation "system" user, list all the files for each member and transfer ownership from the member to the system user. But I'm getting the error "Consent is required to transfer ownership of a file to another user [error=403]".
I had to come up with a workaround where I wrote a script that I run with each member, where I first authenticate as the organisation "system" user, and list all the files in the shared Drive owned by a particular member, and make a copy of each file (granting permission to the original member). In this way, the system user becomes the owner of the copy. Then the "human" member authenticates, and for each file that was copied in step 1, the script removes the original and renames the copy. It's ugly but it works...
Description
Before filing an issue, please read and follow these instructions carefully.
First, please search through existing issues to ensure that the feature request has not already been reported. You can start the search here:https://issuetracker.google.com/savedsearches/566258
If the feature has already been requested, you can click the star next to the issue number to subscribe and receive updates. We prioritize responding to the issues with the most stars. You can also comment on the issue to provide any context of how the feature would benefit you.
Also, please verify that the functionality you are requesting is not already present in the current API and tools.
If your feature has not been requested, please provide all of the following:
A short description of the request: Using the REST api via com.google.api.client.googleapis in Java, transferring ownership to another user worked until a few days ago. Now any request to transfer ownership of a document results in the error message "Consent is required to transfer ownership of a file to another user". It's unclear how to request consent using the api.
What is the purpose of this new feature? Provide a code-driven way to transfer file ownership in Drive.
What existing APIs would this affect? com.google.api.services.drive
What existing data does this use? Drive, Permissions, accounts
Please provide any additional information below. Simple to reproduce: