Skip to content

Latest commit

 

History

History

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 
 
 
 
 
 
 

README.md

Midjourney Ruby SDK for RunAPI

Use runapi-midjourney for Midjourney image generation, editing, image-to-video, first-video extension, image-to-prompt, prompt shortening, and seed lookup in Ruby applications and workers.

Install

gem install runapi-midjourney

Quick Start

require "runapi/midjourney"

client = RunApi::Midjourney::Client.new
result = client.text_to_image.run(
  model: "midjourney-v8.1",
  prompt: "A cobalt blue ceramic vase on white marble"
)
puts result.images.first.url

Use create, get, and run for text_to_image, edit_image, image_to_video, and extend_video. extend_video accepts the task ID of an account-owned completed direct image-to-video task and continues its first video; extension tasks cannot be chained. Use run directly for image_to_prompt, shorten_prompt, and get_seed. Generated media URLs are temporary and should be stored in durable storage.

Links

Licensed under the Apache License, Version 2.0.