Table of Contents
API reference

Method FromString

Namespace
DisCatSharp.Hosting.AspNetCore.Ingress
Assembly
DisCatSharp.Hosting.AspNetCore.dll

FromString(string, Encoding?)

Creates a payload from text content.

public static DiscordIngressPayload FromString(string content, Encoding? encoding = null)

Parameters

content string

The text content to encode.

encoding Encoding

The encoding to use. UTF-8 is used when omitted.

Returns

DiscordIngressPayload

A payload containing the encoded bytes.