public ApiSingleResponse<Comment> Comment(string mediaId, string text) { string json = GetJSON(string.Format(ApiUrls.COMMENTS_ADD_URL, mediaId, base._token, text), string.Format("text={0}",text), "POST"); ApiSingleResponse<Comment> response = json.Deserialize<ApiSingleResponse<Comment>>(); return response; }
public JsonResult Create(PhotoComment comment) { try { MediaClient client = new MediaClient(base.userToken.access_token); ApiSingleResponse<Comment> response = client.Comment(comment.id, Server.UrlEncode(comment.text)); return Json(new { success = true }); } catch { return Json(new { success = false }); } }