> ## 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.

# Midjourney テキストから画像

> Midjourney AI モデルを使用してテキストから画像を生成します（非同期）

[Midjourney](https://midjourney.com) V7 モデルを使用してテキストからアートスタイルの画像を生成します。

**モデルの特徴:**

* **独自の美学スタイル** - 業界をリードするアート表現力、高い識別性
* **正確なプロンプト理解** - V7 バージョンでテキスト指示の遵守能力が大幅に向上
* **ディテールの完璧な表現** - 人体、手、オブジェクトなどのディテール処理がより自然に
* **豊かなテクスチャ** - 画像のテクスチャがより豊かで、ディテールがより一貫


## OpenAPI

````yaml /ja/openapi.yaml POST /generate/k/mj-txt2img
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/mj-txt2img:
    post:
      tags:
        - public
      summary: Midjourney テキストから画像生成
      description: Midjourney AI モデルを使用してテキストから画像を生成します（非同期）
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/ka.CreateMidjourneyTxt2ImgTaskRequest'
        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'
        '402':
          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.CreateMidjourneyTxt2ImgTaskRequest:
      properties:
        aspectRatio:
          description: アスペクト比（オプション）- 出力アスペクト比
          enum:
            - '1:2'
            - '9:16'
            - '2:3'
            - '3:4'
            - '5:6'
            - '6:5'
            - '4:3'
            - '3:2'
            - '1:1'
            - '16:9'
            - '2:1'
          example: '16:9'
          type: string
        enableTranslation:
          default: false
          description: 翻訳を有効化（オプション、デフォルト false）- 自動翻訳を有効化
          example: false
          type: boolean
        prompt:
          description: プロンプト（必須、最大2000文字）- 生成するテキスト記述
          example: Help me generate a sci-fi themed fighter jet in a beautiful sky
          maxLength: 2000
          minLength: 1
          type: string
        speed:
          description: 速度（オプション）- API生成速度
          enum:
            - relaxed
            - fast
            - turbo
          example: relaxed
          type: string
        stylization:
          description: スタイライゼーション（オプション、範囲 0-1000）- 芸術的スタイルの強度
          example: 1
          maximum: 1000
          minimum: 0
          type: integer
        variety:
          description: 多様性（オプション、範囲 0-100、ステップ5）- コンテンツの多様性
          example: 10
          maximum: 100
          minimum: 0
          type: integer
        version:
          description: バージョン（オプション）- Midjourneyモデルバージョン
          enum:
            - '7'
            - '6.1'
            - '6'
            - '5.2'
            - '5.1'
            - niji6
          example: '7'
          type: string
        waterMark:
          description: ウォーターマーク（オプション）- ウォーターマーク識別子
          example: my_watermark
          type: string
        weirdness:
          description: 奇妙さ（オプション、範囲 0-3000）- 創造的な独自性
          example: 1
          maximum: 3000
          minimum: 0
          type: integer
      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を使用して認証を行ってください

````