{ nixpkgs ? import { }, pythonPkgs ? nixpkgs.pkgs.python39Packages }: let inherit (nixpkgs) pkgs; inherit pythonPkgs; selfprivacy-api = { buildPythonPackage, flask, flask-restful, setuptools, portalocker, flask-swagger, flask-swagger-ui, pytz, pytest, pytest-mock, pytest-datadir, huey, gevent }: buildPythonPackage rec { pname = "selfprivacy-api"; version = "1.1.1"; src = builtins.fetchGit { url = "https://git.selfprivacy.org/SelfPrivacy/selfprivacy-rest-api.git"; rev = "650032bdab5e7fa4556aaed5575a008c9d1db65d"; ref = "migrations-branch-fix"; }; propagatedBuildInputs = [ flask flask-restful setuptools portalocker flask-swagger flask-swagger-ui pytz pytest pytest-mock pytest-datadir huey gevent ]; meta = { description = '' SelfPrivacy Server Management API ''; }; }; drv = pythonPkgs.callPackage selfprivacy-api { }; in if pkgs.lib.inNixShell then drv.env else drv