Class MessageImageUrlParam

java.lang.Object
com.azure.ai.agents.persistent.models.MessageImageUrlParam
All Implemented Interfaces:
com.azure.json.JsonSerializable<MessageImageUrlParam>

public final class MessageImageUrlParam extends Object implements com.azure.json.JsonSerializable<MessageImageUrlParam>
Defines how an external image URL is referenced when creating an image-URL block.
  • Constructor Details

    • MessageImageUrlParam

      public MessageImageUrlParam(String url)
      Creates an instance of MessageImageUrlParam class.
      Parameters:
      url - the url value to set.
  • Method Details

    • getUrl

      public String getUrl()
      Get the url property: The publicly accessible URL of the external image.
      Returns:
      the url value.
    • getDetail

      public ImageDetailLevel getDetail()
      Get the detail property: Optional detail level for the image (auto, low, or high). Defaults to 'auto' if not specified.
      Returns:
      the detail value.
    • setDetail

      public MessageImageUrlParam setDetail(ImageDetailLevel detail)
      Set the detail property: Optional detail level for the image (auto, low, or high). Defaults to 'auto' if not specified.
      Parameters:
      detail - the detail value to set.
      Returns:
      the MessageImageUrlParam object itself.
    • toJson

      public com.azure.json.JsonWriter toJson(com.azure.json.JsonWriter jsonWriter) throws IOException
      Specified by:
      toJson in interface com.azure.json.JsonSerializable<MessageImageUrlParam>
      Throws:
      IOException
    • fromJson

      public static MessageImageUrlParam fromJson(com.azure.json.JsonReader jsonReader) throws IOException
      Reads an instance of MessageImageUrlParam from the JsonReader.
      Parameters:
      jsonReader - The JsonReader being read.
      Returns:
      An instance of MessageImageUrlParam if the JsonReader was pointing to an instance of it, or null if it was pointing to JSON null.
      Throws:
      IllegalStateException - If the deserialized JSON object was missing any required properties.
      IOException - If an error occurs while reading the MessageImageUrlParam.