Open grigori-gru opened 6 years ago
Hi, the release in npm (0.0.15), still works to send image files? And how can I achieve this, I know that the object img is:
{
file: string,
name: string
}
The file value can be a base 64 string made from an image?
In my application I'm using like this:
api.sendImage({
file: base64,
name: Math.random().toString(36).substr(2, 15)
}, messageObj.sendTo)
.then(r => console.log(`Send image from server to Skype ${JSON.stringify(r)}`))
.catch(e => console.error(`Error while sending media to Skype ${JSON.stringify(e)}`));
But aways end in the catch with:
Error while sending media to Skype {"name":"send-image","data":{}}
At the moment, the lib still works or I'm doing something wrong? Thanks!
Created a pull-request adding the header.
If someone want to send image either, the img
object is:
{
file: "/path/to/my/image.png",
name: "image.png"
}
Without the header the same problem happened: {"name":"send-image","data":{}}
With the header, the image was sent.
i got image working by adding "X-Client-Version": "0/0.0.0.0" but i coudnt enlarge or even download the image,
Hello!
Link to SkPy issue
It's seems to me the best solution should be to add
"X-Client-Version": "0/0.0.0.0"
to headers insend-image.js
. It helps me in my project, I can make pull request with it. But maybe there is some other problems which i can't catch.