1
它不是DUPLICATE.Link發送JSON對象,已提供的是一個古老的「HTTP客戶端」已api23被刪除通過HTTP POST方法在android系統
我想送JSON對象:
{"emailId":"[email protected]","address":"Naya bans","city":"Noida","pincode":"201301","account_number":"91123546374208","bank_name":"Axis Bank","branch_name":"91123546374208","ifsc_code":"UTI0000879"}
到網址:
http://10digimr.mobimedia.in/api/mobile_retailer/update_profile 我該怎麼做呢? 通過post方法?
方法:
POST /api/mobile_retailer/update_profile
強制性KEY:
{"emailId","address"}
REQUEST JSON:
{"emailId":"[email protected]","address":"Naya bans","city":"Noida","pincode":"201301","account_number":"91123546374208","bank_name":"Axis Bank","branch_name":"91123546374208","ifsc_code":"UTI0000879"}
RESPONSE:
{"message":"Mail Send","data":true,"status":200}
你所提到的API是一個GET方法。請向API開發人員提供有關訪問API的正確方法的文檔。我試着通過休息客戶端向它發送一個POSt請求。它給出了一個錯誤。 – crashOveride
可能的重複[如何發送一個JSON對象通過Android的請求?](http://stackoverflow.com/questions/3027066/how-to-send-a-json-object-over-request-with-android) –
我的不好!寫錯了網址! – user6092109