Applications¶
-
class
steampak.libsteam.resources.apps.
Applications
¶ Exposes methods to get applications data.
-
current
= <steampak.libsteam.resources.apps.CurrentApplication object>¶ Interface to current application.
print(api.apps.current.language_current)
-
installed
= <steampak.libsteam.resources.apps.InstalledApplications object>¶ Interface to installed applications.
for app_id, app in api.apps.installed(): print('%s: %s' % (app_id, app.name))
-
Current Application¶
-
class
steampak.libsteam.resources.apps.
CurrentApplication
¶ Exposes methods to get current application data.
Interface can be accessed through
api.apps.current
.from steampak import SteamApi api = SteamApi(LIBRARY_PATH, app_id=APP_ID) print(api.apps.current.language_current)
-
achievements
= <steampak.libsteam.resources.stats.CurrentApplicationAchievements object>¶ Current application (game) achievements.
for ach_name, ach in api.apps.current.achievements(): print('%s: %s' % (ach_name, ach.title))
-
beta_name
¶ Current beta branch name, ‘public’ is the default branch.
Return type: str
-
build_id
¶ Current application Build ID. This may change at any time based on backend updates.
Warning
Restricted interface can only be used by approved apps.
Return type: int
-
dlcs
= <steampak.libsteam.resources.apps.CurrentApplicationDlcs object>¶ Interface to DLCs of current application.
for dlc_id, dlc in api.apps.current.dlcs(): print('%s: %s' % (dlc_id, dlc.name))
-
install_dir
¶ Returns application installation path.
Note
If fails this falls back to a restricted interface, which can only be used by approved apps.
Return type: str
-
installed
¶ True
if app is installed (not necessarily owned).Return type: bool
-
language_available
¶ List of available game languages.
E.g.: [‘english’, ‘russian’]
Return type: list[str]
-
language_current
¶ Current game language.
E.g.: english
Return type: str
-
low_violence
¶ True
if the current app is low violence.Return type: bool
-
mark_corrupt
(only_files_missing=False)¶ Signal Steam that game files seems corrupt or missing.
Parameters: only_files_missing (bool) – Set it to True if only files are missing. Return type: bool
-
mode_cybercafe
¶ True
if the current app supports Valve Cybercafe Program.Return type: bool
-
mode_free_weekend
¶ True
if the user is subscribed to the current app through a free weekend.Will return
False
for users who have a retail or other type of license.Note
Before using, please ask your Valve technical contact how to package and secure your free weekened.
Return type: bool
-
name
¶ Application name, or None on error.
Warning
Restricted interface can only be used by approved apps.
Return type: str
-
owned
¶ True
if user owns the current app.Return type: bool
-
purchase_time
¶ Date and time of app purchase.
Return type: datetime
-
vac_banned
¶ True
if the current app is banned by BIsVACBanned.Return type: bool
-
Application¶
-
steampak.
SteamApplication
¶ alias of
Application
-
class
steampak.libsteam.resources.apps.
Application
(app_id)¶ Exposes methods to get application data.
Aliased as
steampak.SteamApplication
.from steampak import SteamApplication # We use `Spacewar` app ID. (This game is provided with SDK). my_app = SteamApplication(480)
Parameters: app_id (int|None) – Application (game) ID. -
build_id
¶ Application Build ID. This may change at any time based on backend updates.
Warning
Restricted interface can only be used by approved apps.
Return type: int
-
install_dir
¶ Returns application installation path.
Note
If fails this falls back to a restricted interface, which can only be used by approved apps.
Return type: str
-
installed
¶ True
if app is installed (not necessarily owned).Return type: bool
-
name
¶ Application name, or None on error.
Warning
Restricted interface can only be used by approved apps.
Return type: str
-
owned
¶ True
if user owns the current app.Warning
Only use this member if you need to check ownership of a game related to yours, a demo for example.
Return type: bool
-
purchase_time
¶ Date and time of app purchase.
Return type: datetime
-
DLC¶
-
steampak.
SteamDlc
¶ alias of
Dlc
-
class
steampak.libsteam.resources.apps.
Dlc
(app_id)¶ Exposes methods to get downloadable content (DLC) data.
Aliased as
steampak.SteamDlc
.from steampak import SeamDlc # We use `Spacewar` DLC app ID. (Spacewar game is provided with SDK). my_dlc = SeamDlc(110902)
Current application DLCs are available through
CurrentApplication.dlcs
.-
available
¶ True if DLC is available.
Return type: bool
-
build_id
¶ Application Build ID. This may change at any time based on backend updates.
Warning
Restricted interface can only be used by approved apps.
Return type: int
-
get_download_progress
()¶ Returns tuple with download progress (for optional DLCs):
(bytes_downloaded, bytes_total)Return type: tuple
-
install
()¶ Installs DLC (for optional DLCs).
-
install_dir
¶ Returns application installation path.
Note
If fails this falls back to a restricted interface, which can only be used by approved apps.
Return type: str
-
installed
¶ True
if the user owns the DLC & if the DLC is installed.Return type: bool
-
name
¶ DLC name.
Return type: str
-
owned
¶ True
if user owns the current app.Warning
Only use this member if you need to check ownership of a game related to yours, a demo for example.
Return type: bool
-
purchase_time
¶ Date and time of app purchase.
Return type: datetime
-
uninstall
()¶ Uninstalls DLC (for optional DLCs).
-