A comprehensive Postman workspace for exploring, testing, and integrating with Google's Gemini APIs. This workspace provides pre-built collections, environments, tests, documentation, and automation tools to streamline your AI development workflow.
- Visit Google AI Studio
- Create a new API key
- Keep it secure - you'll need it for authentication
- Download this repository
- Open Postman
- Click Import and select the collection files from
collections/ - Import the environment files from
environments/
- Select "Gemini API - Development" environment
- Set your
GEMINI_API_KEYvariable - Run the "API Connectivity Test" to verify setup
- Try text generation requests
- Explore chat and conversation flows
- Test image analysis capabilities
- Generate and review code
postman-gemini-workspace/
├── collections/ # Postman collection files
│ ├── gemini-api-collection.json
│ ├── text-generation.json
│ ├── chat-conversation.json
│ ├── vision-image-analysis.json
│ └── code-generation.json
├── environments/ # Environment configurations
│ ├── development.json
│ ├── production.json
│ └── .env.example
├── tests/ # Test scripts and validation
│ ├── api-validation-tests.js
│ └── collection-tests.json
├── mocks/ # Mock server for local development
│ └── gemini-mock-server.js
├── scripts/ # Automation and utility scripts
│ ├── validate-collections.js
│ ├── start-mock-server.js
│ ├── check-api-updates.js
│ └── update-workspace.js
├── docs/ # Documentation
│ ├── getting-started.md
│ ├── advanced-usage.md
│ └── api-reference.md
└── .github/workflows/ # CI/CD automation
└── update-workspace.yml
| Collection | Requests | Purpose |
|---|---|---|
| Text Generation | 6 | Basic text generation with various parameters |
| Chat & Conversation | 6 | Multi-turn conversations and context management |
| Vision & Image Analysis | 7 | Image understanding and visual Q&A |
| Code Generation | 7 | Programming assistance and code review |
- Complete API Coverage: All major Gemini API endpoints
- Production Ready: Proper error handling and validation
- Multiple Environments: Development and production configurations
- Comprehensive Testing: Built-in test scripts and validation
- Mock Server: Local development without API costs
- Auto-Updates: GitHub Actions for maintenance
- Rich Documentation: Getting started guides and API reference
- Blog post generation
- Creative writing assistance
- Marketing copy creation
- Social media content
- Code generation and completion
- Bug detection and fixing
- Code review and optimization
- Documentation generation
- Content moderation
- Accessibility descriptions
- Visual question answering
- UI/UX analysis
- Customer support bots
- Educational assistants
- Interactive help systems
- Conversational interfaces
| Variable | Description | Example |
|---|---|---|
GEMINI_API_KEY |
Your Google AI Studio API key | AIza... |
base_url |
Gemini API base URL | https://generativelanguage.googleapis.com |
api_version |
API version to use | v1beta |
| Variable | Default | Purpose |
|---|---|---|
model_name |
gemini-1.5-pro |
Default text model |
vision_model_name |
gemini-1.5-pro |
Vision tasks model |
chat_model_name |
gemini-1.5-pro |
Chat model |
code_model_name |
gemini-1.5-pro |
Code generation model |
| Variable | Development | Production |
|---|---|---|
request_timeout |
30000ms | 60000ms |
rate_limit_requests_per_minute |
60 | 300 |
default_temperature |
0.7 | 0.3 |
safety_threshold |
BLOCK_MEDIUM_AND_ABOVE |
BLOCK_LOW_AND_ABOVE |
# Install dependencies
npm install
# Validate collections
npm run validate
# Run API tests
npm run test
# Run tests against production
npm run test:prodStart the local mock server for development:
# Start mock server
npm run mock
# Or use the script directly
node scripts/start-mock-server.js start --daemon --port=3000Set base_url to http://localhost:3000 to use the mock server.
All requests include comprehensive test scripts that validate:
- Response structure and format
- Content quality and relevance
- Error handling and edge cases
- Performance metrics
- Safety ratings
The workspace includes automated maintenance via GitHub Actions:
- Weekly Updates: Checks for new models and API changes
- Security Scanning: Validates for secrets and vulnerabilities
- Performance Monitoring: Benchmarks response times
- Documentation: Auto-generates updated docs
# Check for API updates
node scripts/check-api-updates.js
# Update workspace
node scripts/update-workspace.js
# Validate all collections
node scripts/validate-collections.js- Getting Started Guide - Setup and basic usage
- Advanced Usage - Power user features
- API Reference - Complete parameter reference
{
"contents": [
{
"parts": [{"text": "Explain quantum computing"}]
}
],
"generationConfig": {
"temperature": 0.7,
"maxOutputTokens": 1024
}
}{
"contents": [
{
"parts": [
{"text": "What's in this image?"},
{
"inline_data": {
"mime_type": "image/jpeg",
"data": "base64_image_data"
}
}
]
}
]
}{
"contents": [
{
"role": "user",
"parts": [{"text": "Hello, I need help with Python"}]
},
{
"role": "model",
"parts": [{"text": "I'd be happy to help! What would you like to know?"}]
},
{
"role": "user",
"parts": [{"text": "How do I read a CSV file?"}]
}
]
}- Node.js 18+
- Postman desktop app
- Google AI Studio API key
- Clone this repository
- Install dependencies:
npm install - Copy
.env.exampleto.envand configure - Start mock server:
npm run mock - Import collections into Postman
- Start testing and developing!
- Fork the repository
- Create a feature branch
- Make your changes
- Run tests:
npm test - Submit a pull request
- Use 2 spaces for indentation
- Follow existing patterns in collections
- Include comprehensive test scripts
- Document new features
- Never commit API keys to the repository
- Use environment variables for sensitive data
- Rotate keys regularly
- Use separate keys for development and production
- All requests include safety settings
- Configurable safety thresholds
- Content filtering validation
- Monitoring for sensitive content
This project is licensed under the Apache License 2.0 - see the LICENSE file for details.
- Check the documentation
- Review issues for common problems
- Join the Postman Community
- Visit Google AI documentation
- Check existing issues first
- Provide clear reproduction steps
- Include environment details
- Share relevant collection exports (remove API keys!)
- Google AI team for the Gemini API
- Postman team for the excellent platform
- Open source community for inspiration
- Contributors and testers
- Core Collections: Complete
- Documentation: Complete
- Testing Suite: Complete
- Mock Server: Complete
- CI/CD: Complete
- Ongoing: API updates and maintenance
Ready to explore the power of Gemini AI? Start with the Getting Started Guide and join thousands of developers building the future with AI!
*This workspace is not officially affiliated with Google or Postman. It's a GCOS project to help developers work with Gemini APIs more effectively.

