pyautogui.screenshot() in a box code example
Example 1: python hotkey pyautogui
>>> pyautogui.press('enter') # press the Enter key
>>> pyautogui.press('f1') # press the F1 key
>>> pyautogui.press('left') # press the left arrow key
Example 2: python pyautogui how to change the screenshot location
pyautogui.screenshot(region=(0,0, 300, 400))
#Thank me later