Re: [問題] c#登入api
※ 引述《MOONY135 (談無慾)》之銘言:
: 大家好 最近剛要學call web api
: 以下是我的疑問
: post使用的是64base Encode 送出
: 回傳的值是json
: https://gist.github.com/Aix-Shiao/bf7df4258cfb935fca06bafde3c14551
: 以上是我的code
: string postData = "myjson";
: myjson 是我將
: {"account":"ooo@xxx.com.tw",
: "password":"pass1234"}
: 這串json 丟入
: https://www.base64encode.org/ 這個網址產生出來的
: =======================
: 我想問說
: sting postDate ->
: byte[] postDataBytes ->
: Convert.ToBase64String(postDataBytes)->
: Convert.FromBase64String(returnValue);
: 不知道這樣的轉換邏輯是否有問題?
: 錯誤代碼一直是無post資料
感謝大大 目前也遇到同樣的問題...
不過我目前需要的是 post "account":"ooo@xxx.com.tw" 跟一個zip檔
應該是多重類型 不知道大大有沒有研究呢
--
※ 發信站: 批踢踢實業坊(ptt.cc), 來自: 59.124.46.66
※ 文章網址: https://www.ptt.cc/bbs/C_Sharp/M.1476867296.A.723.html
討論串 (同標題文章)