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

Google Apps Profiles API is deprecated #2

Open
aryelnr opened this issue Jan 4, 2017 · 3 comments
Open

Google Apps Profiles API is deprecated #2

aryelnr opened this issue Jan 4, 2017 · 3 comments
Assignees
Labels

Comments

@aryelnr
Copy link

aryelnr commented Jan 4, 2017

Hi, could you help me here?
I run this command
python shared_contacts_profiles.py [email protected] --export=ml.csv

But I Receive this error

### Exporting contacts/profiles to CSV file: ml.csv
Retrieving contacts... (0 retrieved so far)
All contacts retrieved: 0 total
Retrieving profiles... (0 retrieved so far)
Traceback (most recent call last):
  File "shared_contacts_profiles.py", line 1180, in <module>
    main()
  File "shared_contacts_profiles.py", line 1175, in main
    contacts_manager.ExportMsOutlookCsv(contact_entries, profile_entries, export_csv_file)
  File "shared_contacts_profiles.py", line 552, in ExportMsOutlookCsv
    profile_entries))
  File "shared_contacts_profiles.py", line 742, in writerows
    for row in rows:
  File "shared_contacts_profiles.py", line 260, in GetAllProfiles
    desired_class=gdata.contacts.data.ProfilesFeed)
  File "C:\Python27\lib\site-packages\gdata\client.py", line 640, in get_feed
    **kwargs)
  File "C:\Python27\lib\site-packages\gdata\client.py", line 319, in request
    RequestError)
gdata.client.RequestError: Server responded with: 403, The Google Apps Profiles API has been officially deprecated. See https://developers.google.com/google-apps/profiles/ for more information.
@rdoursenaud rdoursenaud self-assigned this Jan 5, 2017
@rdoursenaud rdoursenaud added the bug label Jan 5, 2017
@rdoursenaud
Copy link
Member

rdoursenaud commented Jan 5, 2017

The error is quite clear. The API used to retrieve the profiles is deprecated.
The code needs to be ported to use the new Directory API from the Google Apps Admin SDK.
I'll give it a try.

@rdoursenaud rdoursenaud changed the title Problem when I Try run script Google Apps Profiles API is deprecated Jan 5, 2017
@rdoursenaud
Copy link
Member

After having a quick glance at the code, I believe this will need a major redesign of the application.
I don't quite have the incentive to tackle this at the moment.
Any help appreciated.

@rdoursenaud
Copy link
Member

rdoursenaud commented Jan 5, 2017

For the record, the work that needs to be done is:

In the meantime, if excluding the shared profiles informations from your export is an acceptable tradeoff, I think you can comment line 1174 to only export the contacts.

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

No branches or pull requests

2 participants