Giter Club home page Giter Club logo

bigc's Introduction

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

bigc's People

Contributors

r-thomson avatar d-llon avatar maxheyn avatar craigrobertwhite avatar ben-mig avatar iapetus-11 avatar aliyahsjones avatar atwalsh avatar fieryprophet avatar gnovack41 avatar juliuswalton avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.