Support Topics Documentation Slack YouTube Blog

Message Service

I think there’s something wrong with PublishOptions in sending messages.
I sent a message using PublishOptions like this but it didn’t work:
PublishOptions *publishOptions = [PublishOptions new];
[publishOptions addHeader:@“publisher_name” value:name];

publish:“default” message:message publishOptions:publishOptions
response:^(MessageStatus *messageStatus) {
NSLog(@“MessageStatus = %@ <%@>”, messageStatus.messageId, messageStatus.status);
error:^(Fault *fault) {
NSLog(@“FAULT = %@”, fault);
It worked many times before without any error but now it doesn’t.
Please check this service.
Thank you !

the ‘name’ parameter in the codes above is :@“Hello”. Sorry for the missing.
It didn’t work, please check the service.

What does “Does not work mean”. I can think of about 20 different things, but it would help if you describe one specific that happens in your app.

With PublishOptions, the message can’t be sent as expected and my app crash with no error detail, but when i send messages with no PublishOptions everything works fine.

Here’s the screenshot of xcode:</img>

Hi Kadik,

Do you still experience this issue with the latest SDK?

It’s okay now :slight_smile: