Skip to content
This repository was archived by the owner on Sep 29, 2025. It is now read-only.

Commit 4200d8f

Browse files
authored
Merge pull request #8 from kaliiiiiiiiii/dev
Updated README
2 parents 0177581 + d418103 commit 4200d8f

File tree

1 file changed

+41
-1
lines changed

1 file changed

+41
-1
lines changed

README.md

Lines changed: 41 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,10 @@
1-
# Selenium-Profiles V2
1+
# Selenium-Profiles
22

33
* Overwrite **device metrics** using Selenium
44
* Mobile and Desktop **emulation**
55
* **Undetected** by Google, Cloudflare, ..
66
* [Modifying headers](#Modify-headers) supported using [Selenium-Interceptor](https://github.com/kaliiiiiiiiii/Selenium-Interceptor)
7+
* [Touch Actions](#Touch_actions)
78

89
for the latest features, have a look at the `dev`branch
910

@@ -125,6 +126,45 @@ driver.get("https://modheader.com/headers?product=ModHeader")
125126
Don't forget to execute
126127
`cdp_listener.terminate_all()`
127128

129+
### Touch_actions
130+
131+
Example demonstration script
132+
```python
133+
from selenium_profiles.driver import driver as mydriver
134+
from selenium_profiles.profiles import profiles
135+
136+
from selenium_profiles.scripts.touch_actions import touch_action_chain, mid_location
137+
138+
from selenium.webdriver.common.by import By
139+
140+
141+
# Start Driver
142+
mydriver = mydriver()
143+
profile = profiles.Android()
144+
driver = mydriver.start(profile, uc_driver=False) # or .Android
145+
146+
# initialise touch_actions
147+
touch_actions = touch_action_chain(driver)
148+
149+
driver.get("https://cps-check.com/de/multi-touch-test")
150+
151+
touch_box = driver.find_element(By.XPATH,'//*[@id="box"]') # Get element
152+
location = mid_location(touch_box) # get element middle location
153+
154+
# setup actions
155+
touch_actions.pointer_action.move_to_location(location['x'],location['y'])
156+
touch_actions.pointer_action.pointer_down()
157+
158+
# perform actions
159+
touch_actions.perform()
160+
161+
# now you should see a touch indication point on the Website
162+
163+
# quit driver
164+
input('Press ENTER to quit Driver\n')
165+
driver.quit()
166+
```
167+
128168
### To export a profile:
129169

130170
go to [https://js.do/kaliiiiiiiiiii/get_profile](https://js.do/kaliiiiiiiiiii/get_profile) in your browser and copy the text.

0 commit comments

Comments
 (0)