py-ptsl
Native Python PTSL (Pro Tools Scripting Library) RPC interface
Important Notice!
This software is developed by enthusiasts and is not a work of or supported by Avid. Developers who wish to contribute to this project should obtain the PTSL SDK from Avid's Developer site for the most current documentation and protobuf source files.
Example
See the examples directory for scripts demonstrating how to use the client.
- session_info.py - This example prints a list of gettable properties from the currently-open session.
- print_tracks.py - This example prints a list of every track in the currently-open session, including state information like selection, mute and solo state, track color and track ID.
- make_session.py - Creates a new session interactively from the terminal.
- pt_set.py - Allows several session setup options to be set from the terminal.
- pt_pasteboard.py - Demonstrates triggering cut/copy/paste actions.
- toolshell.py - Implements a command line interface for Pro Tools.
Sending Commands To Pro Tools with the Engine class
The Engine class exposes ptsl commands with a method call interface.
from ptsl import open_engine
with open_engine(company_name="MY_COMPANY", application_name="MY_TOOL") as engine:
session_name = engine.session_name()
Sending Commands to Pro Tools from the Command Line
The module implements a main function that can be called from the shell. Pass request JSON to the standard input and any response will be passed to standard output.
bash-3.2$ poetry run python3 -m ptsl GetTrackList <<JSON
{"pagination_request": {
"limit": 100, "offset": 0
},
"track_filter_list": [
{"filter": 0, "is_inverted": false}
]
}
JSON
{'pagination_response': {'total': 4, 'offset': 0, 'limit': 100}, 'track_list':
[{'name': 'Au dio 1', 'type': 'TT_Audio', 'format': 'TF_Mono', ...
bash-3.2$ poetry run python3 -m ptsl -n GetPTSLVersion
{"version": 2025}
Metadata
Release files for py-ptsl 602.0.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| py_ptsl-602.0.0.tar.gz | 92.7 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| py_ptsl-602.0.0-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 214.5 kB
Release files / py_ptsl-602.0.0.tar.gz
| Download URL | py_ptsl-602.0.0.tar.gz |
|---|---|
| Size | 92.7 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
3bf0e35bc36711274e7a323a2efe8cf61948c5ed45b6135850022334e80743de
|
|
BLAKE2b-256 checksum How to use checksums |
1ba4c318420de64ea706ea7daf5f5dd58ee9567159deebb29a4a28da2031b1bc
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/6.1.0 CPython/3.13.7
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Jul 25, 2026.
Transparency logRelease files / py_ptsl-602.0.0-py3-none-any.whl
| Download URL | py_ptsl-602.0.0-py3-none-any.whl |
|---|---|
| Size | 121.8 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
e2e949af66a602e54686e434f7c273b72136cc198111ce4048a1a0887d444314
|
|
BLAKE2b-256 checksum How to use checksums |
231ee49856f9309a57e959638a2fa6d5bebc2a719806affdc773b08b92c5b3b1
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/6.1.0 CPython/3.13.7
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Jul 25, 2026.
Transparency log