Registry / crm-productivity / pyairtable

pyairtable

JSON →
library3.4.2pypypi✓ verified 26d ago

Official community Python client for the Airtable API. Formerly known as airtable-python-wrapper. Current version is 3.3.0 (Nov 2025). Has gone through major rewrites at 1.0, 2.0, and 3.0 — each with breaking changes. Many tutorials still reference the old airtable-python-wrapper package which is abandoned.

pip install pyairtable
INSTALL
IMPORT
SIG · PYAIRTABLE
P
pyairtable
crm-productivitypythonv3.4.2
Install
4.0s avg
Import
1470ms
Disk
31MB
Pass rate
10/ 10
Env Coverage10 / 10
glibc
3.93.13
musl
3.93.13
Install & Compatibility
Where this runs
tested against v3.4.2 · pip install
no network on importno background threads
Install × environment matrix
Each cell = how many times install + import succeeded across repeated harness runs. Partial = flaky.
glibc = Debian/Ubuntu slim · musl = Alpine Linux
musl
py 3.103.910 runs
installs and imports cleanly · install 0.0s · import 1.516s · 33MB
glibc
py 3.103.910 runs
installs and imports cleanly · install 4.0s · import 1.424s · 33MB
31MB installed
● package 31MB
Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

Api
from pyairtable import Api
from airtable import Airtable
airtable-python-wrapper is the old abandoned package. pyairtable is the maintained successor. Do not confuse the two.
Table
api = Api(api_key); table = api.table(base_id, table_name)
Table(api_key, base_id, table_name)
Passing raw strings to Table() constructor is deprecated since 2.0. Always construct via Api instance.

Minimal Airtable read/write using pyairtable 3.3.x.

from pyairtable import Api api = Api('YOUR_PERSONAL_ACCESS_TOKEN') # not API key — deprecated table = api.table('BASE_ID', 'TABLE_NAME') # fetch all records records = table.all() # create a record table.create({'Name': 'New Row', 'Status': 'Active'})
Debug
Known issues
breakingAirtable deprecated legacy API keys in January 2024. They no longer work. All code using api_key='key...' strings will fail with 401.
fix
Generate a Personal Access Token at airtable.com/create/tokens and use that instead. Scopes must be explicitly granted per base.
affects: all
breakingairtable-python-wrapper is the old abandoned package. Package name changed to pyairtable at 1.0.0. Installing airtable-python-wrapper gives you dead code.
fix
pip install pyairtable — not airtable or airtable-python-wrapper.
affects: all
breakingPydantic 1.x support dropped in pyairtable 3.x. Will fail to import if Pydantic 1.x is installed.
fix
pip install 'pydantic>=2.0'
affects: >= 3.0.0
breakingTable(api_key, base_id, table_name) constructor with raw strings deprecated in 2.0, raises TypeError in 3.0. Most tutorials and LLM-generated code still use this pattern.
fix
api = Api(token); table = api.table(base_id, table_name)
affects: >= 2.0.0
breakingpyairtable.metadata module removed in 3.0. Any code importing from it will fail.
fix
Use api.base(base_id).schema() for metadata access.
affects: >= 3.0.0
gotchaModel.save() return type changed from bool to SaveResult in 3.x. Code checking 'if record.save():' will break silently — SaveResult is always truthy.
fix
Check SaveResult.created or SaveResult.updated explicitly.
affects: >= 3.0.0
gotchareturn_fields_by_field_id= parameter renamed to use_field_ids= in 3.x.
fix
Replace return_fields_by_field_id=True with use_field_ids=True.
affects: >= 3.0.0
deprecatedPython 3.9 support dropped in 3.3.0 (Nov 2025).
fix
Use Python 3.10+.
affects: >= 3.3.0
breakingAirtable API returned 404 Not Found. This typically indicates an incorrect Base ID or Table Name in your configuration, or that the specified base/table does not exist or is not accessible with the provided token.
fix
Verify that the BASE_ID and TABLE_NAME used in your code are correct and correspond to an existing Airtable base and table. Ensure the Personal Access Token has appropriate scopes and permissions to access the specified base and table.
affects: all
Errors
Common errors & fixes
ModuleNotFoundError: No module named 'airtable' OR ImportError: cannot import name 'Airtable' from 'airtable'
You are trying to import the deprecated `airtable-python-wrapper` library, or you have `pyairtable` installed but are using the old import syntax.
fix
Ensure `pyairtable` is installed (`pip install pyairtable`) and update your import statements to use `from pyairtable import Api` or `from pyairtable import Table`.
AttributeError: 'Table' object has no attribute 'get_all'
The method `get_all()` was part of the older `airtable-python-wrapper` or earlier `pyairtable` versions; it has been renamed or replaced in newer `pyairtable` releases (e.g., by `all()` or `each()`).
fix
Replace `table.get_all()` with `table.all()` to retrieve all records or `table.each()` for an iterator, and update other method calls according to the current `pyairtable` API documentation.
HTTP 401 Unauthorized OR HTTP 403 Forbidden
Your Airtable API key or Personal Access Token (PAT) is invalid, missing, or lacks the necessary permissions for the requested operation or base.
fix
Verify that your API key/PAT is correct, has the required scopes (e.g., `data.records:read` for reading), and that you are using a Personal Access Token (API keys are deprecated). Ensure it's passed correctly, e.g., `api = Api('YOUR_PAT')` or via `os.environ['AIRTABLE_API_KEY']`.
TypeError: Table() takes X positional arguments but Y were given
The constructor signature for `pyairtable.Table` or `pyairtable.Api` has changed in a breaking release (e.g., from 1.x to 2.x or 2.x to 3.x), leading to an incorrect number of arguments being passed.
fix
Consult the `pyairtable` migration guide for your specific version change and update the `Table` or `Api` constructor calls. For `pyairtable` 2.0+, `Table` is typically instantiated as `Table(api_instance, base_id, table_name)` or `api.table(base_id, table_name)`.
Upgrade
Version history
3.4.2latest on PyPI · released Jul 26, 2026
Audit
Dependencies
pydantic>=2.0requiredPydantic 1.x support dropped in 3.x. Required for model validation.
Agent activity
47 hits · last 30 days
node
42
OpenAI (training)
1
Resources
pyairtable — pip install pyairtable · libregistry