Google Chat ऐप्लिकेशन के लिए गड़बड़ी लॉग करने की सुविधा चालू करें
संग्रह की मदद से व्यवस्थित रहें
अपनी प्राथमिकताओं के आधार पर, कॉन्टेंट को सेव करें और कैटगरी में बांटें.
इस पेज पर, Chat ऐप्लिकेशन में गड़बड़ी की लॉगिंग की सुविधा चालू करने का तरीका बताया गया है. इससे, Chat ऐप्लिकेशन की टेस्टिंग के दौरान, Google Cloud Logs Explorer में गड़बड़ी के लॉग देखे जा सकते हैं और उनसे जुड़े सवाल पूछे जा सकते हैं.
ज़रूरी शर्तें
Chat ऐप्लिकेशन में गड़बड़ी की जानकारी लॉग करने की सुविधा चालू करने के लिए, आपको इनकी ज़रूरत होगी:
- Google Workspace खाता, जिससे Google Chat को ऐक्सेस किया जा सकता हो.
- Chat ऐप्लिकेशन. Chat ऐप्लिकेशन बनाने के लिए, यह क्विकस्टार्ट गाइड पढ़ें.
एनवायरमेंट सेट अप करना
Chat ऐप्लिकेशन के गड़बड़ी लॉग के बारे में क्वेरी करने से पहले, आपको Chat ऐप्लिकेशन के Google Cloud प्रोजेक्ट में Cloud Logging API चालू करना होगा.
Google Cloud Console में, Cloud Logging API चालू करें. मेन्यू
menu
> एपीआई और सेवाएं
> लाइब्रेरी पर क्लिक करें.
> Cloud Logging API खोजें
> Cloud Logging API पर क्लिक करें
> चालू करें पर क्लिक करें.
एपीआई चालू करना
गड़बड़ी की जानकारी लॉग करने की सुविधा चालू करना
गड़बड़ी की लॉगिंग की सुविधा चालू करें. जब Chat ऐप्लिकेशन कोई गड़बड़ी दिखाता है, तो यह उसे Cloud Logging में लॉग करता है. Cloud Logging के लिए शुल्क लगता है. इसलिए, समस्या हल करने के बाद, गड़बड़ी की लॉगिंग की सुविधा बंद करें.
Google Cloud Console में, Chat API के कॉन्फ़िगरेशन पेज पर जाएं. मेन्यू
menu
> ज़्यादा प्रॉडक्ट
> Google Workspace
> प्रॉडक्ट लाइब्रेरी
> Google Chat API
> मैनेज करें
> कॉन्फ़िगरेशन पर क्लिक करें.
Chat API पर जाएं
फ़ंक्शन सेक्शन में जाकर, Cloud Logging में गड़बड़ियों को लॉग करें को चुनें.
सेव करें पर क्लिक करें.
अब जब भी Chat ऐप्लिकेशन में कोई गड़बड़ी होती है, तो गड़बड़ी की जानकारी Cloud Logging में लॉग हो जाती है.
गड़बड़ी की जानकारी लॉग करने की सुविधा बंद करना
Cloud Logging के लिए शुल्क लगता है. इसलिए, हो सकता है कि आपको गड़बड़ी की लॉगिंग की सुविधा बंद करनी हो.
Google Cloud Console में, Chat API के कॉन्फ़िगरेशन पेज पर जाएं. मेन्यू
menu
> ज़्यादा प्रॉडक्ट
> Google Workspace
> प्रॉडक्ट लाइब्रेरी
> Google Chat API
> मैनेज करें
> कॉन्फ़िगरेशन पर क्लिक करें.
Chat API पर जाएं
फ़ंक्शन सेक्शन में जाकर, Log errors to Cloud Logging से चुने का निशान हटाएं.
सेव करें पर क्लिक करें.
अब जब भी Chat ऐप्लिकेशन में कोई गड़बड़ी होती है, तो गड़बड़ी को Cloud Logging में लॉग नहीं किया जाता है. लॉग एक्सप्लोरर का इस्तेमाल करके, गड़बड़ी के पिछले लॉग के बारे में क्वेरी की जा सकती है.
गड़बड़ी के लॉगिंग की सुविधा चालू करने के बाद, Chat ऐप्लिकेशन के लिए गड़बड़ी के लॉग क्वेरी किए जा सकते हैं.
जब तक कुछ अलग से न बताया जाए, तब तक इस पेज की सामग्री को Creative Commons Attribution 4.0 License के तहत और कोड के नमूनों को Apache 2.0 License के तहत लाइसेंस मिला है. ज़्यादा जानकारी के लिए, Google Developers साइट नीतियां देखें. Oracle और/या इससे जुड़ी हुई कंपनियों का, Java एक रजिस्टर किया हुआ ट्रेडमार्क है.
आखिरी बार 2025-08-04 (UTC) को अपडेट किया गया.
[null,null,["आखिरी बार 2025-08-04 (UTC) को अपडेट किया गया."],[[["\u003cp\u003eThis guide explains how to enable error logging for your Google Chat app, allowing you to view and analyze errors in Google Cloud Logs Explorer.\u003c/p\u003e\n"],["\u003cp\u003eTo enable error logging, you need a Google Workspace account, a Chat app, and the Cloud Logging API enabled in your Google Cloud project.\u003c/p\u003e\n"],["\u003cp\u003eWhen enabled, Chat app errors are logged to Cloud Logging, which may incur costs; you can disable logging after troubleshooting.\u003c/p\u003e\n"],["\u003cp\u003eYou can turn off error logging to avoid incurring costs from Cloud Logging, but you can still query past logs.\u003c/p\u003e\n"]]],["To enable Chat app error logging, first enable the Cloud Logging API in the Google Cloud console. Then, navigate to the Chat API configuration page and under Functionality, select \"Log errors to Cloud Logging,\" and save. Errors are now logged to Cloud Logging. To disable, deselect \"Log errors to Cloud Logging\" and save. Remember to disable it when troubleshooting is complete, as Cloud Logging incurs a cost. Error logs can be viewed in Google Cloud Logs Explorer.\n"],null,["This page describes how to turn on Chat app error logging, so that you can query and view error logs in [Google Cloud Logs Explorer](https://cloud.google.com/logging/docs/view/logs-viewer-interface) while testing your Chat app.\n\nPrerequisites\n\nTo turn on Chat app error logging, you need:\n\n- A Google Workspace account with access to Google Chat.\n- A Chat app. To build a Chat app, follow this [quickstart](/workspace/chat/quickstart/gcf-app).\n\nSet up the environment\n\nBefore querying Chat app error logs, you must enable the Cloud Logging API in the Chat app's Google Cloud project.\n\n1. In the Google Cloud console, turn on the Cloud Logging API. Click **Menu**\n menu\n \\\u003e **APIs \\& Services**\n \\\u003e **Library** .\n \\\u003e search for **Cloud Logging API**\n \\\u003e click **Cloud Logging API**\n \\\u003e **Enable**.\n\n [Enable the API](https://console.cloud.google.com/marketplace/product/google/logging.googleapis.com)\n\nTurn on error logging\n\nTurn on error logging and when a Chat app returns an error, it logs it to Cloud logging. Because Cloud Logging [incurs a cost](https://cloud.google.com/stackdriver/pricing), you might want to [turn off error logging](#turn-off-error-logging) after you finish troubleshooting.\n\n1. In the Google Cloud console, go to the Chat API **configuration** page. Click **Menu**\n menu\n \\\u003e **More products**\n \\\u003e **Google Workspace**\n \\\u003e **Product Library**\n \\\u003e **Google Chat API**\n \\\u003e **Manage**\n \\\u003e **Configuration**.\n\n [Go to Chat API](https://console.cloud.google.com/apis/api/chat.googleapis.com/hangouts-chat)\n2. Under Functionality, select **Log errors to Cloud Logging**.\n\n3. Click **Save**.\n\nNow, whenever the Chat app returns an error, the error gets logged to Cloud Logging.\n\nTurn off error logging\n\nBecause Cloud Logging [incurs a cost](https://cloud.google.com/stackdriver/pricing), you might want to turn off error logging.\n\n1. In the Google Cloud console, go to the Chat API **configuration** page. Click **Menu**\n menu\n \\\u003e **More products**\n \\\u003e **Google Workspace**\n \\\u003e **Product Library**\n \\\u003e **Google Chat API**\n \\\u003e **Manage**\n \\\u003e **Configuration**.\n\n [Go to Chat API](https://console.cloud.google.com/apis/api/chat.googleapis.com/hangouts-chat)\n2. Under Functionality, deselect **Log errors to Cloud Logging**.\n\n3. Click **Save**.\n\nNow, whenever the Chat app returns an error, the error doesn't get logged to Cloud Logging. You can continue to query past error logs using Logs Explorer.\n\nRelated topics\n\nAfter turning on error logging, you're ready to [query error logs](/workspace/chat/query-logs) for your Chat app."]]