# Class: MqttPublishMessage

## vertx-mqtt-server-js/mqtt_publish_message~ MqttPublishMessage

#### new MqttPublishMessage()

Represents an MQTT PUBLISH message

Source:
  - vertx-mqtt-server-js/mqtt_publish_message.js, line 31

### Methods

#### isDup() → {boolean}

Source:
  - vertx-mqtt-server-js/mqtt_publish_message.js, line 75

##### Returns:

If the message is a duplicate

Type
  boolean

#### isRetain() → {boolean}

Source:
  - vertx-mqtt-server-js/mqtt_publish_message.js, line 91

##### Returns:

If the message needs to be retained

Type
  boolean

#### messageId() → {number}

Source:
  - vertx-mqtt-server-js/mqtt_publish_message.js, line 43

##### Returns:

Message identifier

Type
  number

#### payload() → {Buffer}

Source:
  - vertx-mqtt-server-js/mqtt_publish_message.js, line 123

##### Returns:

Payload message

Type
  Buffer

#### qosLevel() → {Object}

Source:
  - vertx-mqtt-server-js/mqtt_publish_message.js, line 59

##### Returns:

Quality of service level

Type
  Object

#### topicName() → {string}

Source:
  - vertx-mqtt-server-js/mqtt_publish_message.js, line 107

##### Returns:

Topic on which the message was published

Type
  string