0

Help on fileTransferSend for receive action

 
url = ymSide.getServer() + "/v1/filetransfer/relay?sid=" + ymSide.
connection = ymSide.connectionApiHTTP(url, "POST", true);
req = "{\"sendAs\":\"" + ymSide.getUsername() +
        + "\"action\":\"receive\","
+ "\"ftSessionId\":\"" + id + "\","
+ "\"target\":\"" + destination + "\","
+ "\"relayIP\":\"" + relayIP + "\","
+ "\"filename\":\"" + fileName + "\"" + "}";
connection.setRequestProperty("Content-Type", "application/json;charset=utf-8");
connection.setRequestProperty("Content-Length", "" + req.length());
connection.openOutputStream().write(req.getBytes());
connection.openInputStream();

this code return {"error":{"code":-1005,"detail":"Invalid Argument Error","description":"Invalid Argument Error"}.

Can someone help me where exactly the error is? I search all over req, it is meet the requirement api.

by
0 Replies

Recent Posts

in Messenger IM SDK