MCPcopy Create free account
hub / github.com/ClydeTime/Surge / userDelete

Function userDelete

Script/Task/xmly.js:436–462  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

434}
435
436async function userDelete(){
437 let headers = {
438 "Cookie": config.xm_cookie,
439 'Content-Type': `application/x-www-form-urlencoded`
440 }
441 let body = `bizType=13&isFollow=0&toUid=2342717`
442 let myRequest = {
443 url: `https://mobile.ximalaya.com/mobile/follow`,
444 headers: headers,
445 body: body
446 }
447 return await $.http.post(myRequest).then(
448 (response) => {
449 body = JSON.parse(response.body)
450 if (body.ret == 0) {
451 $.log("- 取关用户成功")
452 return true
453 } else {
454 $.log("- !!!未知关注状况")
455 return false
456 }
457 },(reason) => {
458 $.log("- !!!取关用户失败")
459 return false
460 }
461 )
462}
463
464async function giveVoiceLike(){
465 let headers = {

Callers 1

mainFunction · 0.85

Calls 3

postMethod · 0.45
parseMethod · 0.45
logMethod · 0.45

Tested by

no test coverage detected