Connect and integrate Gmail with Hyper for seamless data ingestion and querying.

Integrating Gmail with Hyper allows developers to leverage email data directly from Gmail, enabling efficient data synchronization and interaction with Hyper's platform. This guide provides instructions for two distinct scenarios: connecting Gmail for internal company or project data ingestion using an API key, and configuring Gmail for Hyper Connect, where end-users can connect their data to Hyper.

Scenario 1: Internal Data Ingestion Using an API Key

For developers looking to use internal email data from their own company or project, the setup process is straightforward:

Connecting Gmail in the Hyper UI

  1. Access Hyper UI: Log into the Hyper user interface.

  2. Navigate to Data Sources: Go to the section where you can manage your data sources.

  3. Add Gmail: Select Gmail from the list of data sources and initiate the connection process.

  4. Authenticate: Use your Google credentials to authenticate and grant Hyper access to your Gmail data.

  5. Select Emails: Choose the specific emails or labels from Gmail that you want to ingest into Hyper.

  6. Start Querying: With the data ingested, you can now use your API key to start querying your data through Hyper's API.

Ingesting and Querying Data

Once Gmail is connected, developers can begin ingesting data:

  1. Use the Hyper API: Send requests to Hyper's endpoints to ingest data from the connected Gmail.

  2. Query Data: Apply Hyper's querying capabilities to the ingested data for insights and analysis.

Scenario 2: Hyper Connect Integration for User Data

When the goal is to enable the DEVELOPER'S USERS to connect their data to Hyper via Hyper Connect, additional steps are required:

OAuth Configuration for Gmail

  1. Register OAuth Application: Go to the Google Cloud Console, create a new OAuth application, and obtain client credentials (client ID and client secret).

  2. Set Redirect URIs: Configure the redirect URIs provided by Hyper.

  3. Implement OAuth Flow: In your application, implement the OAuth flow to prompt users to authorize access to their Gmail data.

  4. Exchange Authorization Code for Tokens: After users authorize access, exchange the received authorization code for access and refresh tokens.

  5. Secure Token Storage: Store the access and refresh tokens securely within your application.

  6. Refresh Tokens: Implement logic to refresh the access tokens using the refresh tokens as needed.

Access Control

Developers may want to set up access control for user data:

  1. Define Access Levels: Determine different levels of access for different types of users.

  2. Implement Role-Based Access Control: Assign roles to users and enforce permissions based on these roles.

  3. Manage User Sessions: Keep track of user sessions and ensure they are tied to the validity of the access tokens.

Using Data with Hyper

After setting up Hyper Connect:

  1. Tagging and Querying: Use Hyper's API to tag and query the connected data.

  2. Webhooks: Optionally, set up webhooks to receive real-time updates on specific events.

Remember to verify your data source connections to make the data available for Hyper's integration and querying capabilities.