Reproduce:
Use Node API,
Send base64 upload via oneall.user.publish
I get back:
I20160928-10:03:30.885(2)? publishing res { result:
I20160928-10:03:30.885(2)? { data:
I20160928-10:03:30.891(2)? { sharing_message_token: '50d57718-45cf-4ffc-ba20-8270d432d80c',
I20160928-10:03:30.891(2)? date_creation: 'Wed, 28 Sep 2016 10:03:30 +0200',
I20160928-10:03:30.891(2)? date_last_published: 'Wed, 28 Sep 2016 10:03:30 +0200',
I20160928-10:03:30.892(2)? publications: [Object] },
I20160928-10:03:30.892(2)? status:
I20160928-10:03:30.900(2)? { flag: 'success',
I20160928-10:03:30.901(2)? code: 200,
I20160928-10:03:30.901(2)? info: 'Your request has been processed successfully' } },
I20160928-10:03:30.905(2)? error: null }
[ { provider: 'linkedin',
....
I20160928-10:12:21.939(2)? status:
I20160928-10:12:21.940(2)? { flag: 'success',
I20160928-10:12:21.945(2)? code: 200,
I20160928-10:12:21.946(2)? message: 'Message published successfully to identity' },
I20160928-10:12:21.946(2)? date_publication: 'Wed, 28 Sep 2016 10:12:21 +0200' } ]
The post does appear on LinkedIn but does not have the image attached.
Exactly the same post appears with image on Twitter, so it's not a matter of posting the wrong data.
Answers
Unfortunately, this feature (upload) is not supported by Linkedin.
You can use a picture URL instead.
The status message is not accurate.
Regards
You might want to make that clear in the documentation for other users, and update the status message response.
message: 'The provider did not accept the message, it is incomplete: The message must contain the node [text->body] and/or both nodes [link->caption] and [link->url]' } }
The json that I post is correct though, you can see both required parts are in the json, and it works fine for Facebook / Twitter
parts: {
text: {
body: 'Did you know?'
},
link: {
caption: "",
url: 'https://socialchore.s3-eu-central-1.amazonaws.com/Fileboard---Chew-gum-to-charge-up-your-sales.png'
},
picture: {
url: 'https://socialchore.s3-eu-central-1.amazonaws.com/Fileboard---Chew-gum-to-charge-up-your-sales.png'
},
uploads: [
{
name: 'Fileboard---Chew-gum-to-charge-up-your-sales.png',
data: base64String
}
]
}
Note that I have to include uploads because I'm both posting to Twitter (which only accepts uploads, not picture url), Facebook and LinkedIn.