> ## Documentation Index
> Fetch the complete documentation index at: https://docs.sinancode.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Nano Banana テキストから画像

> Nano Banana モデルを使用して画像を生成します（非同期）

[Google DeepMind](https://deepmind.google) の Nano Banana (Gemini 2.5 Flash) モデルを使用してテキストから画像を生成します。

**モデルの特徴:**

* **高速生成** - Gemini 2.5 Flash ベースで高速生成
* **コストパフォーマンス** - 低コストで大量生成に最適
* **1K 解像度** - 最大 1024x1024 ピクセル出力をサポート
* **優れた理解力** - Gemini の意味理解と推論能力を継承


## OpenAPI

````yaml /ja/openapi.yaml POST /generate/k/nano-banana
openapi: 3.0.0
info:
  contact:
    email: support@sinancode.com
    name: API Support
    url: https://sinancode.com/support
  description: AIモデルタスクスケジューリングプラットフォーム API
  license:
    name: MIT
    url: https://opensource.org/licenses/MIT
  termsOfService: https://sinancode.com/terms-of-service
  title: TikTomato API
  version: '1.0'
servers:
  - url: https://api.sinancode.com/v1
    description: 本番サーバー
security: []
paths:
  /generate/k/nano-banana:
    post:
      tags:
        - public
      summary: Nano Banana 画像生成
      description: Nano Banana モデルを使用して画像を生成します（非同期）
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/ka.CreateNanoBananaTaskRequest'
        description: タスクパラメータ
        required: true
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/dto.CreateTaskResponse'
        '400':
          description: 無効なパラメータ
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/apierror.ErrorResponse'
        '401':
          description: 認証エラー
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/apierror.ErrorResponse'
        '500':
          description: サーバーエラー
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/apierror.ErrorResponse'
      security:
        - AccessToken: []
components:
  schemas:
    ka.CreateNanoBananaTaskRequest:
      properties:
        image_size:
          default: '1:1'
          description: 画像サイズ（オプション、デフォルト 1:1）- 画像アスペクト比
          enum:
            - '1:1'
            - '9:16'
            - '16:9'
            - '3:4'
            - '4:3'
            - '3:2'
            - '2:3'
            - '5:4'
            - '4:5'
            - '21:9'
            - auto
          example: '1:1'
          type: string
        output_format:
          description: 出力形式（オプション）- 画像出力形式
          enum:
            - png
            - jpeg
          example: png
          type: string
        prompt:
          description: プロンプト（必須、最大5000文字）- 画像生成のテキスト記述
          example: >-
            A surreal painting of a giant banana floating in space, stars and
            galaxies in the background, vibrant colors, digital art
          maxLength: 5000
          minLength: 1
          type: string
      required:
        - prompt
      type: object
    dto.CreateTaskResponse:
      properties:
        task_id:
          description: タスクID
          example: 01234567-89ab-cdef-0123-456789abcdef
          type: string
      required:
        - task_id
      type: object
    apierror.ErrorResponse:
      properties:
        error_code:
          description: '機械可読なエラーコード（例: TASK.INVALID_PARAMS）'
          type: string
        message:
          description: ユーザーフレンドリーなエラーメッセージ
          type: string
      type: object
  securitySchemes:
    AccessToken:
      type: http
      scheme: bearer
      bearerFormat: JWT
      description: API Tokenを使用して認証を行ってください

````