# Google Cloud Logging

```json
{
  "name": "Google Cloud Logging",
  "slug": "google_cloud_logging",
  "url": "https://composio.dev/toolkits/google_cloud_logging",
  "markdown_url": "https://composio.dev/toolkits/google_cloud_logging.md",
  "logo_url": "https://logos.composio.dev/api/google_cloud_logging",
  "categories": [
    "developer tools & devops"
  ],
  "is_composio_managed": false,
  "updated_at": "2026-11-28T05:34:01.339Z"
}
```

![Google Cloud Logging logo](https://logos.composio.dev/api/google_cloud_logging)

## Description

Securely connect your AI agents and chatbots (Claude, ChatGPT, Cursor, etc) with Google Cloud Logging MCP or direct API to search logs, analyze errors, manage log entries, and configure logging through natural language.

## Summary

Google Cloud Logging is a Google Cloud service for storing, searching, and analyzing resource logs.
It centralizes operational data to simplify monitoring, troubleshooting, and compliance.

## Categories

- developer tools & devops

## Toolkit Details

- Tools: 64

## Images

- Logo: https://logos.composio.dev/api/google_cloud_logging

## Authentication

- **Oauth2**
  - Type: `oauth2`
  - Description: Oauth2 authentication for Google Cloud Logging.
  - Setup:
    - Configure Oauth2 credentials for Google Cloud Logging.
    - Use the credentials when creating an auth config in Composio.

## Suggested Prompts

- Find production errors from the last hour
- Summarize warning logs for my service
- Review recent audit logs for unusual activity

## Supported Tools

| Tool slug | Name | Description |
|---|---|---|
| `GOOGLE_CLOUD_LOGGING_CANCEL_OPERATION` | Cancel Operation | Start best-effort cancellation of a Cloud Logging long-running operation using explicit parent, location, and operation IDs. |
| `GOOGLE_CLOUD_LOGGING_COPY_LOG_ENTRIES` | Copy Log Entries | Start a long-running copy of matching entries from a Cloud Logging log bucket to a Cloud Storage bucket. |
| `GOOGLE_CLOUD_LOGGING_CREATE_EXCLUSION` | Create Exclusion | Create one exclusion under an explicit Google Cloud parent resource. |
| `GOOGLE_CLOUD_LOGGING_CREATE_LOG_BUCKET` | Create Log Bucket | Create a Cloud Logging bucket under an explicit parent and location. |
| `GOOGLE_CLOUD_LOGGING_CREATE_LOG_BUCKET_ASYNC` | Create Log Bucket Asynchronously | Start asynchronous creation of a Cloud Logging bucket under an explicit Google Cloud parent and location. |
| `GOOGLE_CLOUD_LOGGING_CREATE_LOG_LINK` | Create Log Link | Start asynchronous creation of a BigQuery-linked dataset for an explicit Cloud Logging bucket. |
| `GOOGLE_CLOUD_LOGGING_CREATE_LOG_METRIC` | Create Log Metric | Create a logs-based metric in an explicit Google Cloud project. |
| `GOOGLE_CLOUD_LOGGING_CREATE_LOG_SCOPE` | Create Log Scope | Create one log scope under an explicit Google Cloud parent and location. |
| `GOOGLE_CLOUD_LOGGING_CREATE_LOG_VIEW` | Create Log View | Create one view over log entries in an explicit Cloud Logging bucket. |
| `GOOGLE_CLOUD_LOGGING_CREATE_SAVED_QUERY` | Create Saved Query | Create one saved query under an explicit Google Cloud parent and location. |
| `GOOGLE_CLOUD_LOGGING_CREATE_SINK` | Create Sink | Create a Cloud Logging sink under an explicit parent resource. |
| `GOOGLE_CLOUD_LOGGING_DELETE_EXCLUSION` | Delete Exclusion | Delete one Cloud Logging exclusion identified by explicit parent and exclusion IDs. |
| `GOOGLE_CLOUD_LOGGING_DELETE_LOG` | Delete Log | Delete all entries in one log from the global _Default Log Bucket under an explicit project, folder, organization, or billing account. |
| `GOOGLE_CLOUD_LOGGING_DELETE_LOG_BUCKET` | Delete Log Bucket | Delete one Cloud Logging log bucket using explicit parent, location, and bucket identifiers. The bucket enters DELETE_REQUESTED state and is permanently purged after the provider's recovery period. |
| `GOOGLE_CLOUD_LOGGING_DELETE_LOG_LINK` | Delete Log Link | Start asynchronous deletion of one Cloud Logging log link and its corresponding BigQuery linked dataset using explicit resource IDs. |
| `GOOGLE_CLOUD_LOGGING_DELETE_LOG_METRIC` | Delete Log Metric | Delete a project log-based metric using explicit project and metric IDs. |
| `GOOGLE_CLOUD_LOGGING_DELETE_LOG_SCOPE` | Delete Log Scope | Delete one Cloud Logging log scope using explicit parent, location, and log scope identifiers. |
| `GOOGLE_CLOUD_LOGGING_DELETE_LOG_VIEW` | Delete Log View | Delete one Cloud Logging log view using explicit parent, location, bucket, and view identifiers. |
| `GOOGLE_CLOUD_LOGGING_DELETE_SAVED_QUERY` | Delete Saved Query | Delete one Cloud Logging saved query using explicit parent, location, and saved query identifiers. |
| `GOOGLE_CLOUD_LOGGING_DELETE_SINK` | Delete Sink | Delete one Cloud Logging sink under an explicit project, folder, organization, or billing account. If the sink has a unique writer identity, Google also deletes that service account. |
| `GOOGLE_CLOUD_LOGGING_GET_CMEK_SETTINGS` | Get CMEK Settings | Get Cloud Logging CMEK settings for an explicit parent resource. |
| `GOOGLE_CLOUD_LOGGING_GET_EXCLUSION` | Get Exclusion | Get one Cloud Logging exclusion by its explicit parent and resource IDs. |
| `GOOGLE_CLOUD_LOGGING_GET_LOCATION` | Get Location | Get one Logging API location under an explicit Google Cloud parent. |
| `GOOGLE_CLOUD_LOGGING_GET_LOG_BUCKET` | Get Log Bucket | Get one Cloud Logging log bucket using explicit parent, location, and bucket identifiers. |
| `GOOGLE_CLOUD_LOGGING_GET_LOG_LINK` | Get Log Link | Get one Cloud Logging log link using explicit parent and resource IDs. |
| `GOOGLE_CLOUD_LOGGING_GET_LOG_METRIC` | Get Log Metric | Get a project log-based metric using explicit project and metric IDs. |
| `GOOGLE_CLOUD_LOGGING_GET_LOG_SCOPE` | Get Log Scope | Get one log scope by its explicit parent and resource IDs. |
| `GOOGLE_CLOUD_LOGGING_GET_LOG_VIEW` | Get Log View | Get one Cloud Logging log view by its explicit parent and resource IDs. |
| `GOOGLE_CLOUD_LOGGING_GET_LOG_VIEW_IAM_POLICY` | Get Log View IAM Policy | Get the IAM access policy for an explicit Cloud Logging log view. |
| `GOOGLE_CLOUD_LOGGING_GET_OPERATION` | Get Operation | Get the latest state of a Cloud Logging long-running operation using explicit parent, location, and operation IDs. |
| `GOOGLE_CLOUD_LOGGING_GET_SAVED_QUERY` | Get Saved Query | Get one saved query by its explicit parent and resource IDs. |
| `GOOGLE_CLOUD_LOGGING_GET_SETTINGS` | Get Settings | Get Cloud Logging settings for an explicit Google Cloud parent resource. |
| `GOOGLE_CLOUD_LOGGING_GET_SINK` | Get Sink | Get one Cloud Logging sink by its explicit parent and sink IDs. |
| `GOOGLE_CLOUD_LOGGING_LIST_EXCLUSIONS` | List Exclusions | List one page of exclusions on the _Default sink for an explicit Google Cloud project, folder, organization, or billing account. |
| `GOOGLE_CLOUD_LOGGING_LIST_LOCATIONS` | List Locations | List one page of Cloud Logging API locations under an explicit Google Cloud project, folder, organization, or billing account. |
| `GOOGLE_CLOUD_LOGGING_LIST_LOG_BUCKETS` | List Log Buckets | List one page of Cloud Logging buckets in an explicit project, folder, organization, or billing account location. |
| `GOOGLE_CLOUD_LOGGING_LIST_LOG_ENTRIES` | List Or Poll Log Entries | List one page of matching Cloud Logging entries, or repeatedly call the same entries.list query for bounded tail-like behavior without using entries.tail. |
| `GOOGLE_CLOUD_LOGGING_LIST_LOG_LINKS` | List Log Links | List one page of Cloud Logging links for an explicit project, folder, organization, or billing account log bucket. |
| `GOOGLE_CLOUD_LOGGING_LIST_LOG_METRICS` | List Log Metrics | List one page of logs-based metrics in an explicit Google Cloud project. |
| `GOOGLE_CLOUD_LOGGING_LIST_LOGS` | List Logs | List one page of Cloud Logging log names in an explicit Google Cloud project, folder, organization, or billing account. |
| `GOOGLE_CLOUD_LOGGING_LIST_LOG_SCOPES` | List Log Scopes | List one page of Cloud Logging log scopes in an explicit project, folder, or organization location. |
| `GOOGLE_CLOUD_LOGGING_LIST_LOG_VIEWS` | List Log Views | List one page of Cloud Logging views for an explicit project, folder, organization, or billing account log bucket. |
| `GOOGLE_CLOUD_LOGGING_LIST_MONITORED_RESOURCE_DESCRIPTORS` | List Monitored Resource Descriptors | List one page of monitored resource descriptor types available to Google Cloud Logging. |
| `GOOGLE_CLOUD_LOGGING_LIST_OPERATIONS` | List Operations | List one page of Cloud Logging long-running operations for an explicit Google Cloud parent and location. |
| `GOOGLE_CLOUD_LOGGING_LIST_RECENT_QUERIES` | List Recent Queries | List one page of queries run by the current user in the last approximately 30 days for an explicit Google Cloud parent and Logging location. |
| `GOOGLE_CLOUD_LOGGING_LIST_SAVED_QUERIES` | List Saved Queries | List one page of Cloud Logging saved queries in an explicit project, folder, organization, or billing account location. |
| `GOOGLE_CLOUD_LOGGING_LIST_SINKS` | List Sinks | List one page of Cloud Logging sinks for an explicit project, folder, organization, or billing account. |
| `GOOGLE_CLOUD_LOGGING_LIST_VIEW_LOGS` | List View Logs | List one page of Cloud Logging log names visible through an explicit log view. |
| `GOOGLE_CLOUD_LOGGING_PATCH_SINK` | Patch Sink | Patch selected fields of one Cloud Logging sink under an explicit project, folder, organization, or billing account. |
| `GOOGLE_CLOUD_LOGGING_REPLACE_SINK` | Replace Sink | Replace a Cloud Logging sink under an explicit Google Cloud parent. |
| `GOOGLE_CLOUD_LOGGING_SET_LOG_VIEW_IAM_POLICY` | Set Log View IAM Policy | Replace the IAM policy on one Cloud Logging log view under an explicit project, folder, or organization resource. |
| `GOOGLE_CLOUD_LOGGING_TAIL_LOG_ENTRIES` | Tail Log Entries With Bounded List Polling | Safely emulate the documented Cloud Logging entries.tail operation with finite entries.list polling from a receive timestamp captured when the action starts. Mercury's buffered unary transport cannot consume the bidirectional tail stream or preserve partial stream messages, so this action never dispatches entries:tail or returns older matching history. It returns matching entries in ascending timestamp order, a page cursor, and whether the bounded polling window expired. |
| `GOOGLE_CLOUD_LOGGING_TEST_LOG_VIEW_IAM_PERMISSIONS` | Test Log View IAM Permissions | Return the requested IAM permissions the caller has on an explicit Cloud Logging log view. Do not use this fail-open API for authorization checks. |
| `GOOGLE_CLOUD_LOGGING_UNDELETE_LOG_BUCKET` | Undelete Log Bucket | Restore a Cloud Logging bucket within its seven-day deletion grace period using explicit parent, location, and bucket IDs. |
| `GOOGLE_CLOUD_LOGGING_UPDATE_CMEK_SETTINGS` | Update CMEK Settings | Patch Cloud Logging CMEK settings for a Google Cloud organization. |
| `GOOGLE_CLOUD_LOGGING_UPDATE_EXCLUSION` | Update Exclusion | Patch selected fields of one Cloud Logging exclusion under an explicit Google Cloud parent resource. |
| `GOOGLE_CLOUD_LOGGING_UPDATE_LOG_BUCKET` | Update Log Bucket | Synchronously patch selected fields of a Cloud Logging bucket under an explicit parent and location. |
| `GOOGLE_CLOUD_LOGGING_UPDATE_LOG_BUCKET_ASYNC` | Update Log Bucket Asynchronously | Start an asynchronous update of selected fields on a Cloud Logging bucket under an explicit parent and location. |
| `GOOGLE_CLOUD_LOGGING_UPDATE_LOG_METRIC` | Update Log Metric | Update a project log-based metric using explicit project and metric IDs. |
| `GOOGLE_CLOUD_LOGGING_UPDATE_LOG_SCOPE` | Update Log Scope | Patch selected fields of one Cloud Logging log scope under an explicit project, folder, or organization. |
| `GOOGLE_CLOUD_LOGGING_UPDATE_LOG_VIEW` | Update Log View | Patch selected fields of one Cloud Logging log view under an explicit parent, location, and bucket. |
| `GOOGLE_CLOUD_LOGGING_UPDATE_SAVED_QUERY` | Update Saved Query | Patch selected fields of one Cloud Logging saved query under an explicit parent and location; update_mask controls which supplied values change. |
| `GOOGLE_CLOUD_LOGGING_UPDATE_SETTINGS` | Update Settings | Patch Cloud Logging settings for an explicit folder or organization. |
| `GOOGLE_CLOUD_LOGGING_WRITE_LOG_ENTRIES` | Write Log Entries | Write a batch of log entries to Google Cloud Logging. |

## Supported Triggers

None listed.

## Installation and MCP Setup

### Path 1: SDK Installation

#### Path 1, Step 1: Install Composio

Install the Composio SDK, the OpenAI provider, and the OpenAI SDK
```python
pip install composio composio_openai openai
```

```typescript
npm install @composio/core @composio/openai openai
```

#### Path 1, Step 2: Create a Composio session

Initialize Composio with the OpenAI Responses provider and create a session scoped to Google Cloud Logging
```python
import json
from openai import OpenAI
from composio import Composio
from composio_openai import OpenAIResponsesProvider

composio = Composio(provider=OpenAIResponsesProvider())
client = OpenAI()

session = composio.create(user_id="your-user-id", toolkits=["google_cloud_logging"])
tools = session.tools()
```

```typescript
import OpenAI from "openai";
import { Composio } from "@composio/core";
import { OpenAIResponsesProvider } from "@composio/openai";

const composio = new Composio({ provider: new OpenAIResponsesProvider() });
const client = new OpenAI();

const session = await composio.create("your-user-id", { toolkits: ["google_cloud_logging"] });
const tools = await session.tools();
```

#### Path 1, Step 3: Run Google Cloud Logging tools with your agent

Send a request, execute the Google Cloud Logging tool calls through the session, and print the final answer
```python
response = client.responses.create(
    model="gpt-5.6-sol",
    tools=tools,
    input=[{"role": "user", "content": "Search Google Cloud Logging for ERROR entries from the last hour in my production project."}],
)

while True:
    tool_calls = [o for o in response.output if o.type == "function_call"]
    if not tool_calls:
        break
    results = composio.provider.handle_tool_calls(response=response, session=session)
    response = client.responses.create(
        model="gpt-5.6-sol",
        tools=tools,
        previous_response_id=response.id,
        input=[
            {"type": "function_call_output", "call_id": call.call_id, "output": json.dumps(results[i])}
            for i, call in enumerate(tool_calls)
        ],
    )

print(response.output_text)
```

```typescript
let response = await client.responses.create({
  model: "gpt-5.6-sol",
  tools,
  input: [{ role: "user", content: "Search Google Cloud Logging for ERROR entries from the last hour in my production project." }],
});

while (response.output.some((o) => o.type === "function_call")) {
  const outputs = await composio.provider.handleToolCalls(session, response.output);
  response = await client.responses.create({
    model: "gpt-5.6-sol",
    tools,
    previous_response_id: response.id,
    input: outputs,
  });
}

console.log(response.output_text);
```

### Path 2: MCP Server Setup

#### Path 2, Step 1: Install Composio

Install the Composio SDK and your agent framework
```python
pip install composio claude-agent-sdk
```

```typescript
npm install @composio/core ai @ai-sdk/mcp @ai-sdk/openai
```

#### Path 2, Step 2: Create a session with MCP enabled

Create a session scoped to Google Cloud Logging and read its MCP URL and headers
```python
from composio import Composio

composio = Composio()
session = composio.create(user_id="your-user-id", toolkits=["google_cloud_logging"], mcp=True)
```

```typescript
import { Composio } from "@composio/core";

const composio = new Composio();
const { mcp } = await composio.create("your-user-id", {
  toolkits: ["google_cloud_logging"],
  mcp: true,
});
```

#### Path 2, Step 3: Connect your agent to the MCP server

Pass the session's MCP URL and headers to your agent and run a Google Cloud Logging request
```python
import asyncio
from claude_agent_sdk import ClaudeSDKClient, ClaudeAgentOptions, AssistantMessage, TextBlock

options = ClaudeAgentOptions(
    mcp_servers={
        "composio": {
            "type": "http",
            "url": session.mcp.url,
            "headers": session.mcp.headers,
        }
    },
    system_prompt="You are a helpful assistant with access to Google Cloud Logging tools.",
    tools=[],
    allowed_tools=["mcp__composio__*"],
)

async def main():
    async with ClaudeSDKClient(options=options) as client:
        await client.query("Search Google Cloud Logging for ERROR entries from the last hour in my production project.")
        async for message in client.receive_response():
            if isinstance(message, AssistantMessage):
                for block in message.content:
                    if isinstance(block, TextBlock):
                        print(block.text)

asyncio.run(main())
```

```typescript
import { createMCPClient } from "@ai-sdk/mcp";
import { openai } from "@ai-sdk/openai";
import { generateText, stepCountIs } from "ai";

const client = await createMCPClient({
  transport: { type: "http", url: mcp.url, headers: mcp.headers },
});

const { text } = await generateText({
  model: openai("gpt-5.6-sol"),
  tools: await client.tools(),
  prompt: "Search Google Cloud Logging for ERROR entries from the last hour in my production project.",
  stopWhen: stepCountIs(10),
});

console.log(text);
await client.close();
```

## Why Use Composio?

### 1. AI Native Google Cloud Logging Integration

- Supports both Google Cloud Logging MCP and direct API based integrations
- Structured, LLM-friendly schemas for reliable tool execution
- Rich coverage for reading, writing, and querying your Google Cloud Logging data

### 2. Managed Auth

- Built-in OAuth handling with automatic token refresh and rotation
- Central place to manage, scope, and revoke Google Cloud Logging access
- Per user and per environment credentials instead of hard-coded keys

### 3. Agent Optimized Design

- Tools are tuned using real error and success rates to improve reliability over time
- Comprehensive execution logs so you always know what ran, when, and on whose behalf

### 4. Enterprise Grade Security

- Fine-grained RBAC so you control which agents and users can access Google Cloud Logging
- Scoped, least privilege access to Google Cloud Logging resources
- Full audit trail of agent actions to support review and compliance

## Use Google Cloud Logging with any AI Agent Framework

Choose a framework you want to connect Google Cloud Logging with:

- [ChatGPT](https://composio.dev/toolkits/google_cloud_logging/framework/chatgpt)
- [Claude Cowork](https://composio.dev/toolkits/google_cloud_logging/framework/claude-cowork)

## Related Toolkits

- [Supabase](https://composio.dev/toolkits/supabase) - Supabase is an open-source backend platform offering scalable Postgres databases, authentication, storage, and real-time APIs. It lets developers build modern apps without managing infrastructure.
- [Codeinterpreter](https://composio.dev/toolkits/codeinterpreter) - Codeinterpreter is a Python-based coding environment with built-in data analysis and visualization. It lets you instantly run scripts, plot results, and prototype solutions inside supported platforms.
- [GitHub](https://composio.dev/toolkits/github) - GitHub is a code hosting platform for version control and collaborative software development. It streamlines project management, code review, and team workflows in one place.
- [1password](https://composio.dev/toolkits/_1password) - 1Password is a password manager and digital vault for storing logins, secrets, notes, and secure documents. It helps individuals and teams protect credentials, share access safely, and reduce password risk.
- [21st MCP](https://composio.dev/toolkits/21st_mcp) - 21st MCP is a hosted design resource service for React/shadcn components, themes, templates, and SVG logos. It gives teams a fast way to discover, organize, and reuse polished interface assets.
- [Ably](https://composio.dev/toolkits/ably) - Ably is a real-time messaging platform for live chat and data sync in modern apps. It offers global scale and rock-solid reliability for seamless, instant experiences.
- [Abuselpdb](https://composio.dev/toolkits/abuselpdb) - Abuselpdb is a central database for reporting and checking IPs linked to malicious online activity. Use it to quickly identify and report suspicious or abusive IP addresses.
- [Agent37](https://composio.dev/toolkits/agent37) - Agent37 is a control API for managed agent sandboxes, templates, networking, and execution. It gives teams built-in scheduling, observability, budgets, and workspace administration.
- [Aikido Security](https://composio.dev/toolkits/aikido) - Aikido Security is a security platform for workspace, code, cloud, and application protection. It helps teams find vulnerabilities, manage compliance, and reduce security risk.
- [Alchemy](https://composio.dev/toolkits/alchemy) - Alchemy is a blockchain development platform offering APIs and tools for Ethereum apps. It simplifies building and scaling Web3 projects with robust infrastructure.
- [Algolia](https://composio.dev/toolkits/algolia) - Algolia is a hosted search API that powers lightning-fast, relevant search experiences for web and mobile apps. It helps developers deliver instant, typo-tolerant, and scalable search without complex infrastructure.
- [Anakin](https://composio.dev/toolkits/anakin_io) - Anakin is a web automation platform offering scraping, crawling, search, and browser automation. Use it to extract structured data, automate site tasks, and monitor web changes reliably.
- [Anchor browser](https://composio.dev/toolkits/anchor_browser) - Anchor browser is a developer platform for AI-powered web automation. It transforms complex browser actions into easy API endpoints for streamlined web interaction.
- [Anchor Browser MCP](https://composio.dev/toolkits/anchor_browser_mcp) - Anchor Browser MCP is a hosted browser automation service for running cloud browser sessions and web tasks. It provides secure, reusable browser identities and managed authentication for reliable agent workflows.
- [AnyAPI](https://composio.dev/toolkits/anyapi) - AnyAPI is a marketplace of utility APIs for validation, currency conversion, holidays, documents, and web data. It brings common application workflows together through one practical API platform.
- [Apiflash](https://composio.dev/toolkits/apiflash) - Apiflash is a website screenshot API for programmatically capturing web pages. It delivers high-quality screenshots on demand for automation, monitoring, or reporting.
- [Apiverve](https://composio.dev/toolkits/apiverve) - Apiverve delivers a suite of powerful APIs that simplify integration for developers. It's designed for reliability and scalability so you can build faster, smarter applications without the integration headache.
- [APIVerve MCP](https://composio.dev/toolkits/apiverve_mcp) - APIVerve MCP is a hosted utility API server for lookups, validation, conversion, and data enrichment. It gives developers one MCP connection to access APIVerve's utility APIs.
- [Appcircle](https://composio.dev/toolkits/appcircle) - Appcircle is an enterprise-grade mobile CI/CD platform for building, testing, and publishing mobile apps. It streamlines mobile DevOps so teams ship faster and with more confidence.
- [Appdrag](https://composio.dev/toolkits/appdrag) - Appdrag is a cloud platform for building websites, APIs, and databases with drag-and-drop tools and code editing. It accelerates development and iteration by combining hosting, database management, and low-code features in one place.

## Frequently Asked Questions

### Do I need my own developer credentials to use Google Cloud Logging with Composio?

Yes, Google Cloud Logging requires you to configure your own OAuth credentials. Once set up, Composio handles token storage, refresh, and lifecycle management for you.

### Can I use multiple toolkits together?

Yes! Composio's Tool Router enables agents to use multiple toolkits. [Learn more](https://docs.composio.dev/tool-router/overview).

### Is Composio secure?

Composio is SOC 2 and ISO 27001 compliant with all data encrypted in transit and at rest. [Learn more](https://trust.composio.dev).

### What if the API changes?

Composio maintains and updates all toolkit integrations automatically, so your agents always work with the latest API versions.

---
[See all toolkits](https://composio.dev/toolkits) · [Composio docs](https://docs.composio.dev/llms.txt)
