API Reference: Privacy-First Integration
What you’ll get out of this
- Complete API access to all DeelRx CRM functionality
- Privacy-first integration with no data mining or third-party sharing
- Neo API playground for testing endpoints and exploring capabilities
- Comprehensive documentation with examples and best practices
Welcome to the DeelRx CRM API. Where your integrations respect privacy as much as you do. Our RESTful API gives you programmatic access to all CRM functionality without the data mining.
Getting Started: The Smart Way
Base URL
All API requests go to:
https://api.deelrxcrm.app/api
No tracking pixels, no analytics cookies, no “telemetry.” Just clean API calls.
Try it now - Use the Neo API playground to test endpoints and explore the API without writing code.
Authentication with Aliases
Use your email alias + API token for authentication:
curl -H "Authorization: Bearer your_api_token" \
-H "X-User-Alias: [email protected]" \
https://api.deelrxcrm.app/api/customers
Why aliases in API calls? Same reason you used them to sign up. Compartmentalization and privacy.
Rate Limiting (Fair and Transparent)
No surprise throttling based on secret algorithms:
- Free plan: 100 requests/minute
- Pro plan: 1,000 requests/minute
- Enterprise: 10,000 requests/minute
Rate limit headers in every response:
X-RateLimit-Limit: 1000
X-RateLimit-Remaining: 999
X-RateLimit-Reset: 1640995200
Translation: We tell you exactly what you get, and you get exactly what we promise.
Making Requests: Keep It Simple
HTTP Methods That Make Sense
GET - Fetch data (customers, orders, inventory)
POST - Create new stuff (customers, products, sales)
PUT - Update existing records completely
PATCH - Update just specific fields
DELETE - Remove data (with proper confirmations)
Content Type
Always use application/json:
curl -X POST \
-H "Content-Type: application/json" \
-H "Authorization: Bearer your_token" \
-d '{"name": "Big Spender LLC", "phone": "+1-555-MONEY"}' \
https://api.deelrxcrm.app/api/customers
Pro tip: Our API validates everything but doesn’t require unnecessary fields. Name + contact method = valid customer.
Success Responses
Clean, consistent JSON structure:
{
"success": true,
"data": {
"id": "cust_123",
"name": "Big Spender LLC",
"phone": "+1-555-MONEY",
"suggestedCredit": 2500,
"pricingTier": "premium",
"createdAt": "2024-01-15T10:30:00Z"
},
"meta": {
"timestamp": "2024-01-15T10:30:00Z",
"requestId": "req_abc123"
}
}
Error Responses
Helpful errors, not cryptic codes:
{
"success": false,
"error": {
"code": "VALIDATION_ERROR",
"message": "Phone number looks sketchy",
"details": {
"field": "phone",
"value": "not-a-phone-number",
"suggestion": "Try format: +1-555-123-4567"
}
}
}
We actually help you fix the problem instead of just saying “400 Bad Request.”
Real-World Examples
Add a Customer (The Right Way)
# Minimal but effective
curl -X POST \
-H "Authorization: Bearer your_token" \
-d '{
"name": "Cash Money Enterprises",
"phone": "+1-555-CASH-NOW"
}' \
https://api.deelrxcrm.app/api/customers
AI immediately suggests:
- Credit limit: $1,500 (business entity detected)
- Pricing tier: “standard” (no purchase history yet)
- Payment terms: “net30” (business name suggests B2B)
Create a Product That Sells
curl -X POST \
-H "Authorization: Bearer your_token" \
-d '{
"name": "Premium Widget",
"cost": 15.00,
"price": 25.00,
"quantity": 50,
"reorderAt": 10
}' \
https://api.deelrxcrm.app/api/products
Response includes AI insights:
{
"success": true,
"data": {
"id": "prod_456",
"name": "Premium Widget",
"cost": 15.00,
"price": 25.00,
"margin": 40.0,
"inventoryValue": 750.00,
"aiInsights": {
"marginAssessment": "healthy",
"pricingOpportunity": "consider 10% increase",
"demandForecast": "steady"
}
}
}
Process a Sale (Fast)
curl -X POST \
-H "Authorization: Bearer your_token" \
-d '{
"customerId": "cust_123",
"items": [
{"productId": "prod_456", "quantity": 2, "price": 25.00}
],
"paymentMethod": "cash",
"total": 50.00
}' \
https://api.deelrxcrm.app/api/orders
Instant profit calculation, inventory update, and customer history update.
Simple Parameters
curl "https://api.deelrxcrm.app/api/customers?limit=25&offset=50"
Smart Response
{
"success": true,
"data": [...], // 25 customers
"pagination": {
"limit": 25,
"offset": 50,
"total": 247,
"hasMore": true,
"nextUrl": "/api/customers?limit=25&offset=75"
}
}
We give you the next URL so you don’t have to do math.
Filtering & Search: Find What Matters
Filter by What You Need
# Active customers with credit balances
curl "https://api.deelrxcrm.app/api/customers?status=active&creditBalance>0"
# Products running low
curl "https://api.deelrxcrm.app/api/products?quantity<reorderPoint"
# Overdue payments
curl "https://api.deelrxcrm.app/api/orders?status=overdue&daysOverdue>30"
Search That Works
# Find customers by name, phone, or email
curl "https://api.deelrxcrm.app/api/customers?search=big+spender"
# Search products by name or SKU
curl "https://api.deelrxcrm.app/api/products?search=widget"
Privacy in APIs
Data Minimization
Request only what you need:
curl "https://api.deelrxcrm.app/api/customers?fields=id,name,phone"
Smaller responses, faster performance, better privacy.
Configurable Privacy
Respect user privacy settings:
# This customer has minimal data storage enabled
curl "https://api.deelrxcrm.app/api/customers/cust_123"
# Response respects their privacy settings
{
"id": "cust_123",
"name": "Private Customer",
"contact": "+1-555-****", // Last 4 digits hidden
"privacyMode": "high"
}
No Third-Party Leaks
Your API calls don’t get logged by:
- Analytics services
- Marketing platforms
- Data brokers
- Government agencies (unless legally compelled)
APIs are private too. No data leaks, no sketchy vendors.
Error Handling: Actually Helpful
Standard HTTP Codes
200 - Success (got what you asked for)
201 - Created (new resource made)
400 - Bad Request (fix your request)
401 - Unauthorized (check your token)
403 - Forbidden (you can’t do that)
404 - Not Found (doesn’t exist)
429 - Rate Limited (slow down)
500 - Server Error (our fault, we’re fixing it)
Detailed Error Messages
{
"success": false,
"error": {
"code": "INSUFFICIENT_CREDIT",
"message": "Customer credit limit exceeded",
"details": {
"customerCredit": 1000.00,
"currentBalance": 750.00,
"availableCredit": 250.00,
"requestedAmount": 500.00,
"suggestion": "Reduce order or collect payment first"
}
}
}
We tell you exactly what’s wrong and how to fix it.
Rate Limiting: Fair and Predictable
How It Works
- Per-minute limits based on your plan
- Burst allowance for occasional spikes
- Gradual recovery rather than hard cutoffs
- Clear headers showing your status
When You Hit Limits
{
"success": false,
"error": {
"code": "RATE_LIMIT_EXCEEDED",
"message": "API rate limit exceeded",
"details": {
"limit": 1000,
"resetTime": "2024-01-15T10:31:00Z",
"retryAfter": 42,
"suggestion": "Consider upgrading to Enterprise for higher limits"
}
}
}
Pro tip: Enterprise customers get dedicated rate limits and can request increases.
Webhooks: Real-Time Updates
Available Events
Get notified when stuff happens:
customer.created - New customer added
customer.updated - Customer info changed
order.created - New order placed
order.completed - Order fulfilled
payment.received - Payment processed
inventory.low - Stock running low
Webhook Setup
curl -X POST \
-H "Authorization: Bearer your_token" \
-d '{
"url": "https://your-app.com/webhooks/deelrx",
"events": ["order.created", "payment.received"],
"secret": "your_webhook_secret"
}' \
https://api.deelrxcrm.app/api/webhooks
Webhook Payload
{
"event": "order.created",
"data": {
"orderId": "order_789",
"customerId": "cust_123",
"total": 125.50,
"paymentMethod": "cash"
},
"timestamp": "2024-01-15T10:30:00Z",
"signature": "sha256=abc123..." // Verify with your secret
}
SDKs & Libraries
Official SDKs (Privacy-Focused)
- JavaScript/Node.js:
npm install @deelrxcrm/api
- Python:
pip install deelrxcrm-api
- PHP:
composer require deelrxcrm/api-client
- Ruby:
gem install deelrxcrm
- Go:
go get github.com/deelrxcrm/go-client
All SDKs respect privacy settings and include built-in rate limiting.
Best Practices
- Use field selection to get only what you need
- Implement pagination for large datasets
- Cache responses appropriately (respect privacy settings)
- Use bulk operations when available
Security
- Always use HTTPS (we reject HTTP)
- Store API tokens securely (not in code)
- Rotate tokens regularly (we make this easy)
- Validate webhook signatures (prevent spoofing)
Privacy
- Request minimal data needed for your use case
- Respect user privacy settings in API responses
- Don’t log sensitive data from API responses
- Use aliases consistently across your integrations
The Bottom Line: Our API gives you the power to integrate DeelRxCRM with your existing tools while maintaining the same privacy-first principles that make DeelRxCRM different.
DeelRxCRM APIs: Your integrations, your data, your rules.