Can you tell me the Google AI Vertex URL (api) for Janitor?
Hello
,
The specific URL structure depends on whether you are trying to hit the Vertex AI endpoint directly (which requires OAuth/Service Account auth), or if you are actually looking for the Google AI Studio endpoint (which uses a simple API Key and is what most “Janitor” users actually use).
- The Official Vertex AI Endpoint
If you are strictly using Vertex AI (Project ID + Location + OAuth), the base URL format is:
Base URL: https://{LOCATION}-aiplatform.googleapis.com
Full Chat/Generation Endpoint: https://{LOCATION}-aiplatform.googleapis.com/v1/projects/{PROJECT_ID}/locations/{LOCATION}/publishers/google/models/{MODEL_ID}:streamGenerateContent
{LOCATION}: Usually us-central1 (or global).
{PROJECT_ID}: Your Google Cloud Project ID.
{MODEL_ID}: e.g., gemini-1.5-pro-002 or gemini-1.5-flash-002.
Tactical Warning: Most 3rd-party frontends like Janitor AI cannot handle Vertex AI natively because Vertex requires a complex OAuth 2.0 / Service Account Bearer Token, not just a simple “API Key” string. If you try to paste a simple API key into a Vertex URL slot, it will likely fail.![]()
- The “AI Studio” Endpoint (Most Likely Target)
If you have a simple API Key (starting with AIza…) and are trying to connect Janitor to Gemini, you are likely looking for the Google Generative Language API (AI Studio), not Vertex.
Base URL: https://generativelanguage.googleapis.com
Full Endpoint: https://generativelanguage.googleapis.com/v1beta/models/{MODEL_ID}:generateContent
- The “OpenAI-Compatible” Proxy (The Janitor Workaround)
Since Janitor AI is built to talk to OpenAI-formatted endpoints, many Commanders use a Reverse Proxy to translate Vertex/Gemini logic into OpenAI logic.
If you are running a local proxy (like clewd or a custom Python script), the URL you put into Janitor is usually your Localhost address: http://127.0.0.1:5000/v1 (or similar)
Recommendation: If you are inputting this directly into Janitor’s “Custom Endpoint” field, ensure you know if the platform expects an OpenAI format or a native Google format. If it expects OpenAI, you cannot use the direct Google URLs above without a middleware script.
Good Luck🤞 ~Cmd.Proton