Invalid Input: memberKey - invalid

2,358 views
Skip to first unread message

Bryan Guidroz

unread,
Apr 3, 2017, 1:32:26 PM4/3/17
to GAM for G Suite
My CSV input file is laid out as follows:

FirstName,LastName,Username,DOB,Site
John,Doe,JohnDoe,01-01-1975,Buildng A

An example command giving this error:
gam csv BuildingA.csv gam update group buil...@mydomain.org add member user ~Username

The result:

Using 7 processes...
 adding member JohnDoe@unknown...

ERROR: 400: Invalid Input: memberKey - invalid


My input CSV file does not include my Google domain so that's what's causing the "Invalid Input: memberKey - invalid" error.
This started recently.  Excluding the domain has worked fine in previous versions of GAM.

Is there a way to append my domain to the command?
gam csv BuildingA.csv gam update group buil...@mydomain.org add member user ~Username & "@mydomain.com"
This would be the ideal solution for us.

Or is there a "default domain" setting in GAM?

Thank you.

Jay Lee

unread,
Apr 3, 2017, 1:36:51 PM4/3/17
to google-ap...@googlegroups.com
This is due to an error I made in GAM 4.12. Upgrade to latest version of GAM and then run:

gam oauth revoke

then re-run your command and authorize again. It should work after that.

Jay

--
You received this message because you are subscribed to the Google Groups "GAM for G Suite" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-apps-manager+unsub...@googlegroups.com.
To post to this group, send email to google-apps-manager@googlegroups.com.
Visit this group at https://groups.google.com/group/google-apps-manager.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-apps-manager/5b0dce08-1cdb-4cdd-a63f-ab3a58baf7e2%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Bryan Guidroz

unread,
Apr 3, 2017, 1:46:44 PM4/3/17
to GAM for G Suite
Thanks... Looks like that did it.
And it looks like "~~Username~~@mydomain.com" might have worked ... but I would have had a lot of fixing to do.
SO THANK YOU!!!!

To post to this group, send email to google-ap...@googlegroups.com.

Edward Crist

unread,
Apr 3, 2017, 1:49:53 PM4/3/17
to google-ap...@googlegroups.com
Thanks, Jay.



Edward Crist
Technology Manager
City Charter High School
__________________________
201 Stanwix St.
Pittsburgh, PA 15222

"Humility is not thinking less of yourself, but thinking of yourself less" - C. S. Lewis

The optimist believes we live in the best possible world....the pessimist fears this is true.


On Mon, Apr 3, 2017 at 1:36 PM, Jay Lee <jay...@gmail.com> wrote:
This is due to an error I made in GAM 4.12. Upgrade to latest version of GAM and then run:

gam oauth revoke

then re-run your command and authorize again. It should work after that.

Jay
On Mon, Apr 3, 2017 at 1:32 PM, Bryan Guidroz <bryang...@tpsdonline.org> wrote:
My CSV input file is laid out as follows:

FirstName,LastName,Username,DOB,Site
John,Doe,JohnDoe,01-01-1975,Buildng A

An example command giving this error:
gam csv BuildingA.csv gam update group buil...@mydomain.org add member user ~Username

The result:

Using 7 processes...
 adding member JohnDoe@unknown...

ERROR: 400: Invalid Input: memberKey - invalid


My input CSV file does not include my Google domain so that's what's causing the "Invalid Input: memberKey - invalid" error.
This started recently.  Excluding the domain has worked fine in previous versions of GAM.

Is there a way to append my domain to the command?
gam csv BuildingA.csv gam update group buil...@mydomain.org add member user ~Username & "@mydomain.com"
This would be the ideal solution for us.

Or is there a "default domain" setting in GAM?

Thank you.

--
You received this message because you are subscribed to the Google Groups "GAM for G Suite" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-apps-manager+unsubscribe...@googlegroups.com.

--
You received this message because you are subscribed to the Google Groups "GAM for G Suite" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-apps-manager+unsub...@googlegroups.com.
To post to this group, send email to google-apps-manager@googlegroups.com.
Visit this group at https://groups.google.com/group/google-apps-manager.

KevinAurora

unread,
Nov 9, 2017, 6:24:29 PM11/9/17
to GAM for G Suite
Jay,
I think I'm seeing this  issue under GAM 4.32 even after trying the oauth revoke trick.

kmoore-mbp:src kmoore$ gam update group <group> add member <user>
 Group: <group>@<domain>, <user> Add as MEMBER Failed: Invalid Input: memberKey
kmoore-mbp:src kmoore$ gam --version

Python 2.7.10 64-bit final
google-api-python-client 1.6.3
oauth2client 4.1.2
Darwin-16.7.0-x86_64-i386-64bit x86_64
Path: /Users/kmoore/gam/GAM-4.32/src

Ross Scroggs

unread,
Nov 9, 2017, 6:35:24 PM11/9/17
to google-ap...@googlegroups.com
Kevin,

Was <user> just joe or was it j...@domain.com?
You can do this one of two ways:
1) gam update group <group> add member j...@domain.com
2) gam update group <group> add member user joe

In form 1, you must supply the domain name.
in form 2, you can omit the domain name.

Ross


Ross

--
You received this message because you are subscribed to the Google Groups "GAM for G Suite" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-apps-manager+unsub...@googlegroups.com.
To post to this group, send email to google-apps-manager@googlegroups.com.
Visit this group at https://groups.google.com/group/google-apps-manager.

For more options, visit https://groups.google.com/d/optout.



--

Kevin Moore

unread,
Nov 9, 2017, 6:39:51 PM11/9/17
to google-ap...@googlegroups.com
Ross,

Thank you.  There's my problem.  I have been using add member joe rather than add member user joe.

Thx,

Kevin M.

To unsubscribe from this group and stop receiving emails from it, send an email to google-apps-manager+unsubscribe...@googlegroups.com.

To post to this group, send email to google-apps-manager@googlegroups.com.
Visit this group at https://groups.google.com/group/google-apps-manager.



--

--
You received this message because you are subscribed to a topic in the Google Groups "GAM for G Suite" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/google-apps-manager/CT1PXLC0d88/unsubscribe.
To unsubscribe from this group and all its topics, send an email to google-apps-manager+unsub...@googlegroups.com.

To post to this group, send email to google-apps-manager@googlegroups.com.
Visit this group at https://groups.google.com/group/google-apps-manager.
Reply all
Reply to author
Forward
0 new messages