cros features - all stating "Not authorized"

134 views
Skip to first unread message

Scott S

unread,
Apr 30, 2015, 1:07:22 PM4/30/15
to google-ap...@googlegroups.com
I am trying to use gam to modify chromeos information.  I can seem to access other items fine like users, but any cros operations such as print or info are giving me "Not Authorized to access this resource/api".

I tried adding an additional scope into the API client access on the google apps domain for chrome os (https://www.googleapis.com/auth/admin.directory.device.chromeos) but that didn't appear to help.

Is this another API that is needed for the cros functions to work?

Here is the debug output:

$ python gam.py print cros                                                      

Retrieving All Chrome OS Devices for organization (may take some time for       

large accounts)...                                                              

connect: (www.googleapis.com, 443)                                              

send: 'GET /admin/directory/v1/customer/my_customer/devices/chromeos?alt=json&prettyPrint=true                                                                             

HTTP/1.1\r\nHost: www.googleapis.com\r\ncontent-length: 0\r\nauthorization:     

Bearer ya29..........5yQ\r\naccept-encoding:                                                         

gzip, deflate\r\naccept: application/json\r\nuser-agent: GAM 3.44 -             

http://git.io/gam / Jay Lee <.....@gmail.com> / Python 2.7.2 final /          

Darwin-12.5.0-x86_64-i386-64bit x86_64 / google-api-python-client/1.4.0         

(gzip)\r\n\r\n'                                                                 

reply: 'HTTP/1.1 403 Forbidden\r\n'                                             

header: Vary: Origin                                                            

header: Vary: X-Origin                                                          

header: Content-Type: application/json; charset=UTF-8                           

header: Content-Encoding: gzip                                                  

header: Date: Thu, 30 Apr 2015 16:32:52 GMT                                     

header: Expires: Thu, 30 Apr 2015 16:32:52 GMT                                  

header: Cache-Control: private, max-age=0                                       

header: X-Content-Type-Options: nosniff                                         

header: X-Frame-Options: SAMEORIGIN                                             

header: X-XSS-Protection: 1; mode=block                                         

header: Server: GSE                                                             

header: Alternate-Protocol: 443:quic,p=1                                        

header: Transfer-Encoding: chunked                                              

Error 403: Not Authorized to access this resource/api - forbidden               


Here is the oauth2 info:

OAuth File: /Applications/GAM-3.44/oauth2.txt                                   

Client ID: .....apps.googleusercontent.com        

Secret: .......                                                

Scopes:                                                                         

  https://www.googleapis.com/auth/userinfo.email                                

  https://www.googleapis.com/auth/admin.directory.group                         

  https://www.googleapis.com/auth/admin.directory.orgunit                       

  https://www.googleapis.com/auth/admin.directory.user                          

  https://www.googleapis.com/auth/admin.directory.device.chromeos               

  https://www.googleapis.com/auth/admin.directory.device.mobile                 

  https://apps-apis.google.com/a/feeds/emailsettings/2.0/                       

  https://apps-apis.google.com/a/feeds/calendar/resource/                       

  https://apps-apis.google.com/a/feeds/compliance/audit/                        

  https://apps-apis.google.com/a/feeds/domain/                                  

  https://www.googleapis.com/auth/apps.groups.settings                          

  https://www.googleapis.com/auth/calendar                                      

  https://www.googleapis.com/auth/admin.reports.audit.readonly                  

  https://www.googleapis.com/auth/admin.reports.usage.readonly                  

  https://www.googleapis.com/auth/drive.file                                    

  https://www.googleapis.com/auth/apps.licensing                                

  https://www.googleapis.com/auth/admin.directory.user.security                 

  https://www.googleapis.com/auth/admin.directory.notifications                 

  https://www.googleapis.com/auth/siteverification                              

  https://mail.google.com/                                                      

  https://www.googleapis.com/auth/admin.directory.userschema                    

  https://www.googleapis.com/auth/plus.me                                       

Google Apps Admin: ..........                             


Jay Lee

unread,
Apr 30, 2015, 1:11:08 PM4/30/15
to google-ap...@googlegroups.com
Managing Chrome devices requires that you purchase device licenses for your Google Apps domain. See:


you need to make sure you see the licenses in your admin console before cros commands will work.


Jay Lee

--
You received this message because you are subscribed to the Google Groups "Google Apps Manager" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-apps-man...@googlegroups.com.
To post to this group, send email to google-ap...@googlegroups.com.
Visit this group at http://groups.google.com/group/google-apps-manager.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-apps-manager/6ee58a75-61b5-4042-bda6-6144c5cbcb6f%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Scott S

unread,
Apr 30, 2015, 3:12:36 PM4/30/15
to google-ap...@googlegroups.com
That was it.  There are two domains and the authorization was done under the wrong domain that didn't actually have any chrome devices in it.  When the authorization happened, it opened the default browser that was logged into the other domain at the time.

Kevin Moore

unread,
Oct 12, 2015, 8:34:06 PM10/12/15
to Google Apps Manager
We have no chrome OS devices in our account but do have a number of chrome box for meetings.  Is there a way for GAM to report on our CFM devices?

Kevin M.


Jay Lee

To unsubscribe from this group and stop receiving emails from it, send an email to google-apps-manager+unsub...@googlegroups.com.
Reply all
Reply to author
Forward
0 new messages