Skip to main content

SDK for KillB API V2

Project description

Kill-B Python SDK

This is the official Python SDK for interacting with the Kill-B API V2.


Installation

You can install the SDK via pip:

  pip install killb-sdk-python

Requirements

This SDK requires only the requests library. You can install it using pip:

  pip install requests

Usage

Authentication

To start using the SDK, you need to authenticate with your Kill-B API credentials:

from killb.client import Client

# ENVIRONMENT -> available environment is SANDBOX and PRODUCTION - please test first to go to PRODUCTION

# Replace with your environment, email, password, and API key
client = Client(environment="SANDBOX", email="your@email.com", password="your_password",
                api_key="your_api_key")

Creating a User

You can create a user using the User class:

    user_data = {
            "type": "PERSON",
            "data": {
                "firstName": "Bruce",
                "lastName": "Wayne",
                "dateOfBirth": "1982-01-28",
                "email": "wayne@batman.com",
                "phone": "+5511933222111",
                "document": {
                    "type": "PASSPORT",
                    "number": "BAT0001",
                    "issuedCountryCode": "US"
                },
                "address": {
                    "street1": "Street1",
                    "zipCode": "00315",
                    "city": "Gotham",
                    "countryCode": "US",
                    "state": "GO"
                }
            }
    }

    user_client = client.User.create(user_data)
    print("User created successfully:", user_client)

Creating Account

You can create account using the Account class:

    account_data = {
	"type": "SPEI",
	"userId": user["id"],
	"data": {
		"firstName": "Selina",
		"lastName": "Kyle",
        "phone": "+5511933222111",
        "email": "selina@cat.com",
        "bankCode": "1211",
        "countryCode": "MX",
        "clabe": "ASDFASDFASDFA",
		"document": {
            "type": "PASSPORT",
			"number": "CAT221122",
			"issuedCountryCode": "US"
		    }
	    }
    }

    account = client.Account.create(account_data)
    print("Account created successfully:", account)

For more detailed documentation and examples, please refer to the API documentation.

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

killb_sdk_python-1.0.4.tar.gz (10.8 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

killb_sdk_python-1.0.4-py3-none-any.whl (14.7 kB view details)

Uploaded Python 3

File details

Details for the file killb_sdk_python-1.0.4.tar.gz.

File metadata

  • Download URL: killb_sdk_python-1.0.4.tar.gz
  • Upload date:
  • Size: 10.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.0.1 CPython/3.12.8

File hashes

Hashes for killb_sdk_python-1.0.4.tar.gz
Algorithm Hash digest
SHA256 04aa6116caee5234c43d7cc2b197c8a638007d0422b23c0d7610dc3e251ffa8b
MD5 f8a380e267ee7514ac6ca9caf1afc278
BLAKE2b-256 ee146f8a893fd7ebd910cb3d7be1c3f5e288cc301c5131b5e08f6cebe6a108fc

See more details on using hashes here.

Provenance

The following attestation bundles were made for killb_sdk_python-1.0.4.tar.gz:

Publisher: publish.yml on Kill-B/sdk-python

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file killb_sdk_python-1.0.4-py3-none-any.whl.

File metadata

File hashes

Hashes for killb_sdk_python-1.0.4-py3-none-any.whl
Algorithm Hash digest
SHA256 f85f585a6af35d3e4032f9d822a0a776c24b01b88499ae86e5f228ecd8995358
MD5 0052650aa6c35664816191b88071b278
BLAKE2b-256 d1e267f77abb713cde2da95a35ca786177692e54fe52fbc42940f98620060edf

See more details on using hashes here.

Provenance

The following attestation bundles were made for killb_sdk_python-1.0.4-py3-none-any.whl:

Publisher: publish.yml on Kill-B/sdk-python

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

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