Install
$ agentstack add skill-cuopipyyy-skills-for-agent-gemini-web-image ✓ scanned · ✓ verified, works with Claude Code, Cursor, and more.
Security review
✓ PassedNo issues found. Passed automated security review. · v0.1.0 How review works →
- ✓ Prompt-injection patterns
- ✓ Secret / credential exfiltration
- ✓ Dangerous shell & filesystem operations
- ✓ Untrusted network calls
- ✓ Known-malicious package signatures
What it can access
- ✓ Network access No
- ✓ Filesystem access No
- ✓ Shell / process execution No
- ✓ Environment & secrets No
- ✓ Dynamic code execution No
From automated source analysis of v0.1.0. “Used” means the capability is present in the source — more access means more to trust, not that it’s unsafe.
Verified badge
Passed review? Show it. Paste this badge into your README, it links to the public security report.
Reliability & compatibility
Declared compatibility
Compatibility is declared by the source manifest. End-to-end runtime verification is coming, see below.
We're building live execution health for every listing: tool-call success rate, median latency, uptime, and last-checked timestamps, measured, not self-reported. It isn't live yet, so we don't show numbers we can't stand behind.
How agent discovery & health will work →About
Gemini Web Image
Pure web-based Gemini image generation via reverse-engineered browser login. This skill is image-first. Text mode is only for diagnostics and smoke tests.
Script Directory
Important: All scripts are located in the scripts/ subdirectory of this skill.
Agent Execution Instructions:
- Determine this SKILL.md file's directory path as
{baseDir} - Script path =
{baseDir}/scripts/.ts - Resolve
${BUN_X}runtime: ifbuninstalled →bun; ifnpxavailable →npx -y bun; else suggest installing bun - Replace all
{baseDir}and${BUN_X}in this document with actual values
Script Reference: | Script | Purpose | |--------|---------| | scripts/main.ts | CLI entry point for image generation | | scripts/gemini-webapi/* | TypeScript port of gemini_webapi (GeminiClient, types, utils) |
Consent Check (REQUIRED)
Before first use, verify user consent for reverse-engineered API usage.
Consent file locations:
- macOS:
~/Library/Application Support/gemini-web-image/data/consent.json - Linux:
~/.local/share/gemini-web-image/data/consent.json - Windows:
%APPDATA%\gemini-web-image\data\consent.json
Flow:
- Check if consent file exists with
accepted: trueanddisclaimerVersion: "1.0" - If valid consent exists → print warning with
acceptedAtdate, proceed - If no consent:
- Ask the user explicitly in chat before running the skill, or
- run the CLI in a TTY and accept interactively, or
- pass
--accept-disclaimerfor an explicit non-interactive first run
- Consent file format:
{"version":1,"accepted":true,"acceptedAt":"","disclaimerVersion":"1.0"}
Usage
# Image generation
${BUN_X} {baseDir}/scripts/main.ts --prompt "A cute cat" --image cat.png
${BUN_X} {baseDir}/scripts/main.ts --mode image --prompt "A cute cat" --image cat.png
${BUN_X} {baseDir}/scripts/main.ts --promptfiles system.md content.md --image out.png
${BUN_X} {baseDir}/scripts/main.ts --prompt "A cute cat" --image cat.png --raw-json cat.response.json
# Reference-image variation
${BUN_X} {baseDir}/scripts/main.ts --prompt "Create variation" --reference a.png --image out.png
# Dedicated profile login
${BUN_X} {baseDir}/scripts/main.ts --login
${BUN_X} {baseDir}/scripts/main.ts --login --accept-disclaimer
# Text diagnostics only
${BUN_X} {baseDir}/scripts/main.ts --mode text --prompt "Hello" --json
Options
| Option | Description | |--------|-------------| | --prompt, -p | Prompt text | | --promptfiles | Read prompt from files (concatenated) | | --model, -m | Model: gemini-3-pro (default), gemini-3-flash, gemini-3-flash-thinking, gemini-3.1-pro-preview | | --mode | auto, text, or image. --image implies image mode. | | --image [path] | Output image path. This flag switches the request into image mode. | | --raw-json | Save parsed response JSON for debugging. Defaults to .response.json. | | --reference, --ref | Reference images for variation or image-conditioned requests | | --sessionId | Session ID for advanced multi-turn diagnostics | | --list-sessions | List saved sessions | | --json | Output as JSON | | --login | Refresh cookies, then exit | | --accept-disclaimer | Record consent non-interactively for first use | | --cookie-path | Custom cookie file path | | --profile-dir | Chrome profile directory | | --timeout | Override request timeout | | --no-auto-image-prompt | Disable automatic image-only prompt wrapper | | --quiet-stages | Suppress stderr stage logs |
Models
| Model | Description | |-------|-------------| | gemini-3-pro | Default, latest 3.0 Pro | | gemini-3-flash | Fast, lightweight 3.0 Flash | | gemini-3-flash-thinking | 3.0 Flash with thinking | | gemini-3.1-pro-preview | 3.1 Pro preview (empty header, auto-routed) |
Authentication
First run opens a dedicated Chrome profile for Google and Gemini Web login. Complete Google sign-in and any Gemini onboarding in that browser window. Cookies are cached automatically.
This skill stores its own state only in the gemini-web-image namespace:
- cookie cache and consent under
gemini-web-image/data - dedicated Chrome profile under
gemini-web-image/chrome-profile - chat sessions under
gemini-web-image/data/sessions
It does not reuse legacy baoyu-skills/gemini-web cookies or profile directories.
Supported browsers (auto-detected): Chrome, Chrome Canary/Beta, Chromium, Edge.
Force refresh: --login flag. Override browser: GEMINI_WEB_CHROME_PATH env var.
Environment Variables
| Variable | Description | |----------|-------------| | GEMINI_WEB_DATA_DIR | Data directory | | GEMINI_WEB_COOKIE_PATH | Cookie file path | | GEMINI_WEB_CHROME_PROFILE_DIR | Chrome profile directory | | GEMINI_WEB_CHROME_PATH | Chrome executable path | | GEMINI_WEB_ACCEPT_DISCLAIMER | Set to 1 or true to pre-accept the disclaimer | | HTTP_PROXY, HTTPS_PROXY | Proxy for Google access (set inline with command) |
Sessions
Session files stored in data directory under sessions/.json.
Contains: id, metadata (Gemini chat state), messages array, timestamps.
Upgrade Notes
--imageis treated as a real image mode, not just a save path hint.- Image mode auto-injects an explicit "generate one image" wrapper unless
--no-auto-image-promptis used. - When
--imageis used, the parsed response is also saved to.response.jsonby default, including error details when generation fails after request submission. - Stage logs are printed to stderr for
init,submit,response,debug, andsaveunless--quiet-stagesis used. - If Gemini returns multiple candidates, the first candidate containing an image is selected for saving.
- Profile and cookie state are fully isolated to this skill's own namespace.
Source & license
This open-source skill is cataloged on AgentStack and links to its original source — we do not rehost the code.
- Author: Cuopipyyy
- Source: Cuopipyyy/skillsfor_agent
- License: MIT
Install and usage instructions live in the source repository linked above.
Reviews
No reviews yet, be the first.
Write a review
Versions
- v0.1.0 Imported from the upstream source.