Antiviruses
Get information about antivirus engines and distribution packs configured in the sandbox.
import asyncio
from ptsandbox import Sandbox, SandboxKey
async def main():
sandbox = Sandbox(...)
await sandbox.ui.authorize()
engines = await sandbox.ui.get_av_engines()
print(engines)
asyncio.run(main())
ptsandbox.sandbox.ui._system.SystemMixin.get_av_engines
async
Get information about antivirus scanners
Returns:
-
SandboxAVEnginesResponse–A model with information about all antiviruses
Raises:
-
SandboxException–if not authorized or token refresh fails
-
ClientResponseError–if the server returns an error status
-
ClientError–on connection or transport errors
-
ValidationError–if the response body does not match the expected model
Get settings of a specific engine
import asyncio
from ptsandbox import Sandbox, SandboxKey
async def main():
sandbox = Sandbox(...)
await sandbox.ui.authorize()
engine = await sandbox.ui.get_av_engine("clamav")
print(engine)
asyncio.run(main())
ptsandbox.sandbox.ui._system.SystemMixin.get_av_engine
async
Get settings of a specific antivirus engine.
Parameters:
-
item_id(str) –antivirus identifier (engine code name, e.g.
"clamav")
Returns:
-
SandboxAVEngineSettingsResponse–A model with the antivirus settings
Raises:
-
SandboxException–if not authorized or token refresh fails
-
ClientResponseError–if the server returns an error status
-
ClientError–on connection or transport errors
-
ValidationError–if the response body does not match the expected model
Get distribution packs
import asyncio
from ptsandbox import Sandbox, SandboxKey
async def main():
sandbox = Sandbox(...)
await sandbox.ui.authorize()
packs = await sandbox.ui.get_av_distribution_packs()
print(packs)
asyncio.run(main())
ptsandbox.sandbox.ui._system.SystemMixin.get_av_distribution_packs
async
Get the list of antivirus distributions available for installation.
Returns:
-
SandboxAVDistributionPacksResponse–A model with the distribution packs
Raises:
-
SandboxException–if not authorized or token refresh fails
-
ClientResponseError–if the server returns an error status
-
ClientError–on connection or transport errors
-
ValidationError–if the response body does not match the expected model