SDK Quick Start
Ready to integrate? This guide will get you up and running with Kintsugi SDKs in just a few minutes.
Prerequisites
Before you begin, make sure you have:
Choose Your SDK
from kintsugi_tax import KintsugiClient
# Initialize the client
client = KintsugiClient(
api_key="your-api-key",
organization_id="your-org-id"
)
# Calculate tax for a transaction
tax_result = client.tax.estimate({
"line_items": [
{
"quantity": 1,
"price": 100.00,
"product_tax_code": "A_GEN_TAX"
}
],
"ship_to": {
"street_1": "123 Main St",
"city": "San Francisco",
"state": "CA",
"postal_code": "94105",
"country": "US"
}
})
print(f"Tax amount: ${tax_result.total_tax}")
Authentication
All SDKs use API key authentication. You can get your API key from the Kintsugi Platform.
Keep your API key secure - Never commit API keys to version control. Use environment variables or secure configuration management.
Environment Variables
Set your API key as an environment variable:
export KINTSUGI_API_KEY="your-api-key"
export KINTSUGI_ORGANIZATION_ID="your-org-id"
Then initialize the SDK without hardcoding credentials:
import os
from kintsugi import KintsugiClient
client = KintsugiClient(
api_key=os.getenv("KINTSUGI_API_KEY"),
organization_id=os.getenv("KINTSUGI_ORGANIZATION_ID")
)
Next Steps