1
0

Compare commits

...

12 Commits

Author SHA1 Message Date
f226b34fb3 Actually there's a reason 2025-08-22 22:33:54 +00:00
630e73dbad Add more information to README 2025-08-19 17:34:44 +00:00
eb98e8a37e Add version to __init__.py
I might be incredibly stupid, if there's any better way to do this because I'm currently referencing it twice which is like.. potentially decoupling.. let me know please ;-;
2025-08-19 02:54:25 -04:00
d66585b87b Add custom tracked AppSettings configuration option 2025-08-19 01:10:59 -04:00
8febbba940 Make assignment logic smarter, so that I am not beheaded 2025-08-19 01:10:28 -04:00
968feef80a bump version 2025-08-19 00:59:10 -04:00
fa2677cd6d none of this is used. go bye bye 2025-08-19 00:58:47 -04:00
105742820f do a little bit of this because i need to continue stroking my genius 2025-08-19 00:53:25 -04:00
00dbde4a81 Make these debug statements actually kind of make sense logically 2025-08-19 00:47:29 -04:00
7b4f0b3498 Update README to make more sense to a human 2025-08-19 00:32:50 -04:00
972ab251b9 MOAR DEBUG 2025-08-18 16:37:53 -04:00
495ded1e83 Update README a little bit
asdgafgfdsh
2025-08-18 15:57:48 -04:00
7 changed files with 26 additions and 21 deletions

1
.gitignore vendored
View File

@@ -2,7 +2,6 @@
config.py
# Ignore Poetry garbage
poetry.lock
__pycache__
# IDIOT! IDIOT IDIOT IDIOT!

View File

@@ -2,9 +2,12 @@
I was asked to make an AppSettings archiver, so this should work as a rough attempt ... for now.
# How to install
Copy `config.example.py` to `config.py`. Configure your destination directory, and your ROBLOSECURITY cookie if you wish to provide one. I would recommend using an alternate Roblox account, mostly out of precaution. Your ROBLOSECURITY is not transmitted to any other place than Roblox with this script.
Copy `config.example.py` to `config.py`. Configure your destination directory, and your ROBLOSECURITY cookie if you wish to provide one. I would recommend using an alternate Roblox account, mostly out of precaution. Your ROBLOSECURITY is not transmitted to any third party with this script, only Roblox will see your ROBLOSECURITY. Some additional configuration options if you want to configure them are for overwriting the AppSettings list with your own (it could really just be anything with JSON), and a log level if you want to make things a little noisier.
This project uses [Poetry](https://python-poetry.org/), which has very clear documentation on how to install it:
You will need Python 3.12 or later, so install it.. please.
1. `pip install pipx` to install PIPX
2. `pipx install poetry` to install Poetry under PIPX (You will have global access to Poetry, PIPX performs some gnarly isolation while still allowing global access to tools)
3. In this directory, run `poetry install`. This will install all dependencies required by AppSettings-archiver

View File

@@ -5,22 +5,15 @@ import logging
import sys
import json
VERSION = "0.0.1"
__version__ = "1.0.0"
# Load configuration
ROBLOSECURITY = config.roblosecurity or None
DST_DIR = config.dst_dir or './AppSettings'
LOG_LEVEL = config.log_level or 'INFO'
ROBLOSECURITY = getattr(config, 'roblosecurity', None)
DST_DIR = getattr(config, 'dst_dir', './AppSettings')
LOG_LEVEL = getattr(config, 'log_level', 'INFO')
# Collect AppSettings endpoints
AppSettings = {
"PCStudioApp": "https://clientsettingscdn.roblox.com/v2/settings/application/PCStudioApp",
"PCDesktopClient": "https://clientsettingscdn.roblox.com/v2/settings/application/PCDesktopClient",
"MacDesktopClient": "https://clientsettingscdn.roblox.com/v2/settings/application/MacDesktopClient",
"MacStudioClient": "https://clientsettingscdn.roblox.com/v2/settings/application/MacStudioApp",
"UWPApp": "https://clientsettingscdn.roblox.com/v2/settings/application/UWPApp",
"XboxClient": "https://clientsettingscdn.roblox.com/v2/settings/application/XboxClient",
"AndroidApp": "https://clientsettingscdn.roblox.com/v2/settings/application/AndroidApp",
}
AppSettings = getattr(config, 'CustomTrackedAppSettings', {"PCDesktopClient": "https://clientsettingscdn.roblox.com/v2/settings/application/PCDesktopClient", "MacDesktopClient": "https://clientsettingscdn.roblox.com/v2/settings/application/MacDesktopClient"})
# Prepare logs
if not os.path.exists("logs"):
@@ -37,6 +30,8 @@ log.setLevel(LOG_LEVEL)
log.addHandler(stdout_handler)
log.addHandler(logfile_handler)
log.info(f"AppSettings-archiver version {__version__} started")
if ROBLOSECURITY is None:
log.warning(f"{"#"*6} ROBLOSECURITY IS NOT SET, SOME FFLAGS MAY BE MISSING {"#"*6}")
@@ -46,12 +41,19 @@ if log.level == logging.DEBUG:
os.makedirs(DST_DIR, exist_ok=True)
for AppSetting in AppSettings:
log.debug(f"Processing {AppSetting}")
log.debug(f"Attempting to retrieve {AppSetting}")
response = requests.get(AppSettings[AppSetting], headers={"Cookie": f".ROBLOSECURITY={ROBLOSECURITY}"})
if response.status_code == 200:
log.info(f"Successfully retrieved {AppSetting}")
with open(os.path.join(DST_DIR, f"{AppSetting}.json"), "w") as f:
formatted_response = json.dumps(response.json(), indent=4)
log.debug(f"Response is {len(response.content)/(1<<10):,.0f} kilobytes")
formatted_response = json.dumps(response.json(), indent=4)
log.debug(f"Formatted {AppSetting}")
expected_path = os.path.join(DST_DIR, f"{AppSetting}.json")
with open(expected_path, "w") as f:
f.write(formatted_response)
log.debug(f"Wrote {AppSetting} to {expected_path}")
else:
log.error(f"Failed to retrieve {AppSetting}: {response.status_code}")

View File

@@ -5,4 +5,6 @@ roblosecurity = ""
dst_dir = "./AppSettings"
# Log levels
log_level = "INFO"
log_level = "INFO"
CustomTrackedAppSettings = None

View File

@@ -1,6 +1,6 @@
[project]
name = "appsettings-archiver"
version = "0.1.0"
version = "1.0.0"
description = ""
authors = [
{name = "dfault-user",email = "32969563+dfault-user@users.noreply.github.com"}
@@ -9,7 +9,6 @@ readme = "README.md"
requires-python = ">=3.12"
dependencies = [
"requests",
"dotenv",
]
[tool.poetry]

View File