User Profile API
Manage the current authenticated user's profile, preferences, and data.
Endpoints
| Method | Path | Description |
|---|---|---|
| GET | /api/me | Get current user |
| PATCH | /api/me | Update current user |
| POST | /api/me/export-data | Request GDPR data export |
| GET | /api/me/export-data | Get data export status/download |
| POST | /api/me/onboarding | Update onboarding status |
| GET | /api/me/onboarding | Get onboarding status |
Get Current User
GET /api/meExample
curl https://api.hookbase.app/api/me \
-H "Authorization: Bearer whr_your_api_key"Response
{
"user": {
"id": "33333333-3333-4333-8333-333333333333",
"email": "user@example.com",
"displayName": "John Doe",
"avatarUrl": null,
"twoFactorEnabled": false,
"emailVerified": true,
"createdAt": "2024-01-01T00:00:00Z"
},
"organizations": [
{
"id": "eeeeeeee-eeee-4eee-8eee-eeeeeeee0002",
"name": "My Company",
"slug": "my-company",
"plan": "pro",
"role": "owner",
"member_count": 5,
"source_count": 10,
"destination_count": 8,
"route_count": 15
}
]
}Update Current User
PATCH /api/meRequest Body
| Field | Type | Description |
|---|---|---|
| displayName | string | Display name |
| avatarUrl | string | Avatar URL |
Example
curl -X PATCH https://api.hookbase.app/api/me \
-H "Authorization: Bearer whr_your_api_key" \
-H "Content-Type: application/json" \
-d '{
"displayName": "John D."
}'Response
Returns the updated user object.
GDPR Data Export
Request Export
POST /api/me/export-dataExports every record Hookbase holds for your account across all organizations you belong to.
Most accounts get the export back immediately: the response body is the export, served as a
file download with Content-Type: application/json and a
Content-Disposition: attachment; filename="hookbase-data-export-YYYY-MM-DD.json" header. There is
no separate download step.
A completed export is cached for 24 hours, so repeating the request inside that window returns the same blob without regenerating it.
Example
curl -X POST https://api.hookbase.app/api/me/export-data \
-H "Authorization: Bearer whr_your_api_key" \
-OJResponse — small and medium accounts (200)
The export document itself. Top-level keys include user, organizations, events,
deliveries, cronExecutions, auditLogs, outboundEvents and outboundMessages; webhook
payloads are inlined.
Response — large accounts (202)
Accounts whose export needs more payload fetches than can be done inside one request are handed to a background worker instead:
{
"status": "processing",
"jobId": "33333333-3333-4333-8333-333333333333",
"totalRecords": 184203,
"hydrationTotal": 9144,
"message": "Your account has a lot of data — we're generating your export in the background. Check back shortly."
}Poll the status endpoint below, then re-issue POST /api/me/export-data once it reports a cached
export is available.
If an export is already running when you post again, you get the same 202 shape with
hydratedCount instead of totalRecords, and a message saying the export is already being
generated.
Check Export Status
GET /api/me/export-data/status{
"jobStatus": "completed",
"canExport": true,
"hydratedCount": 9144,
"hydrationTotal": 9144,
"hasCachedExport": true,
"cachedUntil": "2024-01-16T10:35:00Z",
"lastExportAt": "2024-01-15T10:35:00Z",
"errorMessage": null,
"totalRecords": 184203,
"breakdown": {
"events": 91000,
"deliveries": 88000,
"cronExecutions": 1200,
"auditLogs": 3559,
"outboundEvents": 244,
"outboundMessages": 200
}
}Export Statuses
jobStatus reports the most recent export job, or null if you have never requested one.
| Status | Description |
|---|---|
processing | A background export is still hydrating payloads. canExport is false until it finishes. |
completed | The last export finished. Check hasCachedExport and cachedUntil to see whether it is still servable. |
failed | The last export failed; errorMessage says why. Request a new one. |
Warning
There is no exportId field and no /api/me/export-data/{jobId}/download endpoint — the
export is returned by the POST itself. The jobId in a 202 response is only useful for matching
up log lines; it is not a download handle.
Onboarding
Get Onboarding Status
GET /api/me/onboardingResponse
{
"completed": false,
"steps": {
"createOrganization": true,
"createSource": true,
"createDestination": false,
"createRoute": false,
"receiveFirstEvent": false
}
}Update Onboarding
POST /api/me/onboarding| Field | Type | Description |
|---|---|---|
| step | string | Onboarding step to mark complete |
| skip | boolean | Skip the entire onboarding flow |
Related
- Authentication — Login, register, 2FA