Skip to content

Image edit endpoint does not support array input #588

Open
@ryankon

Description

@ryankon

Describe the bug
Per https://platform.openai.com/docs/api-reference/images/createEdit#images-createedit-image, the image edit endpoint supports either a string or an array of files for multiple image edit.

It looks like it currently only supports a string.
https://github.com/alexrudall/ruby-openai/blob/f020cbd5b69d39d24d8ff1b502ad3bb3dae9425c/lib/openai/images.rb#L22C7-L22C74

To Reproduce
Steps to reproduce the behavior:

  1. Hit the image edit endpoint with an array

Expected behavior
The image edit endpoint should accept and process multiple files

Additional context
Passing an array raises:
TypeError (no implicit conversion of Array into String)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions