Filters the image HTML markup to send to the editor when inserting an image.
Parameters
$htmlstring- The image HTML markup to send.
$idint- The attachment ID.
$captionstring- The image caption.
$titlestring- The image title.
$alignstring- The image alignment.
$urlstring- The image source URL.
$sizestring|int[]- Requested image size. Can be any registered image size name, or an array of width and height values in pixels (in that order).
$altstring- The image alternative, or alt, text.
$relstring- The image rel attribute.
Source
$html = apply_filters( 'image_send_to_editor', $html, $id, $caption, $title, $align, $url, $size, $alt, $rel );
Add custom field to media attachment image attribute in post editor