InAppFileAttachment

Represents a file attachment

Represents a file attachment and inherits from InAppAttachment.

Properties

NameReturn TypeDescription
idStringThe ID of the attachment.
sizeLongThe size of the attachment.
urlURLThe URL of the attachment.
contentTypeStringThe content type of the attachment.

Functions

toJson

Converts the file attachment to a JSONObject.

Syntax: fun toJson(): JSONObject

Return: The JSONObject converted from the file attachment.

Companion Functions

fromJson

Converts a JSONObject to a file attachment.

Syntax: fun fromJson(jsonObject: JSONObject): InAppThread

Return: The file attachment converted from the JSONObject.

Parameters

ParametersTypeDescription
jsonObjectJSONObjectThe JSONObject to convert.