Skip to main content

Unofficial client for the BigCommerce API

Project description

bigc

An unofficial Python client for the BigCommerce API.

This project is currently in an alpha state.

Installation

pip install bigc 

Usage

To authenticate, you'll need the BigCommerce store's hash and an access token.

from bigc import BigCommerceAPI


store_hash = '000000000'
access_token = '0000000000000000000000000000000'
bigcommerce = BigCommerceAPI(store_hash, access_token)

order: dict = bigcommerce.orders.get(101)
orders: list[dict] = list(bigcommerce.orders.all(customer_id=1))

The following resources are currently supported:

  • carts
  • categories
  • checkouts
  • customer_groups
  • customers
  • orders
  • products
  • product_variants
  • webhooks

Direct API Access

For resources or parameters that aren't officially supported yet, bigc also includes a flexible API client that can be used to make direct requests to the BigCommerce API.

bigcommerce = BigCommerceAPI(store_hash, access_token)

product = bigcommerce.api.v3.get('/products/77', params={'include': 'videos'})
order_messages = bigcommerce.api.v2.get_many('/orders/101/messages')

Utilities

Some extra utility functions that don't interact with the BigCommerce API are available in bigc.utils.

  • bigc.utils.parse_rfc2822_date: Convert an RFC-2822 date (used by some BigCommerce APIs) to a datetime

Constants

For convenience, some constants are made available in bigc.data.

  • bigc.data.BigCommerceOrderStatus: An Enum of order statuses and their IDs

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

bigc-0.2.16.tar.gz (9.7 kB view details)

Uploaded Source

Built Distribution

bigc-0.2.16-py3-none-any.whl (15.6 kB view details)

Uploaded Python 3

File details

Details for the file bigc-0.2.16.tar.gz.

File metadata

  • Download URL: bigc-0.2.16.tar.gz
  • Upload date:
  • Size: 9.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/2.1.2 CPython/3.9.22 Linux/6.11.0-1012-azure

File hashes

Hashes for bigc-0.2.16.tar.gz
Algorithm Hash digest
SHA256 f7f3e1de141b38d242fbbe95bbf594546774aa21cbba2d102842146d1cba34ad
MD5 c0fe48aaf23ed3db77ffbe8155f41503
BLAKE2b-256 f566079f5ae104c72c067880b5de7b773c1f601a60826d0bd9c0fc1b4f774683

See more details on using hashes here.

File details

Details for the file bigc-0.2.16-py3-none-any.whl.

File metadata

  • Download URL: bigc-0.2.16-py3-none-any.whl
  • Upload date:
  • Size: 15.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/2.1.2 CPython/3.9.22 Linux/6.11.0-1012-azure

File hashes

Hashes for bigc-0.2.16-py3-none-any.whl
Algorithm Hash digest
SHA256 3a8586ce06b2f3a0e5beb490054fc384f0699489221bb500950b3f0248fd1ce9
MD5 dcf000c5f74a65a1f6611042671301db
BLAKE2b-256 b876a8989c7b5b62b2911e2675779d8a531755f7f1a0a4500bdb330e413e624f

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