MQTTAsync_successData(3)

πŸ’– MQTTAsync_successData(3) πŸ’–

okay bestie, welcome to the Library Functions Manual entry for MQTTAsync_successData β€” yes that's the whole NAME section, it's just the struct's name, and honestly? iconic of it to introduce itself that way. no notes. πŸŽ€

This is the little bundle of joy that shows up in your onSuccess response callback when an API call actually worked. slay. ✨


✨ SYNOPSIS ✨

#include <MQTTAsync.h>

πŸ¦‹ Data Fields

MQTTAsync_token token
union {
   int qos
   int * qosList
   struct {
      MQTTAsync_message message
      char * destinationName
   } pub
   struct {
      char * serverURI
      int MQTTVersion
      int sessionPresent
   } connect
} alt

🌸 Detailed Description 🌸

The data returned on completion of a successful API call in the response callback onSuccess. that's it, that's the vibe β€” this struct is literally the "you did it bestie 🫢" receipt. no cap.


πŸ’… Field Documentation πŸ’…

MQTTAsync_token token

A token identifying the successful request. Can be used to refer to the request later. it's giving little name tag for your request so you can find it again later, iykyk. πŸ”₯

int qos

For subscribe, the granted QoS of the subscription returned by the server. Also for subscribeMany, if only 1 subscription was requested. yes girl, only the one β€” if you asked for more, scroll down. πŸ‘€

int* qosList

For subscribeMany, if more than one subscription was requested, the list of granted QoSs of the subscriptions returned by the server. it's the group-chat version of qos, basically. πŸ’¬

MQTTAsync_message message

the message being sent to the server. πŸ’Œ

char* destinationName

the topic destination for the message. where it's going, periodt. πŸ“

struct { ... } pub

For publish, the message being sent to the server. the whole message + destinationName situation above lives inside this one, bestie. 🎁

char* serverURI

the connection string of the server. 🌐

int MQTTVersion

the version of MQTT being used. lowkey important to know which flavour you're on. πŸ“

int sessionPresent

the session present flag returned from the server. 🚩

struct { ... } connect

(this one's a nested struct, no extra description β€” it's just the container holding serverURI, MQTTVersion and sessionPresent together. she's a box. a cute one. πŸŽ€)

union { ... } alt

A union of the different values that can be returned for subscribe, unsubscribe and publish. it's a union so it's one of these at a time, not all of them β€” do not come for me assuming otherwise. πŸ’€

⚠️ real talk: alt is a union, so depending on which call succeeded you get qos/qosList, or pub, or connect β€” not the whole squad at once. read the field that matches your request, bestie.

πŸ‘‘ Author πŸ‘‘

Generated automatically by Doxygen for Paho Asynchronous MQTT C Client Library from the source code. so it wasn't even hand-written, it was born this way. main character energy fr fr. ⭐


and that's the whole page, babes β€” no filler, no crumbs. 🧚

Paho Asynchronous MQTT C Client Library β€” page generated Tue Jun 2 2026 00:00:00, and you just read MQTTAsync_successData(3). go forth and handle your callbacks responsibly. πŸ’œπŸŒˆπŸ’–

πŸ“¦ where this page comes from