walla-cli 0.1.0__tar.gz → 0.1.2__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.
- {walla_cli-0.1.0 → walla_cli-0.1.2}/AGENTS.md +1 -1
- {walla_cli-0.1.0 → walla_cli-0.1.2}/PKG-INFO +6 -8
- {walla_cli-0.1.0 → walla_cli-0.1.2}/README.md +5 -7
- {walla_cli-0.1.0 → walla_cli-0.1.2}/docs/mcp.md +1 -1
- {walla_cli-0.1.0 → walla_cli-0.1.2}/pyproject.toml +1 -1
- {walla_cli-0.1.0 → walla_cli-0.1.2}/skills/walla/SKILL.md +1 -1
- {walla_cli-0.1.0 → walla_cli-0.1.2}/walla/__init__.py +1 -1
- walla_cli-0.1.2/walla/account/prompt.py +82 -0
- {walla_cli-0.1.0 → walla_cli-0.1.2}/walla/cli/banner.py +16 -0
- {walla_cli-0.1.0 → walla_cli-0.1.2}/walla/cli/main.py +5 -3
- walla_cli-0.1.2/walla/core/human_fix.py +31 -0
- {walla_cli-0.1.0 → walla_cli-0.1.2}/walla/core/instruct.py +2 -1
- walla_cli-0.1.0/walla/account/prompt.py +0 -56
- walla_cli-0.1.0/walla/core/human_fix.py +0 -26
- {walla_cli-0.1.0 → walla_cli-0.1.2}/.cursor/rules/quality.mdc +0 -0
- {walla_cli-0.1.0 → walla_cli-0.1.2}/.github/workflows/ci.yml +0 -0
- {walla_cli-0.1.0 → walla_cli-0.1.2}/.gitignore +0 -0
- {walla_cli-0.1.0 → walla_cli-0.1.2}/LICENSE +0 -0
- {walla_cli-0.1.0 → walla_cli-0.1.2}/docs/WIRE.md +0 -0
- {walla_cli-0.1.0 → walla_cli-0.1.2}/docs/assets/walla-github-banner.jpg +0 -0
- {walla_cli-0.1.0 → walla_cli-0.1.2}/docs/code_quality.md +0 -0
- {walla_cli-0.1.0 → walla_cli-0.1.2}/docs/data_engineering_standards.md +0 -0
- {walla_cli-0.1.0 → walla_cli-0.1.2}/docs/objective_function.md +0 -0
- {walla_cli-0.1.0 → walla_cli-0.1.2}/docs/rate_limit_analysis.md +0 -0
- {walla_cli-0.1.0 → walla_cli-0.1.2}/fixtures/categories.json +0 -0
- {walla_cli-0.1.0 → walla_cli-0.1.2}/fixtures/item_detail.json +0 -0
- {walla_cli-0.1.0 → walla_cli-0.1.2}/fixtures/search_bicicleta.json +0 -0
- {walla_cli-0.1.0 → walla_cli-0.1.2}/scripts/check_code_quality.py +0 -0
- {walla_cli-0.1.0 → walla_cli-0.1.2}/scripts/probe_rate.py +0 -0
- {walla_cli-0.1.0 → walla_cli-0.1.2}/tests/test_account.py +0 -0
- {walla_cli-0.1.0 → walla_cli-0.1.2}/tests/test_account_more.py +0 -0
- {walla_cli-0.1.0 → walla_cli-0.1.2}/tests/test_catch.py +0 -0
- {walla_cli-0.1.0 → walla_cli-0.1.2}/tests/test_cli_json.py +0 -0
- {walla_cli-0.1.0 → walla_cli-0.1.2}/tests/test_core.py +0 -0
- {walla_cli-0.1.0 → walla_cli-0.1.2}/tests/test_edges.py +0 -0
- {walla_cli-0.1.0 → walla_cli-0.1.2}/tests/test_http_more.py +0 -0
- {walla_cli-0.1.0 → walla_cli-0.1.2}/tests/test_live.py +0 -0
- {walla_cli-0.1.0 → walla_cli-0.1.2}/tests/test_parsers.py +0 -0
- {walla_cli-0.1.0 → walla_cli-0.1.2}/tests/test_polite.py +0 -0
- {walla_cli-0.1.0 → walla_cli-0.1.2}/tests/test_search_api.py +0 -0
- {walla_cli-0.1.0 → walla_cli-0.1.2}/tests/test_session_store.py +0 -0
- {walla_cli-0.1.0 → walla_cli-0.1.2}/tests/test_verdict.py +0 -0
- {walla_cli-0.1.0 → walla_cli-0.1.2}/walla/account/__init__.py +0 -0
- {walla_cli-0.1.0 → walla_cli-0.1.2}/walla/account/actions.py +0 -0
- {walla_cli-0.1.0 → walla_cli-0.1.2}/walla/account/cookies.py +0 -0
- {walla_cli-0.1.0 → walla_cli-0.1.2}/walla/account/inbox.py +0 -0
- {walla_cli-0.1.0 → walla_cli-0.1.2}/walla/account/login.py +0 -0
- {walla_cli-0.1.0 → walla_cli-0.1.2}/walla/account/session_store.py +0 -0
- {walla_cli-0.1.0 → walla_cli-0.1.2}/walla/cli/__init__.py +0 -0
- {walla_cli-0.1.0 → walla_cli-0.1.2}/walla/cli/catch.py +0 -0
- {walla_cli-0.1.0 → walla_cli-0.1.2}/walla/cli/cmd_account.py +0 -0
- {walla_cli-0.1.0 → walla_cli-0.1.2}/walla/cli/cmd_look.py +0 -0
- {walla_cli-0.1.0 → walla_cli-0.1.2}/walla/cli/cmd_ops.py +0 -0
- {walla_cli-0.1.0 → walla_cli-0.1.2}/walla/cli/console.py +0 -0
- {walla_cli-0.1.0 → walla_cli-0.1.2}/walla/core/__init__.py +0 -0
- {walla_cli-0.1.0 → walla_cli-0.1.2}/walla/core/envelope.py +0 -0
- {walla_cli-0.1.0 → walla_cli-0.1.2}/walla/core/errors.py +0 -0
- {walla_cli-0.1.0 → walla_cli-0.1.2}/walla/core/exceptions.py +0 -0
- {walla_cli-0.1.0 → walla_cli-0.1.2}/walla/core/path.py +0 -0
- {walla_cli-0.1.0 → walla_cli-0.1.2}/walla/http/__init__.py +0 -0
- {walla_cli-0.1.0 → walla_cli-0.1.2}/walla/http/client.py +0 -0
- {walla_cli-0.1.0 → walla_cli-0.1.2}/walla/http/headers.py +0 -0
- {walla_cli-0.1.0 → walla_cli-0.1.2}/walla/http/polite.py +0 -0
- {walla_cli-0.1.0 → walla_cli-0.1.2}/walla/hunter/__init__.py +0 -0
- {walla_cli-0.1.0 → walla_cli-0.1.2}/walla/hunter/profile_store.py +0 -0
- {walla_cli-0.1.0 → walla_cli-0.1.2}/walla/hunter/verdict.py +0 -0
- {walla_cli-0.1.0 → walla_cli-0.1.2}/walla/hunter/watches.py +0 -0
- {walla_cli-0.1.0 → walla_cli-0.1.2}/walla/mcp/__init__.py +0 -0
- {walla_cli-0.1.0 → walla_cli-0.1.2}/walla/mcp/_entry.py +0 -0
- {walla_cli-0.1.0 → walla_cli-0.1.2}/walla/mcp/server.py +0 -0
- {walla_cli-0.1.0 → walla_cli-0.1.2}/walla/models/__init__.py +0 -0
- {walla_cli-0.1.0 → walla_cli-0.1.2}/walla/models/account.py +0 -0
- {walla_cli-0.1.0 → walla_cli-0.1.2}/walla/models/listing.py +0 -0
- {walla_cli-0.1.0 → walla_cli-0.1.2}/walla/models/profile.py +0 -0
- {walla_cli-0.1.0 → walla_cli-0.1.2}/walla/search/__init__.py +0 -0
- {walla_cli-0.1.0 → walla_cli-0.1.2}/walla/search/api.py +0 -0
- {walla_cli-0.1.0 → walla_cli-0.1.2}/walla/search/parse.py +0 -0
|
@@ -21,7 +21,7 @@ pytest -q -m "not live"
|
|
|
21
21
|
## Calling walla from an agent
|
|
22
22
|
|
|
23
23
|
```bash
|
|
24
|
-
pipx install 'walla-cli[mcp]'
|
|
24
|
+
pipx install 'walla-cli[mcp]' # PyPI preferred
|
|
25
25
|
walla instruct --json
|
|
26
26
|
walla setup --lat 41.39 --lon 2.17 --km 30 --label Barcelona --json
|
|
27
27
|
walla login --cookie '<session-token>' --json
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.5
|
|
2
2
|
Name: walla-cli
|
|
3
|
-
Version: 0.1.
|
|
3
|
+
Version: 0.1.2
|
|
4
4
|
Summary: Wallapop.es CLI - look · offer · talk for humans and agents
|
|
5
5
|
Project-URL: Homepage, https://github.com/berendgort/wallapop-cli
|
|
6
6
|
Project-URL: Repository, https://github.com/berendgort/wallapop-cli
|
|
@@ -106,11 +106,11 @@ Link listings as `https://es.wallapop.com/item/<web_slug>`. Verdicts:
|
|
|
106
106
|
|
|
107
107
|
### Bootstrap
|
|
108
108
|
|
|
109
|
-
1. Install from
|
|
109
|
+
1. Install from **PyPI** (preferred):
|
|
110
110
|
```bash
|
|
111
|
-
pipx install 'walla-cli[mcp]'
|
|
112
|
-
|
|
113
|
-
|
|
111
|
+
pipx install 'walla-cli[mcp]'
|
|
112
|
+
```
|
|
113
|
+
From a clone only when hacking: `pipx install -e '.[mcp]'`.
|
|
114
114
|
2. `walla doctor --json` — read `auth.session` and `network.reachable`.
|
|
115
115
|
**Never** print tokens or cookies.
|
|
116
116
|
3. If no session: ask the human to run `walla login` and paste
|
|
@@ -151,9 +151,7 @@ Rules:
|
|
|
151
151
|
## Install
|
|
152
152
|
|
|
153
153
|
```bash
|
|
154
|
-
|
|
155
|
-
cd wallapop-cli
|
|
156
|
-
pipx install 'walla-cli[mcp]' # or: pipx install -e '.[mcp]'
|
|
154
|
+
pipx install 'walla-cli[mcp]' # PyPI: https://pypi.org/project/walla-cli/
|
|
157
155
|
walla setup --lat 41.39 --lon 2.17 --km 30 --label Barcelona --json
|
|
158
156
|
walla login # paste __Secure-next-auth.session-token
|
|
159
157
|
walla doctor --json
|
|
@@ -62,11 +62,11 @@ Link listings as `https://es.wallapop.com/item/<web_slug>`. Verdicts:
|
|
|
62
62
|
|
|
63
63
|
### Bootstrap
|
|
64
64
|
|
|
65
|
-
1. Install from
|
|
65
|
+
1. Install from **PyPI** (preferred):
|
|
66
66
|
```bash
|
|
67
|
-
pipx install 'walla-cli[mcp]'
|
|
68
|
-
|
|
69
|
-
|
|
67
|
+
pipx install 'walla-cli[mcp]'
|
|
68
|
+
```
|
|
69
|
+
From a clone only when hacking: `pipx install -e '.[mcp]'`.
|
|
70
70
|
2. `walla doctor --json` — read `auth.session` and `network.reachable`.
|
|
71
71
|
**Never** print tokens or cookies.
|
|
72
72
|
3. If no session: ask the human to run `walla login` and paste
|
|
@@ -107,9 +107,7 @@ Rules:
|
|
|
107
107
|
## Install
|
|
108
108
|
|
|
109
109
|
```bash
|
|
110
|
-
|
|
111
|
-
cd wallapop-cli
|
|
112
|
-
pipx install 'walla-cli[mcp]' # or: pipx install -e '.[mcp]'
|
|
110
|
+
pipx install 'walla-cli[mcp]' # PyPI: https://pypi.org/project/walla-cli/
|
|
113
111
|
walla setup --lat 41.39 --lon 2.17 --km 30 --label Barcelona --json
|
|
114
112
|
walla login # paste __Secure-next-auth.session-token
|
|
115
113
|
walla doctor --json
|
|
@@ -13,7 +13,7 @@ license: MIT
|
|
|
13
13
|
## Bootstrap
|
|
14
14
|
|
|
15
15
|
```bash
|
|
16
|
-
pipx install 'walla-cli[mcp]'
|
|
16
|
+
pipx install 'walla-cli[mcp]' # PyPI: https://pypi.org/project/walla-cli/
|
|
17
17
|
walla doctor --json
|
|
18
18
|
# If auth.session is false: ask human to run `walla login` and paste cookie
|
|
19
19
|
# Or: walla login --cookie '<value>' --json
|
|
@@ -0,0 +1,82 @@
|
|
|
1
|
+
"""Interactive login helpers (cookie paste primary)."""
|
|
2
|
+
|
|
3
|
+
from __future__ import annotations
|
|
4
|
+
|
|
5
|
+
import getpass
|
|
6
|
+
from typing import Any
|
|
7
|
+
|
|
8
|
+
import typer
|
|
9
|
+
|
|
10
|
+
from walla.account.cookies import SESSION_COOKIE
|
|
11
|
+
from walla.account.login import login_cookie_text, login_password
|
|
12
|
+
from walla.core.exceptions import WallaAuthError
|
|
13
|
+
from walla.models.account import SessionData
|
|
14
|
+
|
|
15
|
+
__all__ = ("interactive_login", "session_summary")
|
|
16
|
+
|
|
17
|
+
_COOKIE_HOWTO = f"""
|
|
18
|
+
How to get your Wallapop session cookie
|
|
19
|
+
=======================================
|
|
20
|
+
|
|
21
|
+
1. Open Chrome/Firefox and go to:
|
|
22
|
+
https://es.wallapop.com
|
|
23
|
+
2. Log in with your Wallapop account (until you see your feed).
|
|
24
|
+
3. Copy the cookie named exactly:
|
|
25
|
+
{SESSION_COOKIE}
|
|
26
|
+
|
|
27
|
+
Easiest (extension):
|
|
28
|
+
- Install "Cookie-Editor" from the Chrome/Firefox store
|
|
29
|
+
- Click the Cookie-Editor icon on es.wallapop.com
|
|
30
|
+
- Find {SESSION_COOKIE}
|
|
31
|
+
- Click Copy on its Value
|
|
32
|
+
|
|
33
|
+
Or DevTools (no extension):
|
|
34
|
+
- Press F12 -> Application (Chrome) or Storage (Firefox)
|
|
35
|
+
- Cookies -> https://es.wallapop.com
|
|
36
|
+
- Click {SESSION_COOKIE}
|
|
37
|
+
- Double-click the Value cell -> Ctrl+C / Cmd+C
|
|
38
|
+
|
|
39
|
+
4. Paste that long string below (one line), then press Enter.
|
|
40
|
+
Do NOT paste your password. Do NOT share this cookie in chat.
|
|
41
|
+
|
|
42
|
+
Optional: save an export as cookies.txt and paste the file path instead.
|
|
43
|
+
""".strip()
|
|
44
|
+
|
|
45
|
+
|
|
46
|
+
def interactive_login(*, password: bool = False) -> SessionData:
|
|
47
|
+
"""Prompt for cookie paste, or email/password when ``password`` is True."""
|
|
48
|
+
if password:
|
|
49
|
+
return _prompt_password()
|
|
50
|
+
return _prompt_cookie()
|
|
51
|
+
|
|
52
|
+
|
|
53
|
+
def _prompt_cookie() -> SessionData:
|
|
54
|
+
typer.echo(_COOKIE_HOWTO)
|
|
55
|
+
typer.echo("")
|
|
56
|
+
raw = typer.prompt(f"Paste {SESSION_COOKIE} value (or cookies.txt path)").strip()
|
|
57
|
+
if not raw:
|
|
58
|
+
raise WallaAuthError("empty paste - copy the cookie Value, not the name")
|
|
59
|
+
return login_cookie_text(raw)
|
|
60
|
+
|
|
61
|
+
|
|
62
|
+
def _prompt_password() -> SessionData:
|
|
63
|
+
typer.echo(
|
|
64
|
+
"Password login often fails (MFA). Prefer plain: walla login (paste cookie)."
|
|
65
|
+
)
|
|
66
|
+
email = typer.prompt("email").strip()
|
|
67
|
+
pw = getpass.getpass("password: ")
|
|
68
|
+
try:
|
|
69
|
+
return login_password(username=email, password=pw)
|
|
70
|
+
except WallaAuthError:
|
|
71
|
+
typer.echo("Password rejected. Falling back to cookie paste.")
|
|
72
|
+
return _prompt_cookie()
|
|
73
|
+
|
|
74
|
+
|
|
75
|
+
def session_summary(sess: SessionData) -> dict[str, Any]:
|
|
76
|
+
return {
|
|
77
|
+
"authenticated": True,
|
|
78
|
+
"has_access_token": bool(sess.access_token),
|
|
79
|
+
"has_cookie": bool(sess.session_cookie),
|
|
80
|
+
"user_id": sess.user_id,
|
|
81
|
+
"micro_name": sess.micro_name,
|
|
82
|
+
}
|
|
@@ -20,6 +20,7 @@ _BANNER_ROWS = (
|
|
|
20
20
|
_STYLE = "bold #A3E635"
|
|
21
21
|
_TAG = "italic #D9F99D"
|
|
22
22
|
_CREDIT = "#84CC16"
|
|
23
|
+
_HOOK = "#BEF264"
|
|
23
24
|
|
|
24
25
|
|
|
25
26
|
def print_banner() -> None:
|
|
@@ -31,3 +32,18 @@ def print_banner() -> None:
|
|
|
31
32
|
console.print(Text(" look · offer · talk", style=_TAG))
|
|
32
33
|
console.print(Text(" Dr. Berend Gort · www.berendgort.dev", style=_CREDIT))
|
|
33
34
|
console.print()
|
|
35
|
+
console.print(
|
|
36
|
+
Text(
|
|
37
|
+
' Example: "Find a used kite near Barcelona under 400eur,\n'
|
|
38
|
+
' message the seller, offer if it is a GRAB."',
|
|
39
|
+
style=_HOOK,
|
|
40
|
+
)
|
|
41
|
+
)
|
|
42
|
+
console.print(
|
|
43
|
+
Text(
|
|
44
|
+
" Install: pipx install 'walla-cli[mcp]' "
|
|
45
|
+
"https://pypi.org/project/walla-cli/",
|
|
46
|
+
style=_CREDIT,
|
|
47
|
+
)
|
|
48
|
+
)
|
|
49
|
+
console.print()
|
|
@@ -23,9 +23,11 @@ app = typer.Typer(
|
|
|
23
23
|
name="walla",
|
|
24
24
|
cls=_WallaGroup,
|
|
25
25
|
help=(
|
|
26
|
-
"Wallapop.es look · offer · talk
|
|
27
|
-
"
|
|
28
|
-
"
|
|
26
|
+
"Wallapop.es look · offer · talk. "
|
|
27
|
+
"Example ask: find a used kite near Barcelona under 400eur, "
|
|
28
|
+
"message seller, offer if GRAB. "
|
|
29
|
+
"Install: pipx install 'walla-cli[mcp]'. "
|
|
30
|
+
"Recipe: walla instruct --json."
|
|
29
31
|
),
|
|
30
32
|
no_args_is_help=True,
|
|
31
33
|
add_completion=False,
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
"""User-visible fix recipes (not system prompts)."""
|
|
2
|
+
|
|
3
|
+
from __future__ import annotations
|
|
4
|
+
|
|
5
|
+
from typing import Any
|
|
6
|
+
|
|
7
|
+
__all__ = (
|
|
8
|
+
"cookie_export_fix",
|
|
9
|
+
)
|
|
10
|
+
|
|
11
|
+
_SESSION_COOKIE = "__Secure-next-auth.session-token"
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
def cookie_export_fix() -> dict[str, Any]:
|
|
15
|
+
return {
|
|
16
|
+
"title": "Paste Wallapop session cookie",
|
|
17
|
+
"steps": [
|
|
18
|
+
"Open https://es.wallapop.com and log in until you see your feed.",
|
|
19
|
+
f"Copy cookie {_SESSION_COOKIE} (Cookie-Editor extension, or F12 -> "
|
|
20
|
+
"Application/Storage -> Cookies -> es.wallapop.com -> copy Value).",
|
|
21
|
+
"Run: walla login",
|
|
22
|
+
"Paste the cookie Value (the long string), not the cookie name, then Enter.",
|
|
23
|
+
"Agents: walla login --cookie '<value>' --json",
|
|
24
|
+
"Never paste the cookie into a chat log.",
|
|
25
|
+
],
|
|
26
|
+
"say_to_user": (
|
|
27
|
+
f"Run `walla login`, then paste the Value of cookie "
|
|
28
|
+
f"`{_SESSION_COOKIE}` from https://es.wallapop.com "
|
|
29
|
+
"(Cookie-Editor, or DevTools -> Application -> Cookies)."
|
|
30
|
+
),
|
|
31
|
+
}
|
|
@@ -18,7 +18,8 @@ def instruct_recipe() -> dict[str, Any]:
|
|
|
18
18
|
"-> walla inbox."
|
|
19
19
|
),
|
|
20
20
|
"protocol": [
|
|
21
|
-
"Install: pipx install 'walla-cli[mcp]'
|
|
21
|
+
"Install from PyPI: pipx install 'walla-cli[mcp]' "
|
|
22
|
+
"(https://pypi.org/project/walla-cli/). Clone only if hacking.",
|
|
22
23
|
"walla doctor --json - never print tokens or cookies.",
|
|
23
24
|
"If no session: ask the human to run `walla login` and paste "
|
|
24
25
|
"__Secure-next-auth.session-token (or pass --cookie for non-interactive).",
|
|
@@ -1,56 +0,0 @@
|
|
|
1
|
-
"""Interactive login helpers (cookie paste primary)."""
|
|
2
|
-
|
|
3
|
-
from __future__ import annotations
|
|
4
|
-
|
|
5
|
-
import getpass
|
|
6
|
-
from typing import Any
|
|
7
|
-
|
|
8
|
-
import typer
|
|
9
|
-
|
|
10
|
-
from walla.account.cookies import SESSION_COOKIE
|
|
11
|
-
from walla.account.login import login_cookie_text, login_password
|
|
12
|
-
from walla.core.exceptions import WallaAuthError
|
|
13
|
-
from walla.models.account import SessionData
|
|
14
|
-
|
|
15
|
-
__all__ = ("interactive_login",)
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
def interactive_login(*, password: bool = False) -> SessionData:
|
|
19
|
-
"""Prompt for cookie paste, or email/password when ``password`` is True."""
|
|
20
|
-
if password:
|
|
21
|
-
return _prompt_password()
|
|
22
|
-
return _prompt_cookie()
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
def _prompt_cookie() -> SessionData:
|
|
26
|
-
typer.echo(
|
|
27
|
-
f"Paste {SESSION_COOKIE} (or a cookies.txt path), then Enter:\n"
|
|
28
|
-
" Tip: log in at es.wallapop.com → Cookie-Editor → copy that cookie."
|
|
29
|
-
)
|
|
30
|
-
raw = typer.prompt("cookie").strip()
|
|
31
|
-
if not raw:
|
|
32
|
-
raise WallaAuthError("empty paste")
|
|
33
|
-
return login_cookie_text(raw)
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
def _prompt_password() -> SessionData:
|
|
37
|
-
typer.echo(
|
|
38
|
-
"Password login often fails (MFA). Prefer: walla login (paste cookie)."
|
|
39
|
-
)
|
|
40
|
-
email = typer.prompt("email").strip()
|
|
41
|
-
pw = getpass.getpass("password: ")
|
|
42
|
-
try:
|
|
43
|
-
return login_password(username=email, password=pw)
|
|
44
|
-
except WallaAuthError:
|
|
45
|
-
typer.echo("Password rejected. Paste the session cookie instead.")
|
|
46
|
-
return _prompt_cookie()
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
def session_summary(sess: SessionData) -> dict[str, Any]:
|
|
50
|
-
return {
|
|
51
|
-
"authenticated": True,
|
|
52
|
-
"has_access_token": bool(sess.access_token),
|
|
53
|
-
"has_cookie": bool(sess.session_cookie),
|
|
54
|
-
"user_id": sess.user_id,
|
|
55
|
-
"micro_name": sess.micro_name,
|
|
56
|
-
}
|
|
@@ -1,26 +0,0 @@
|
|
|
1
|
-
"""User-visible fix recipes (not system prompts)."""
|
|
2
|
-
|
|
3
|
-
from __future__ import annotations
|
|
4
|
-
|
|
5
|
-
from typing import Any
|
|
6
|
-
|
|
7
|
-
__all__ = (
|
|
8
|
-
"cookie_export_fix",
|
|
9
|
-
)
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
def cookie_export_fix() -> dict[str, Any]:
|
|
13
|
-
return {
|
|
14
|
-
"title": "Paste Wallapop session cookie",
|
|
15
|
-
"steps": [
|
|
16
|
-
"Log in at https://es.wallapop.com in your browser.",
|
|
17
|
-
"Copy cookie __Secure-next-auth.session-token (Cookie-Editor).",
|
|
18
|
-
"Run: walla login",
|
|
19
|
-
"Paste the cookie value when prompted.",
|
|
20
|
-
"Agents: walla login --cookie '<value>' --json",
|
|
21
|
-
],
|
|
22
|
-
"say_to_user": (
|
|
23
|
-
"Run `walla login` and paste your "
|
|
24
|
-
"__Secure-next-auth.session-token cookie from es.wallapop.com."
|
|
25
|
-
),
|
|
26
|
-
}
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|