Zum Inhalt

Google: OAuth2 einzelner Dienst#

Dieses Dokument enthält Anweisungen zum Erstellen von Google-Anmeldeinformationen für einen einzelnen Dienst. Sie sind auch als Video verfügbar.

Voraussetzungen#

OAuth einrichten#

Es gibt fünf Schritte, um Ihre Localmind Automate-Anmeldeinformationen mit Google-Diensten zu verbinden:

  1. Erstellen Sie ein Google Cloud Console-Projekt.
  2. Aktivieren Sie APIs.
  3. Konfigurieren Sie Ihren OAuth-Zustimmungsbildschirm.
  4. Erstellen Sie Ihre Google OAuth-Clientanmeldeinformationen.

Erstellen Sie ein Google Cloud Console-Projekt#

Erstellen Sie zunächst ein Google Cloud Console-Projekt. Wenn Sie bereits ein Projekt haben, fahren Sie mit dem nächsten Abschnitt fort:

  1. Log in to your Google Cloud Console using your Google credentials.
  2. In the top menu, select the project dropdown in the top navigation and select New project or go directly to the New Project page.
  3. Enter a Project name and select the Location for your project.
  4. Select Create.
  5. Check the top navigation and make sure the project dropdown has your project selected. If not, select the project you just created.

APIs aktivieren#

Aktivieren Sie nach der Erstellung Ihres Projekts die APIs, auf die Sie Zugriff benötigen:

  1. Access your Google Cloud Console - Library. Make sure you're in the correct project.
  2. Go to APIs & Services > Library.
  3. Search for and select the API(s) you want to enable. For example, for the Gmail node, search for and enable the Gmail API.
  4. Some integrations require other APIs or require you to request access:

    Google Drive API required

    The following integrations require the Google Drive API, as well as their own API:

    • Google Docs
    • Google Sheets
    • Google Slides

    Google Vertex AI API

    In addition to the Vertex AI API you will also need to enable the Cloud Resource Manager API.

  5. Select ENABLE.

Konfigurieren Sie Ihren OAuth-Zustimmungsbildschirm#

Wenn Sie OAuth noch nicht in Ihrem Google Cloud-Projekt verwendet haben, müssen Sie den OAuth-Zustimmungsbildschirm konfigurieren:

  1. Greifen Sie auf Ihre Google Cloud Console - Bibliothek zu. Stellen Sie sicher, dass Sie sich im richtigen Projekt befinden.
  2. Öffnen Sie das linke Navigationsmenü und gehen Sie zu APIs & Dienste > OAuth-Zustimmungsbildschirm.
  3. Wählen Sie für Nutzertyp Intern für den Benutzerzugriff innerhalb des Google Workspace Ihrer Organisation oder Extern für jeden Benutzer mit einem Google-Konto. Weitere Informationen zu Nutzertypen finden Sie in der Google-Dokumentation Nutzertyp.
  4. Wählen Sie Erstellen.
  5. Geben Sie die wesentlichen Informationen ein:
    • App-Name
    • E-Mail-Adresse für den Nutzersupport
    • Feld E-Mail-Adressen in Kontaktinformationen für Entwickler
  6. Fügen Sie im Abschnitt Autorisierte Domains die Domain Ihrer Localmind Automate-Instanz hinzu.
  7. Wählen Sie SPEICHERN UND FORTFAHREN, um zur Seite Bereiche zu gelangen.
  8. Sie müssen keine Bereiche festlegen. Wählen Sie erneut SPEICHERN UND FORTFAHREN, um zur Seite Zusammenfassung zu gelangen.
  9. Überprüfen Sie auf der Seite Zusammenfassung die Informationen auf Richtigkeit.

Erstellen Sie Ihre Google OAuth-Clientanmeldeinformationen#

Erstellen Sie als Nächstes die OAuth-Clientanmeldeinformationen in Google:

  1. Wählen Sie im Abschnitt APIs & Dienste die Option Anmeldeinformationen aus.
  2. Wählen Sie + ANMELDEINFORMATIONEN ERSTELLEN > OAuth-Client-ID.
  3. Wählen Sie in der Dropdown-Liste Anwendungstyp die Option Webanwendung aus.
  4. Google generiert automatisch einen Namen. Aktualisieren Sie den Namen auf einen Namen, den Sie in Ihrer Konsole wiedererkennen.
  5. Kopieren Sie aus Ihren Localmind Automate-Anmeldeinformationen die OAuth-Weiterleitungs-URL. Fügen Sie sie in der Google Console in die Autorisierten Weiterleitungs-URIs ein.
  6. Wählen Sie ERSTELLEN.

Beenden Sie Ihre Localmind Automate-Anmeldeinformationen#

Nachdem das Google-Projekt und die Anmeldeinformationen vollständig konfiguriert sind, beenden Sie die Localmind Automate-Anmeldeinformationen:

  1. Kopieren Sie aus dem Google-Modal OAuth-Client erstellt die Client-ID. Geben Sie diese in Ihren Localmind Automate-Anmeldeinformationen ein.
  2. Kopieren Sie aus demselben Google-Modal den Clientschlüssel. Geben Sie diesen in Ihren Localmind Automate-Anmeldeinformationen ein.
  3. Wählen Sie in Localmind Automate Mit Google anmelden, um Ihre Google-Authentifizierung abzuschließen.
  4. Speichern Sie Ihre neuen Anmeldeinformationen.

Fehlerbehebung#

Google hat diese App nicht verifiziert#

If using the OAuth authentication method, you might see the warning Google hasn't verified this app. To avoid this, you can create OAuth credentials from the same account you want to authenticate.

If you need to use credentials generated by another account (by a developer or another third party), follow the instructions in Google Cloud documentation | Authorization errors: Google hasn't verified this app.

Google Cloud-App wird nicht autorisiert#

For Google Cloud apps with Publishing status set to Testing and User type set to External, consent and tokens expire after seven days. Refer to Google Cloud Platform Console Help | Setting up your OAuth consent screen for more information. To resolve this, reconnect the app in the Localmind Automate credentials modal.