> For the complete documentation index, see [llms.txt](https://dlite.js.org/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://dlite.js.org/event-classes/message-create.md).

# MessageCreate

## Constructor

```javascript
new messageCreate(object, client)
```

## Properties

### author

The author of the message that was sent

Returns - `user`

### type

The type of the message

Returns - `messageType`

### tss

Whether or not the message is a Text-to-Speech message.

Returns - [`Boolean`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Boolean)

### timestamp

The timestamp of when the message is sent

Returns - `Timestamp`

### pinned

Whether or not the message is pinned to the channel

Returns - [`Boolean`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Boolean)

### nonce

A random number generated after the message was successfully sent

Returns - [`Number`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Number)

### mentions

An array of mentions of members of the message - Will be switched to collection soon

Returns - [`Array`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array)

### rolesMention

An array of mentions of roles of the message - Will be switched to collection soon

Returns - [`Array`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array)

### everyoneMentioned

Whether or not @everyone has been mentioned in the message

Returns - [`Boolean`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Boolean)

### member

The member object returned by discord - will have its own class soon

Returns - [`Object`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object)

### flags

The flags of the channel

Returns - [`Number`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Number)

### embeds

An array of the embeds of the channel

Returns - [`Array`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array)

### editedTimestamp

the timestamp of the time the message was last edited

Returns - `?Timestamp`

### content

the content of the message

Returns - [`String`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/String)

### channelID

the id of the channel the message was sent in

Returns - [`?snowflake`](https://docs.snowflake.com/en/sql-reference/data-types.html)

### attachments

An array of the attachments the message has

Returns - [`Array`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array)

### guildID

the id of the guild the message was sent in

Returns - [`?snowflake`](https://docs.snowflake.com/en/sql-reference/data-types.html)

### id

the id of the message

Returns - [`?snowflake`](https://docs.snowflake.com/en/sql-reference/data-types.html)

### client

The client the message was sent in

Returns - [`?Client`](/classes/client.md)

### channel

The channel constructor of the message

Returns - [`channelUtil`](/util-classes/channelutil.md)

### author

The user constructor of the user that sent the message

Returns - [`User`](/classes/user.md)

## Methods

### delete()

This method will delete the current message and fire the messageDelete event

Returns - `?messageDeleteObject`

### pin()

This method will pin the message to the channel

Returns - `?messagePinObject`

### unpin()

This method will unpin the message to the channel

Returns - `?messageUnpinObject`
