return doByteArrayRequest(request);
}
public void setClientData(String secret, String token, String appId, String userId, byte[] data)
throws RestClientException {
HttpRequest request = buildPut("extensions/attachment/user/" + urlEscape(userId) + "/" + urlEscape(appId)
+ "?secret=" + urlEscape(secret));
request.setHeader("X-Auth-Token", token);
try {
request.setRequestContent(ByteSource.wrap(data));
} catch (IOException e) {
throw new RestClientException("Error setting request content", e);
}
doStringRequest(request);