please make a tampermonkey script that when a page loads, it detects this object and…
Jump to turn (6)
- 1please make a tampermonkey script that when a page loads, it detects this object
- 2I forgot one detail, please split the value by the vertical bars "|" and then se
- 3I want it to wait for it to appear as it takes it a little time to after loading
- 4add debug messages with console.log after every major action where it could hang
- 5its just spamming waiting for token input, i have to mention that this is inside
- 6the iframe does not have an id, but a class r34K7X1zGgAi6DllVF3T
- User
please make a tampermonkey script that when a page loads, it detects this object and then stores the value:
then you will send that to 127.0.0.1/api/solve like in this nodejs implementation, but in vanilla userscript javascript.
const axios = require('axios');
async function scrapeToken(token) { const apiEndpoint = 'http://127.0.0.1:5000/api/solve'; const data = { 'token': token, };
try { console.log('scraping...') const response = await axios.get(apiEndpoint, {data,headers: {'Content-Type': 'application/json'}}); console.log('Token sent successfully:', response.data); } catch (error) { console.error('Failed to send token to API:', error); } }
- Assistant