Class AttachmentProperties
public class AttachmentProperties : IHttpSerializable
- Inheritance
-
AttachmentProperties
- Implements
- Derived
- Inherited Members
Constructors
AttachmentProperties(string)
protected AttachmentProperties(string fileName)
Parameters
fileName
stringName of the file (max 1024 characters for attachments sent by message, 2-30 characters for attachments used for sticker creation).
AttachmentProperties(string, Stream)
public AttachmentProperties(string fileName, Stream stream)
Parameters
fileName
stringName of the file (max 1024 characters for attachments sent by message, 2-30 characters for attachments used for sticker creation).
stream
StreamContent of the file.
Properties
Description
Description for the file (max 1024 characters for attachments sent by message, max 200 characters for attachments used for sticker creation).
public string? Description { get; set; }
Property Value
FileName
Name of the file (max 1024 characters for attachments sent by message, 2-30 characters for attachments used for sticker creation).
public string FileName { get; set; }
Property Value
SupportsHttpSerialization
public virtual bool SupportsHttpSerialization { get; }
Property Value
Title
Title of the attachment.
public string? Title { get; set; }
Property Value
Methods
GetStream()
protected Stream? GetStream()
Returns
Serialize()
Serializes the object or its part into HttpContent.
public virtual HttpContent Serialize()
Returns
WithDescription(string?)
Description for the file (max 1024 characters for attachments sent by message, max 200 characters for attachments used for sticker creation).
public AttachmentProperties WithDescription(string? description)
Parameters
description
string
Returns
WithFileName(string)
Name of the file (max 1024 characters for attachments sent by message, 2-30 characters for attachments used for sticker creation).
public AttachmentProperties WithFileName(string fileName)
Parameters
fileName
string
Returns
WithTitle(string?)
Title of the attachment.
public AttachmentProperties WithTitle(string? title)
Parameters
title
string