Skip to main content

Python client for the SFTPGo API

Project description


PyPI License Code style

Python client for the SFTPGo API

The sftpgo_client.base package is automatically generated from the OpenAPI specification provided by SFTPGo using openapi-python-client.


pip install sftpgo-client


  • Creating a client:
from sftpgo_client import Client

client = Client(
    base_url="http://localhost:8080/api/v2", user="admin", password="password"

In an asyncio environment, use the asynchronous client instead:

from sftpgo_client import AsyncClient

client = AsyncClient(
    base_url="http://localhost:8080/api/v2", user="admin", password="password"
  • Listing users:
users = client.get_users()
for user in users:

or with the asynchronous client:

users = await client.get_users()
for user in users:

All API endpoints are available in both the synchronous and asynchronous clients.

  • Adding a new user:
from sftpgo_client import User

user = User.from_dict(
        "username": "user",
        "password": "password",
        "permissions": {"/": ["*"]},


You can fetch the latest version of the SFTPGo OpenAPI specification and update sftpgo_client.base with:


You can run the tests with:

docker-compose up -d

Project details

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

sftpgo-client-0.3.1.tar.gz (80.5 kB view hashes)

Uploaded source

Built Distribution

sftpgo_client-0.3.1-py2.py3-none-any.whl (237.2 kB view hashes)

Uploaded py2 py3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page