Skip to content

Google Chat Spaces

The Google Chat Spaces component allows you to interact with Google Chat directly from your Nappai workflows. You can use it to find spaces, create new communication channels, get information about specific spaces, and add or remove users from these spaces. This helps you automate how teams communicate and manage channels within your Google Workspace.

How it Works

This component acts as a bridge between Nappai and the Google Chat service. When you configure the component, Nappai securely connects to the Google Chat API using the credentials you provide. Based on the action you choose, Nappai sends instructions to Google Chat to perform the requested task. Google Chat processes the request and returns the result to your workflow. This seamless integration allows you to automate tasks like creating team spaces, listing available channels, or updating membership without manually switching between apps.

Connection & Credentials

This component requires configuring a credential in the Nappai panel before interacting with the external service:

  1. Go to the Credentials section in your Nappai panel.
  2. Create a new credential of the type Google Chat and fill in the required fields (Select Project, Client Id, Client Secret, Google Chat access).
  3. In your workflow, select the saved credential in the Credential input field of this node.

Inputs

Input Fields

  • Credential: Select the Google Chat credential configured in your Nappai account to authenticate requests.
  • Operation: Select the action to perform, such as listing spaces, creating a new space, retrieving details, or managing members.
  • Space: Select an existing Google Chat space to view or modify.
  • Spaces Count: The maximum number of spaces to retrieve when listing.
  • Space Name: The display name for a new space you are creating.
  • Space Type: The type of space to create, for example public or private.
  • User Email: The email address of a user or bot to add or remove.

Outputs

The component returns data related to the operation you selected. You can use this output in subsequent nodes to check results, trigger other actions, or store information.

Output Data Example (JSON)

json { “result”: { “name”: “spaces/abc123xyz”, “displayName”: “Marketing Team”, “spaceType”: “SINGLE_CHAT”, “icon”: { “url”: “https://avatar.googleapis.com/avatar/icon.png” } }, “success”: true }

Connectivity

This component is versatile and can be connected to various other nodes in your workflow. It is commonly used after a Trigger or Search component to initiate actions based on data. The output can be passed to Webhook, Email, or Message components to notify teams about space changes or share links to newly created spaces.

Usage Example

Scenario: Create a New Project Space

You need to automatically create a dedicated Google Chat space for a new client project.

  1. Add the Google Chat Spaces component to your workflow.
  2. Select your Credential and set Operation to “Create”.
  3. Enter the Space Name (e.g., “Acme Project Alpha”) and Space Type (e.g., “SPACE”).
  4. Run the workflow. The component creates the space and returns the space details in the Output.
  5. Connect the output to a Message component to send the space link to the project manager via email or chat.

Tips and Best Practices

  • Use the Spaces Count input to limit the number of results when listing spaces, which can improve performance in large accounts.
  • Ensure that user Email addresses are correct and active to avoid errors when adding or removing members.
  • When creating spaces, verify that the Space Type matches your organization’s policies for public or private channels.
  • Check the Success status in the output to confirm that operations completed as expected before proceeding to the next step.

Security Considerations

This component uses OAuth2 authentication. Ensure you only share credentials with trusted users and revoke access when no longer needed. Nappai handles authentication securely, but sensitive data like emails and space names are transmitted via the Google Chat API, so ensure your Google Cloud project has appropriate security configurations. Keep your Client Id and Secret confidential and store them securely in the Nappai credentials manager.