9 / 10

Using PyPI API TokensURL copied

Store your tokens in ~/.pypirc:

Copied
[distutils]
index-servers =
    pypi
    testpypi

[pypi]
username = __token__
password = pypi-YOUR-API-TOKEN-HERE

[testpypi]
username = __token__
password = pypi-YOUR-TESTPYPI-TOKEN-HERE

Then you can upload without entering credentials:

Copied
python -m twine upload dist/*