-
Notifications
You must be signed in to change notification settings - Fork 0
T3 API : API Scripts
This lets you declare your dependencies at the top of the script using special comments. When run with uv run example.py
, uv automatically resolves and installs those dependencies in an isolated environment.
# /// script
# dependencies = [
# "t3api-utils",
# ]
# ///
from t3api_utils.main.utils import (get_authenticated_client_or_error,
pick_license)
api_client = get_authenticated_client_or_error()
license = pick_license(api_client=api_client)
print(license)
You can install dependencies into a standard Python virtual environment managed by uv venv
:
uv venv
source .venv/bin/activate
uv pip install t3api-utils
python example.py
from t3api_utils.main.utils import (get_authenticated_client_or_error,
pick_license)
api_client = get_authenticated_client_or_error()
license = pick_license(api_client=api_client)
print(license)
T3 supports various Python packages to make using the API easier:
t3api
is a wrapper around the entire T3 API. It allows you to authenticate and send requests in a structured way without needing to manually build HTTP requests.
t3api-utils
is a collection of pre-built utilities for solving common patterns. Utilities include automatic authentication, license selection, and loading entire collections in parallel.
t3py
is a command line program with prebuilt commands. It can be run with t3py [<command_name>]
.
- Refer to the T3 API documentation to explore all the available endpoints.
- Most API endpoints require a T3+ subscription. If you don't have a T3+ subscription, you can sign up here.
Created by Matt Frisbie
Contact: matt@trackandtracetools
Copyright © 2025 Track & Trace Tools. All rights reserved.
- Home
- FAQ
- Metrc
- T3 Chrome Extension
- T3 API
- OpenTag
- T3 Labels : Label Templates
- T3 Chrome Extension : Exports
- T3 Chrome Extension : Scan Sheets
- T3 Labels : Tutorial
- RFID
- T3 Chrome Extension : CSV Form Fill
- T3 Labels : Label Layouts
- T3+
- T3 API : Setting Up Python
- T3 Chrome Extension : T3+ Features
- T3 Labels : Printing Label PDFs
- T3 API : API Scripts
- T3 Chrome Extension : Label Studio
- T3 Chrome Extension : Primary Features
- T3 Chrome Extension : Getting Started
- T3 Labels
- T3 Labels : Generating Label PDFs
- T3 API : Reports and Spreadsheet Sync
- T3 API : Getting Started
- T3 Labels : Getting Started