NanoBanana is LinkrAPI's credits-based image generation provider powered by Google AI Studio (Gemini Flash Image). Unlike the Midjourney integration, NanoBanana does not require a Discord account — just credit balance and your lkr_nb_xxx API key.
💡 Same endpoint, different key. NanoBanana uses the same POST /v1/imagine endpoint as Midjourney. The routing is automatic: send your lkr_nb_xxx Global NanoBanana Key instead of a hold key, and the request is routed to Google Gemini.
Authentication
NanoBanana uses a Global NanoBanana API Key — separate from your hold keys. This key starts with lkr_nb_ and applies to your whole account, not a specific hold.
Find, generate, and copy your key on the Settings page. Pass it as a Bearer token:
Authorization: Bearer lkr_nb_your_key_here
Credits & Pricing
NanoBanana generation is charged in credits. The cost depends on your image count setting, which you configure once in the Settings page (nanobanana_image_count). It is not a per-request API parameter.
image_count Setting
Output
Credits per Request
1 (Single)
1 image, direct URL
4 credits
4 (Grid)
2×2 grid image, single URL
16 credits
💰 Credit rate: 100 credits = $1.00 USD. Deposit credits on the Billing page.
Supported Aspect Ratios
NanoBanana supports the following aspect ratios. Include them in your prompt with --ar as you would for Midjourney — LinkrAPI parses the flag and passes the correct ratio to Google Gemini.
ℹ️ Unsupported or unrecognized aspect ratios default to 1:1.
⚠️ Prompt Flag Stripping
NanoBanana automatically strips the following Midjourney-specific flags from your prompt before sending it to Google Gemini:
--ar--aspect--fast--relax--turbo--seed--sameseed
Other flags like --v, --style, and --chaos are passed as plain text to the model description — they won't affect Gemini's output, but they won't cause errors either. For best results with NanoBanana, write plain descriptive prompts without Midjourney-specific flags.
Example Request
cURL
curl -X POST https://linkrapi.com/api/v1/imagine \
-H "Authorization: Bearer lkr_nb_your_key" \
-H "Content-Type: application/json" \
-d '{
"prompt": "a futuristic city at sunset --ar 16:9",
"webhook_url": "https://your-server.com/webhook"
}'
URL of the first generated image (or only image in 1-image mode).
images
array
Array of individual image URLs. For 4-image mode: 4 URLs (_1.png to _4.png). For 1-image mode: 1 URL.
grid_url
string
URL of the 2×2 composite grid image. Null in 1-image mode.
cdn_url
string
Alias for image_url. Kept for backwards compatibility.
components
null
Always null for NanoBanana. Upscale and variation actions are not supported.
⚠️ No /v1/action Support
NanoBanana tasks do not support POST /v1/action. The components field in the fetch response will always be null. If you need upscale or variation actions, use the Midjourney integration with a hold key instead.
Status Codes
200Task submitted successfully. Poll /v1/fetch/{task_id} for the result.
400Invalid request — prompt is empty, missing, or image_count setting is invalid.
401Invalid or missing NanoBanana API key (must start with lkr_nb_).
402Insufficient credits. Response includes required vs. available credit balance.
💡 Typical Workflow
1. Call POST /v1/imagine with your lkr_nb_xxx key → get task_id 2. Poll GET /v1/fetch/{task_id} every 5 seconds 3. When status is completed, use the image_url
NanoBanana generation is typically faster than Midjourney: 10–30 seconds in most cases. You can also pass a webhook_url to receive an instant POST callback instead of polling.