Skip to main content

PyZohoBooksAPI

Usage:

  • Authentication:

    from PyZohoBooksAPI import ZohoAuth
    
    auth = ZohoAuth(
         client_id='your_client_id',
         client_secret='your_client_secret'
    )
    
    # generating token
    status, token = auth.generate_token(code='your_code')
    print(status)
    # >>> 200
    print(token)
    # >>> {'access_token': '1000.60062cb11995ad4c5395a31ae680fa09.d3438f753f4e64021aad100323e9cbb1', 'api_domain': 'https://www.zohoapis.com', 'token_type': 'Bearer', 'expires_in': 3600}
    
    # refreshing token
    status, refreshed_token = auth.refresh_token(refresh_token='1000.455b2011ed031afa48df852cfcfe7f9b.0aeb72a01ad1841ccbf5df8e548f9445'))
    print(status)
    # >>> 200
    print(refreshed_token)
    # >>> {'access_token': '1000.ce1d8d22982db8d5c80ea8c8903ca458.b53a0d99b4b0325f4ff554a8a452a92b', 'api_domain': 'https://www.zohoapis.com', 'token_type': 'Bearer', 'expires_in': 3600}
    
  • Contacts

    from PyZohoBooksAPI import Contacts
    
    contacts = Contacts(token='your_token', organization_id='your_organization_id')
    
    # getting all contacts
    status, all_contacts = contacts.contacts_list()
    print(status)
    # >>> 200
    print(all_contacts)
    # >>> list_of_your_contacts
    
    # get contacts by id:
    status, contact = contacts.get_contact(contact_id='3168296000000075177')
    print(contact)
    # >>> your_contact
    
    # check contacts by email:
    status, contact = contacts.check_by_email(email='marawan6569@gmail.com')
    print(contact)
    # >>> your_contact
    
    # creating new contact
    status, contact = contacts.create_contact(contact_data={})
    print(contact)
    # >>> your_contact
    
  • Invoices

    from PyZohoBooksAPI import Invoices
    
    invoices = Invoices(token='your_token', organization_id='your_organization_id')
    
    invoice = invoices.create_invoice(invoice_data={})
    invoice = invoices.email_an_invoice(invoice_id='your_invoice_id', email_data={})
    

Release files for PyZohoBooksAPI 0.0.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for PyZohoBooksAPI 0.0.1
File Size Uploaded
PyZohoBooksAPI-0.0.1.tar.gz 4.4 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for PyZohoBooksAPI 0.0.1
File Interpreter ABI Platform
PyZohoBooksAPI-0.0.1-py3-none-any.whl Python 3 none any Details

Total release size: 9.6 kB

Release files / PyZohoBooksAPI-0.0.1.tar.gz

Download URL PyZohoBooksAPI-0.0.1.tar.gz
Size 4.4 kB
Tags Source
SHA-256 checksum
How to use checksums
a16cb58088e357d740489824b035cc949212c23d40291e2e1e131efd1e356157
BLAKE2b-256 checksum
How to use checksums
7bdcbcca68a21d0cf838728ebffc99d7bb7415ede04ad5ed72c9c3ec147b5eb1
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.8.0 pkginfo/1.8.2 readme-renderer/34.0 requests/2.22.0 requests-toolbelt/0.9.1 urllib3/1.26.9 tqdm/4.63.1 importlib-metadata/4.11.3 keyring/18.0.1 rfc3986/2.0.0 colorama/0.4.3 CPython/3.8.10

Release files / PyZohoBooksAPI-0.0.1-py3-none-any.whl

Download URL PyZohoBooksAPI-0.0.1-py3-none-any.whl
Size 5.2 kB
Tags Python 3
SHA-256 checksum
How to use checksums
f2808b474a217863152c8b4168115441caee7e2931984bb1e64e6ee46fc99f98
BLAKE2b-256 checksum
How to use checksums
9b31d862c6059b471101a1ad1f94fcd07a72d7415954a16e8747ca7ad5f20abd
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.8.0 pkginfo/1.8.2 readme-renderer/34.0 requests/2.22.0 requests-toolbelt/0.9.1 urllib3/1.26.9 tqdm/4.63.1 importlib-metadata/4.11.3 keyring/18.0.1 rfc3986/2.0.0 colorama/0.4.3 CPython/3.8.10

Release history Release notifications | RSS feed

This release

0.0.1 This release

2 release files

0.0.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page