GooglePubSub icon

GooglePubSub

Consume GooglePubSub API

Overview

This node integrates with Google Cloud Pub/Sub to publish messages to a specified topic. It is useful for workflows that need to send data or notifications to other systems or services via Google Pub/Sub. For example, it can be used to trigger downstream processes by publishing event messages or to send data updates to subscribers listening on a Pub/Sub topic.

Use Case Examples

  1. Publishing a JSON message to a Google Pub/Sub topic to notify other services of a new user registration.
  2. Sending event data from an automation workflow to a Pub/Sub topic for real-time processing by other applications.

Properties

Name Meaning
Project Id. Google Cloud project id used to identify the Google Cloud project where the Pub/Sub topic exists.
Topic Name of the Google Pub/Sub topic to which the message will be published.
Content (JSON) The JSON content to be published as a message to the specified Pub/Sub topic.

Output

JSON

  • id - The message ID returned by Google Pub/Sub after successfully publishing the message.

Dependencies

  • Google Cloud Pub/Sub client library (@google-cloud/pubsub)
  • Google Auth Library (google-auth-library)

Troubleshooting

  • Ensure that the provided Google API credentials are valid and have the necessary permissions to publish messages to the specified Pub/Sub topic.
  • Verify that the 'Content (JSON)' input is a valid JSON string; otherwise, the node will throw a JSON parsing error.
  • Check that the specified project ID and topic name are correct and exist in your Google Cloud project.

Discussion