Official Python SDK for the CrispHive API.
Project description
crisphive
Public REST API for integrating CrispHive from your own backend. Authenticate every request with a secret API key as a Bearer token (Authorization: Bearer chsk_live_…). The key prefix selects the data environment: chsk_live_… → production (live), chsk_test_… → sandbox (isolated test).
Key scopes (restricted keys). A key is either full-access (can call every endpoint below) or restricted to a set of permission codes chosen at creation — the same codes as the dashboard permission grid (e.g. customers_view, job_create, team_manage). A restricted key calling an endpoint outside its scope gets 403. The full code list is the permission catalog (GET /permission/modules on the dashboard API). Create, scope, and revoke keys from the business dashboard.
Every response is wrapped in the envelope { \"error_code\": 0, \"message\": \"Success\", \"data\": <payload> }.
This Python package is automatically generated by the OpenAPI Generator project:
- API version: 1.0
- Package version: 0.1.0
- Generator version: 7.11.0
- Build package: org.openapitools.codegen.languages.PythonClientCodegen
Requirements.
Python 3.8+
Installation & Usage
pip install
If the python package is hosted on a repository, you can install directly using:
pip install git+https://github.com/crisphive/crisphive-python.git
(you may need to run pip with root permission: sudo pip install git+https://github.com/crisphive/crisphive-python.git)
Then import the package:
import crisphive
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 crisphive
Tests
Execute pytest to run the tests.
Getting Started
Please follow the installation procedure and then run the following:
import crisphive
from crisphive.rest import ApiException
from pprint import pprint
# Defining the host is optional and defaults to https://api.crisphive.com/v1
# See configuration.py for a list of all supported configuration parameters.
configuration = crisphive.Configuration(
host = "https://api.crisphive.com/v1"
)
# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.
# Configure Bearer authorization (CrispHive secret key): ApiKeyAuth
configuration = crisphive.Configuration(
access_token = os.environ["BEARER_TOKEN"]
)
# Enter a context with an instance of the API client
with crisphive.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = crisphive.BusinessSkillApi(api_client)
page = 56 # int | Page number (default: 1) (optional)
limit = 56 # int | Page size (default: 15, max: 1000) (optional)
try:
# List skill categories
api_response = api_instance.list_skill_categories(page=page, limit=limit)
print("The response of BusinessSkillApi->list_skill_categories:\n")
pprint(api_response)
except ApiException as e:
print("Exception when calling BusinessSkillApi->list_skill_categories: %s\n" % e)
Documentation for API Endpoints
All URIs are relative to https://api.crisphive.com/v1
| Class | Method | HTTP request | Description |
|---|---|---|---|
| BusinessSkillApi | list_skill_categories | GET /skill-categories | List skill categories |
| BusinessSkillApi | list_skills | GET /skills | List all skills |
| BusinessSkillApi | list_skills_by_category | GET /skill-categories/{id}/skills | List skills in a category |
| CustomerApi | create_customer | POST /customers | Create a customer |
| CustomerApi | delete_customer | DELETE /customers/{id} | Delete a customer |
| CustomerApi | get_customer | GET /customers/{id} | Get a customer |
| CustomerApi | list_customers | GET /customers | List customers |
| CustomerApi | update_customer | PUT /customers/{id} | Update a customer |
| JobRequestBusinessApi | create_job_request | POST /job-requests | Create a job request (business actor) |
| JobRequestBusinessApi | get_job_request | GET /job-requests/{id} | Get a job request |
| JobRequestBusinessApi | get_job_request_timeline | GET /job-requests/{id}/timeline | Job timeline (business surface — also serves tech via BusinessAuth) |
| JobRequestBusinessApi | list_job_request_booking_windows | GET /job-requests/booking-windows | Booking availability (business actor) |
| JobRequestBusinessApi | list_job_request_changes | GET /job-requests/changes | Poll for new & changed job requests (sync feed) |
| JobRequestBusinessApi | list_job_requests | GET /job-requests | List job requests |
| JobTypesApi | get_job_type | GET /job-types/{id} | Get a job type |
| JobTypesApi | list_job_types | GET /job-types | List job types |
| ServiceAreaApi | get_service_area | GET /service-areas/{id} | Get a service area |
| ServiceAreaApi | list_service_areas | GET /service-areas | List service areas |
| TechnicianApi | get_technician | GET /technicians/{id} | Get a technician |
| TechnicianApi | list_technicians | GET /technicians | List technicians |
| VehicleApi | get_vehicle | GET /vehicles/{id} | Get a vehicle |
| VehicleApi | list_vehicles | GET /vehicles | List vehicles |
Documentation For Models
- CreateCustomer200Response
- CreateJobRequest200Response
- Customer
- CustomerAddress
- CustomerAddressRequest
- CustomerContact
- CustomerCreateRequest
- CustomerCreateResponse
- CustomerList
- CustomerListItem
- CustomerProfile
- CustomerSpending
- CustomerTierProgress
- CustomerUpdateRequest
- GetCustomer200Response
- GetJobRequest200Response
- GetJobRequestTimeline200Response
- GetJobType200Response
- GetServiceArea200Response
- GetTechnician200Response
- GetVehicle200Response
- JobDate
- JobDateBusinessRange
- JobDatePeriod
- JobDatePeriodEntry
- JobRequest
- JobRequestActionAuditBy
- JobRequestActionAuditEntry
- JobRequestActionSummary
- JobRequestAddressSummary
- JobRequestArchiveSummary
- JobRequestArrivalWindow
- JobRequestAssignedVehicle
- JobRequestAssignmentSummary
- JobRequestBookingWindows
- JobRequestBusinessTimeRange
- JobRequestChanges
- JobRequestCreateRequest
- JobRequestCreateResponse
- JobRequestCrewMember
- JobRequestCustomerSummary
- JobRequestDayWindows
- JobRequestJobDateBusinessRangeRequest
- JobRequestJobDatePeriodRequest
- JobRequestJobDateRequest
- JobRequestList
- JobRequestPeriod
- JobRequestQuoteSummary
- JobRequestRatingSummary
- JobRequestSchedule
- JobRequestSession
- JobRequestSkillSummary
- JobRequestStatusSummary
- JobRequestTechnicianInfo
- JobRequestTimeline
- JobRequestTimelineAction
- JobRequestTimelineEvent
- JobType
- ListCustomers200Response
- ListJobRequestBookingWindows200Response
- ListJobRequestChanges200Response
- ListJobRequests200Response
- ListJobTypes200Response
- ListServiceAreas200Response
- ListSkillCategories200Response
- ListSkills200Response
- ListSkillsByCategory200Response
- ListTechnicians200Response
- ListVehicles200Response
- Pagination
- ResponseEnvelope
- ServiceArea
- ServiceAreaList
- Skill
- SkillByCategoryList
- SkillCategory
- SkillCategoryList
- SkillList
- SkillSummary
- Technician
- TechnicianAddress
- TechnicianLeadRef
- TechnicianList
- TechnicianServiceAreaRef
- TechnicianStatus
- Vehicle
- VehicleList
- VehicleOwner
Documentation For Authorization
Authentication schemes defined for the API:
ApiKeyAuth
- Type: Bearer authentication (CrispHive secret key)
Author
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file crisphive-0.1.0.tar.gz.
File metadata
- Download URL: crisphive-0.1.0.tar.gz
- Upload date:
- Size: 66.7 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.13.9
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
ce6c252b63bb266b3ac021b9a84ec2bc1b27b084264670763c646e1faeff3917
|
|
| MD5 |
fe2ba2d573f984c40d0ec316fee5949b
|
|
| BLAKE2b-256 |
da3be1d759b347c250060bd736e2991b0971c7c764083b0d1fde222c04e0b024
|
File details
Details for the file crisphive-0.1.0-py3-none-any.whl.
File metadata
- Download URL: crisphive-0.1.0-py3-none-any.whl
- Upload date:
- Size: 226.7 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.13.9
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
8f2601dd0f74aedfa06aed0b08d387c132bfe871a5e02cb3167c0f6e88d97297
|
|
| MD5 |
e5f2bd67fddc5aad488236f5aaa6d122
|
|
| BLAKE2b-256 |
772b988afe508d513048f1469808f19b80fbf1ae405955f34ab6797e930fdeef
|