Are you trying to send a file via Server Connect API?
I could be wrong, but I think it's not possible, there's a afeature request and some extension for that: