API Reference
Complete REST API documentation for developers
Harper REST API
The Harper API allows you to programmatically track conversions, retrieve attribution data, and manage your stores. Our RESTful API uses standard HTTP methods and returns JSON responses.
Base URL
https://api.harper.com/v1All API requests must be made over HTTPS. Requests over plain HTTP will be rejected.
Quick Start
1. Get Your API Key
Navigate to Dashboard → Settings → API Keys and create a new API key.
2. Make Your First Request
Use your API key in the Authorization header:
curl -X GET https://api.harper.com/v1/stores \ -H "Authorization: Bearer YOUR_API_KEY" \ -H "Content-Type: application/json"
3. Handle the Response
All successful responses return JSON with a 200 OK status:
{
"success": true,
"data": {
"stores": [
{
"id": "store_123",
"name": "My Store",
"platform": "shopify",
"status": "active"
}
]
}
}API Endpoints
Authentication
API key management, OAuth flows, and session handling.
Tracking API
Track clicks, conversions, and events programmatically.
Analytics API
Retrieve attribution data, metrics, and custom reports.
Store Management
Create, update, and manage connected stores.
Webhooks
Receive real-time notifications for events.
Rate Limits
Understanding API rate limits and best practices.
Authentication
Harper uses API key authentication. Include your API key in the Authorization header with the Bearer scheme:
Authorization: Bearer wt_live_1234567890abcdef
API Key Types
- •Live keys (
wt_live_...) - Use in production to track real conversions - •Test keys (
wt_test_...) - Use in development for testing without affecting live data
Response Format
Success Response
{
"success": true,
"data": {
// Response data here
},
"meta": {
"timestamp": "2026-01-31T06:00:00Z",
"requestId": "req_abc123"
}
}Error Response
{
"success": false,
"error": {
"code": "invalid_request",
"message": "Missing required parameter: storeId",
"details": {
"field": "storeId",
"reason": "required_field_missing"
}
},
"meta": {
"timestamp": "2026-01-31T06:00:00Z",
"requestId": "req_abc123"
}
}HTTP Status Codes
| Status Code | Meaning |
|---|---|
| 200 OK | Request successful |
| 201 Created | Resource created successfully |
| 400 Bad Request | Invalid parameters or malformed request |
| 401 Unauthorized | Invalid or missing API key |
| 403 Forbidden | Valid API key but insufficient permissions |
| 404 Not Found | Resource not found |
| 429 Too Many Requests | Rate limit exceeded |
| 500 Server Error | Something went wrong on our end |
Pagination
List endpoints support pagination using limit and cursor parameters:
GET /v1/conversions?limit=100&cursor=abc123
Response with Pagination
{
"success": true,
"data": {
"conversions": [ /* array of conversions */ ],
"hasMore": true,
"nextCursor": "def456"
}
}SDKs and Libraries
We provide official SDKs to make integration easier:
Explore the API
Need API Help?
Our developer support team is here to help with API integration questions.
Previous
← Previous ArticleNext
Next Article →