Skip to main content

allow using a common code-base to create a REST API and a CLI

Project description

ApiCli

ApiCli is a python library that allow using a common code-base to create a REST API and a CLI that can interact with your API.

TODOs

  • Create endpoint from route defined using decorators
  • Propose at least bearer authentication from API side
  • Expose API endpoints to manage authentication when enabled
  • Define commands to authenticate from CLI

Contribute

Install project dependencies using pipenv. This will install apicli in editable mode from local folder.

pipenv install

If you want to test generated openapi documentation, you can use swagger-ui.

  • If swagger-ui/ submodule is empty, init submodule using this command
git submodule update --init
  • Then in swagger-ui/ folder, install dependencies and run web interface with command
npm run dev

By default, swagger-ui will be served at http://localhost:3200

  • If you want UI to automatically open the specs from your local apicli server, edit swagger-ui/dev-helpers/index.html

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

apicli-0.0.4.tar.gz (3.8 kB view details)

Uploaded Source

Built Distribution

apicli-0.0.4-py3-none-any.whl (4.9 kB view details)

Uploaded Python 3

File details

Details for the file apicli-0.0.4.tar.gz.

File metadata

  • Download URL: apicli-0.0.4.tar.gz
  • Upload date:
  • Size: 3.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.6.0 requests/2.24.0 setuptools/49.2.1 requests-toolbelt/0.9.1 tqdm/4.50.2 CPython/3.9.0

File hashes

Hashes for apicli-0.0.4.tar.gz
Algorithm Hash digest
SHA256 5891ae90697fb5bd847fca13ec567b864f6dd8a364bd0972318f2fbf14c8ad2b
MD5 aac588e2e9d2455c57f9e69ec86073bb
BLAKE2b-256 4b82dea99fc4262098a6bb808ccf0ada910459c662ea7117bc9f4ff4107da712

See more details on using hashes here.

File details

Details for the file apicli-0.0.4-py3-none-any.whl.

File metadata

  • Download URL: apicli-0.0.4-py3-none-any.whl
  • Upload date:
  • Size: 4.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.6.0 requests/2.24.0 setuptools/49.2.1 requests-toolbelt/0.9.1 tqdm/4.50.2 CPython/3.9.0

File hashes

Hashes for apicli-0.0.4-py3-none-any.whl
Algorithm Hash digest
SHA256 f6362cb25af2b69fc54e10e5959d1128cb02883b0b5d52b99722b490eb32dc51
MD5 4182b97dc0834191eb78a077bb6255a4
BLAKE2b-256 e3ccb085567f89849cf3e5bb2bb340d32346b1498ba6e5a1c9666e2d93f1fe72

See more details on using hashes here.

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