Image
Implementation of discords Image object as a Luau builder.
https://discord.com/developers/docs/resources/message#embed-object-embed-image-structure
Summary
Properties
Section titled “Properties”Source url of image (only supports http(s) and attachments)
proxyUrl
Section titled “proxyUrl”A proxied url of the image
height
Section titled “height”Height of image
Width of image
Methods
Section titled “Methods”setUrl
Section titled “setUrl”Image : setUrl ( url , proxyUrl ) -> Image
Set the image url for this embed.
setHeight
Section titled “setHeight”Image : setHeight ( height ) -> Image
Set the image height for this embed.
Parameters
| height: number |
Returns
| Image |
setWidth
Section titled “setWidth”Image : setWidth ( width ) -> Image
Set the image width for this embed.
Parameters
| width: number |
Returns
| Image |
Image : build ( ) -> JSON
Responsible for building the JSON that can be parsed by the Discord API.
Returns
| JSON |
Functions
Section titled “Functions”Image . new ( resource ) -> Image
Responsible for creating a new Image.
local image = Image.new({ url = "https://example.com/image.png", height = 100, width = 100})