ai-screenshooter 1.2.1__tar.gz → 1.2.3__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: ai-screenshooter
3
- Version: 1.2.1
3
+ Version: 1.2.3
4
4
  Summary: A CLI tool to capture and send AI-powered screenshots
5
5
  Home-page: https://github.com/tech4vision/ai-screenshoter
6
6
  Author: Last Shot AI
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: ai-screenshooter
3
- Version: 1.2.1
3
+ Version: 1.2.3
4
4
  Summary: A CLI tool to capture and send AI-powered screenshots
5
5
  Home-page: https://github.com/tech4vision/ai-screenshoter
6
6
  Author: Last Shot AI
@@ -10,6 +10,11 @@ from pynput import keyboard
10
10
 
11
11
  screenshot_list = []
12
12
  API_TOKEN = None
13
+ API_URL = None
14
+
15
+ # Server URLs
16
+ PROD_URL = "https://service.tech4vision.net/ai-management-service/api/v1/sessions/code-challenge"
17
+ LOCAL_URL = "http://localhost:8082/api/v1/sessions/code-challenge"
13
18
 
14
19
  current_keys = set()
15
20
 
@@ -101,7 +106,7 @@ def send_screenshots():
101
106
  return
102
107
 
103
108
  response = requests.post(
104
- "https://api.ai-management.tech4vision.io/api/v1/sessions/code-challenge",
109
+ API_URL,
105
110
  headers={"Authorization": f"Bearer {API_TOKEN}"},
106
111
  files=files,
107
112
  )
@@ -134,12 +139,16 @@ def main():
134
139
  parser = argparse.ArgumentParser(description="AI Screenshot CLI")
135
140
  parser.add_argument("start", help="Start listening for hotkeys")
136
141
  parser.add_argument("--token", required=True, help="API Token for authentication")
142
+ parser.add_argument("--local", action="store_true", help="Use localhost server instead of production")
137
143
 
138
144
  args = parser.parse_args()
139
- global API_TOKEN
145
+ global API_TOKEN, API_URL
140
146
  API_TOKEN = args.token
147
+ API_URL = LOCAL_URL if args.local else PROD_URL
141
148
 
149
+ server_mode = "LOCAL" if args.local else "PRODUCTION"
142
150
  print("📸 AI Screenshot CLI started.")
151
+ print(f"🌐 Server: {server_mode} ({API_URL})")
143
152
  print("✅ Press ESC + ↓ to capture a screenshot.")
144
153
  print("✅ Press ESC + ↑ to send all stored screenshots.")
145
154
  print("📌 Running... (Press Ctrl + C to exit)")
@@ -2,7 +2,7 @@ from setuptools import setup, find_packages
2
2
 
3
3
  setup(
4
4
  name="ai-screenshooter",
5
- version="1.2.1",
5
+ version="1.2.3",
6
6
  packages=find_packages(),
7
7
  py_modules=["ai_screenshot"],
8
8
  install_requires=[