cloud-logging-query-generation

Generates Logging Query Language queries for Google Cloud Logging from natural language.

Updated May 11, 2026
One-click install
npx skills add https://github.com/alon3153/upe-social-publisher --skill cloud-logging-query-generation-alon3153
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: cloud-logging-query-generation
Source: https://github.com/alon3153/upe-social-publisher/tree/main/.agents/skills/cloud-logging-query-generation
Command: npx skills add https://github.com/alon3153/upe-social-publisher --skill cloud-logging-query-generation-alon3153

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve? Writing correct Logging Query Language (LQL) queries for Google Cloud Logging requires knowing exact resource types, log IDs, and payload schemas that vary per service. This Skill converts natural language debugging or auditing requests into syntactically correct LQL queries, avoiding common mistakes like wrong resource types or invalid operators. ## Core Features & Use Cases - Natural language to LQL conversion: Produces raw, ready-to-paste LQL queries with correct syntax rules (double quotes, uppercase boolean operators, explicit parentheses). - Service-specific schemas: Ships reference files for 20+ Google Cloud services including GKE, Compute Engine, BigQuery, Cloud Run, Cloud SQL, IAM, and audit logs, ensuring accurate resource.type and log_id values. - Safe placeholder handling: Omits non-essential filters when identifiers are missing and inserts angle-bracket placeholders only for strictly required variables. - Use Case: Ask for "error logs from my Cloud Run service yesterday" or "who deleted my GCE instance" and receive a precise query targeting the right resource type, log ID, and protoPayload fields. ## Quick Start Ask the assistant to generate a Cloud Logging query for your scenario, for example: write an LQL query that finds all 5xx errors from my App Engine service in the last 24 hours.

Frequently Asked Questions about cloud-logging-query-generation

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I write a Google Cloud Logging query from plain English?▼

Describe the logs you need in natural language, including the service, severity, and time range. The skill generates a raw LQL query with the correct resource.type, log_id, and filters, ready to paste into the Cloud Logging Logs Explorer.

How do I filter Cloud Logging by resource type and log ID?▼

Use resource.type with the service-specific value (for example, k8s_container or gce_instance) and the log_id() function for the log stream. The skill's reference files list the correct values per Google Cloud service so you do not have to guess.

Does this skill work for querying Cloud SQL or BigQuery data?▼

No. It only generates Logging Query Language for Google Cloud Logging log data, including Cloud SQL engine logs and BigQuery audit logs. It does not query the databases themselves with SQL.

Why does my LQL query return no results for a GCE instance name?▼

For gce_instance resources, instance IDs are numeric and instance names are strings, so comparing a name against instance_id fails. Search by name with SEARCH("my-instance") or use resource.labels.instance_name when available.

What happens when the exact log schema is unknown?▼

The skill falls back to a global keyword search using the SEARCH() function scoped to the correct resource.type, and adds a mandatory LQL comment noting the schema was not found in its references. It avoids guessing jsonPayload or protoPayload field names.