Skip to main content

CashCtrl API Client

Project description

cashctrl

Unofficial python client for the cashctrl api v1

The goal was to make it easy, easier, easiest :smile::

import cashctrl
cc=cashctrl.Client()
people=cc.person.list()

Quickstart

1. Create role

According to the [principle of least privilegue](https://en.wikipedia.org/wiki/Principle_of_least_privilege it is recommended to create a seperate role for the admin user.

Then you can give it the exact permission it needs:add-role

2. Create API-User

Now we can create the api user and copy the api-key: add-user

3. Add credentials to your environment

Create the .env file and add your api-key, organization and language:

cp .env.example .env && open .env

Make sure your .env file is in a safe place

4. have fun

from cashctrl_py import CashCtrlClient
from icecream import ic

cc = CashCtrlClient()
people = cc.person.list()
ic(people)

Contribute

Submit a Pull Request

There is still much work to do 😔

If you want to contribute, please fork the repository and create a pull request. gh repo fork <USER>/cashctrl-py

Dynamic install

For development you can install this library dynamically with the following command:

pip3 install -e /path/to/cashctrl-py

Now you can import it normally in other projects and changes in cashctrl-py get reflected immediately in all importing projects.

Swagger

There is an unofficial swagger.json file to help with development. You can export it into your http-client i.e. insomnia.

IDE

The Project was developed in Vscode. You can install the recommended extensions when you first open the project:

install-extensions

Upload

  1. increment version number
  2. upload:
./upload.sh

Also see: Package Tutorial

.env

Make sure you don't put a .env file in the sources folder. It is dangerous because all projects that have importet cashctrl-py with pip -e will then use that file instead of their own...

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

cashctrl-0.0.14.tar.gz (218.6 kB view details)

Uploaded Source

Built Distribution

cashctrl-0.0.14-py3-none-any.whl (14.1 kB view details)

Uploaded Python 3

File details

Details for the file cashctrl-0.0.14.tar.gz.

File metadata

  • Download URL: cashctrl-0.0.14.tar.gz
  • Upload date:
  • Size: 218.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.11.11

File hashes

Hashes for cashctrl-0.0.14.tar.gz
Algorithm Hash digest
SHA256 bb1ce521680c0bf90c3cf177039398692c9f165c03af94078558c8909215c857
MD5 7f4f8af940c2ca04c9991126746781a5
BLAKE2b-256 e324196f48c926bf78a554d77af61443fb916ef61e4c38c5115a0fc5250341fb

See more details on using hashes here.

File details

Details for the file cashctrl-0.0.14-py3-none-any.whl.

File metadata

  • Download URL: cashctrl-0.0.14-py3-none-any.whl
  • Upload date:
  • Size: 14.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.11.11

File hashes

Hashes for cashctrl-0.0.14-py3-none-any.whl
Algorithm Hash digest
SHA256 95cb25e1938b5553f18af6f0ec78dae66b7b66be182e342f9689cf3a260a3e3c
MD5 2f0e8d71ca8f93ed313e25122396fbcd
BLAKE2b-256 3f6b1812843930fed9b9e0bdf2107be4d421ba0dd1a3706a4ec83077e5b24c8f

See more details on using hashes here.

Supported by

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