A helper extension for Google Gemini API operations in VS Code.
[!IMPORTANT]
Early Access: This extension is currently in Alpha. Features may change, and you may encounter bugs. Please report any issues on the GitHub repository.
Features
📁 Files API Management
List Files: View all your uploaded files in a tree view.
Upload Files: Upload files directly from VS Code. Supports automatic MIME type detection and advanced configuration (display name, resource name).
View Metadata: accurate metadata including URI, size, and creation time.
Manage: Copy file names/URIs or delete files directly from the context menu.
⚙️ Batch API Management
Track Jobs: Monitor the status of your batch jobs in real-time.
Job Status Groups: Jobs are automatically grouped by status (Running, Succeeded, Failed, etc.).
Manual Results Download: Download results for succeeded jobs. Configure a default path or choose one on the fly.
Job Management: Cancel running jobs, untrack finished ones, or permanently delete them from the API.
🔒 Secure & Seamless
Secure Storage: Your API Key is stored securely using VS Code's system keychain integration.
Auto-Refresh: Batch job statuses are polled automatically so you always see the latest state.
Getting Started
Installation: Install the extension from the VS Code Marketplace.
Open Extension: Click the sparkle icon (✨) in the Activity Bar to open the Gemini API Helper view.
Set API Key:
Run the command Gemini API Helper: Set Gemini API Key (or click the key icon if available).
Enter your Google Gemini API Key. It will be saved securely.
User Guide
Managing Files
Upload: Click the cloud upload icon in the "Files API" view title. Select a file from your disk. You can choose "Default" for quick upload or "Advanced" to set a custom display name or MIME type.
Copy Info: Right-click any file to copy its Name or URI for use in your API calls.
Delete: Right-click a file and select "Delete" to remove it from the cloud.
Managing Batch Jobs
Track a Job: Click the + (Track) icon in the "Batch API" view. Enter the Job ID (e.g., batches/...).
Monitor: The job will appear in the list, grouped by its status. The view auto-refreshes every 30 seconds.
Download Results: Once a job is marked as SUCCEEDED, right-click it or use the inline download icon to save the results.
Tip: Set geminiApiHelper.batch.defaultDownloadPath in your VS Code settings to skip the folder prompt.
Copy Job ID: Click the copy icon next to any job to copy its ID.
Cleanup: Use Untrack to remove it from your list (keeps it in the cloud) or Delete to permanently remove it.
Configuration
Setting
Description
Example
geminiApiHelper.batch.defaultDownloadPath
Default folder path for saving batch results. Can be absolute or relative to your workspace.
batch-results or /tmp/gemini-results
Disclaimers
Not Affiliated: This extension is in no way affiliated with Google or Gemini.
Not for Profit: This is a not-for-profit project created for educational and utility purposes.
License
This project is licensed under the MIT License.
Contributing
Contribution is welcome! Please feel free to open issues or submit pull requests on the GitHub Repository.