Skip to main content
Join the official 2020 Python Developers SurveyStart the survey!

PassHub API Client

Project description

PassHub API Client

PassHub API documentation

Access PassHub with Python. This module offers high level and low level calls to the API.

Requirements.

Python 2.7 and 3.4+

Installation & Usage

pip install

If the python package is hosted on Github, you can install directly from Github

pip install sightseeingtech_passhub_api

(you may need to run pip with root permission: sudo pip install sightseeingtech_passhub_api)

Then import the package:

import sightseeingtech_passhub_api

Setuptools

Install via Setuptools.

python setup.py install --user

(or sudo python setup.py install to install the package for all users)

Then import the package:

import sightseeingtech_passhub_api

Getting Started

Please follow the installation procedure and then run the following:

from __future__ import print_function
import time
import sightseeingtech_passhub_api
from sightseeingtech_passhub_api.rest import ApiException
from pprint import pprint

configuration = Configuration()
configuration.api_key['X-Api-Key'] = 'YOUR_API_KEY'
configuration.host = 'YOUR_HOST'
configuration.verify_ssl = False

client = ApiClient(configuration)

try:
    productResourceApi = sightseeingtech_passhub_api.ProductResourceApi(client)

    print('Loading products...')

    products = productResourceApi.get_all_products()

    print('Product %d products is/are loaded.\n' % len(products))
except ApiException as e:
    print("Exception when calling ProductResourceApi->get_all_products: %s\n" % e)

Documentation for API Endpoints

Class Method HTTP request Description
OrderRecordResourceApi createOrderRecord POST /api/v1/orderRecords createOrderRecord
OrderRecordResourceApi getAllOrderRecords GET /api/v2/orderRecords getAllOrderRecords
OrderRecordResourceApi getOrderRecord GET /api/v1/orderRecords/{id} getOrderRecord
OrderRecordResourceApi mergeVouchers POST /api/v1/orderRecords/mergeVouchers mergeVouchers
OrderRecordResourceApi updateOrderRecord) PUT /api/v1/orderRecords updateOrderRecord
ProductResourceApi findProductsByVendor GET /api/v1/products/vendor/{vendorId} findProductsByVendor
ProductResourceApi getAllProducts GET /api/v2/products getAllProducts
VendorResourceApi getAllVendors GET /api/v2/vendors getAllVendors
VoucherResourceApi cancelValidation POST /api/v2/voucher/validate/cancel V2 Cancel validation for the voucher
VoucherResourceApi cancelVoucher POST /api/v1/voucher/cancel cancelVoucher
VoucherResourceApi convertVoucher POST /api/v1/voucher/convert convertVoucher
VoucherResourceApi validateVoucher POST /api/v2/voucher/validate [V2 Validates voucher which represents single order item or group of them.

Documentation For Authorization

X-Api-Key

  • Type: API key
  • API key parameter name: X-Api-Key
  • Location: HTTP header

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Files for sightseeingtech-passhub-api, version 1.0.0
Filename, size File type Python version Upload date Hashes
Filename, size sightseeingtech_passhub_api-1.0.0-py3-none-any.whl (85.2 kB) File type Wheel Python version py3 Upload date Hashes View
Filename, size sightseeingtech-passhub-api-1.0.0.tar.gz (42.2 kB) File type Source Python version None Upload date Hashes View

Supported by

Pingdom Pingdom Monitoring Google Google Object Storage and Download Analytics Sentry Sentry Error logging AWS AWS Cloud computing DataDog DataDog Monitoring Fastly Fastly CDN DigiCert DigiCert EV certificate StatusPage StatusPage Status page