Last active
June 23, 2020 09:29
-
-
Save shriyaRam/67f21e1ee03da7890bc79683f7b82772 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
await page.select('#phone_route_voice_handler', 'relay_agora').then(async()=>{ console.log("SUCCESS!")}).catch(()=>{console.log("FAILED TO SELECT AGORA CONNECTOR")}); | |
await page.select("select#phone_route_call_agora_connector_id", req.body.connectorname) | |
const input = await page.$('#phone_route_call_agora_channel'); | |
await input.click({ clickCount: 3 }) | |
await input.type(req.body.channel); | |
await page.$eval('input[name=commit]', el => el.click()).then(async()=>{ await page.waitForNavigation({waitUntil: 'load'})}).catch(()=>{console.log("SUCCESS")});; | |
await browser.close(); | |
reply += "Call on: " + ans; | |
await res.send(reply); | |
await setTimeout((function() { | |
return process.exit(22); | |
}), 1000); | |
}; | |
main(); | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment