buildWithAttachments

Builds and returns both the text content and media attachments.

This method combines the text content built through the inherited TextContentBuilder methods with any media attachments configured through the attachments method.

Return

A Pair containing the built text content as the first element and the list of media attachments as the second element