Developer API Reference
The Credential Camp External API lets you read and write training compliance data — employees, courses, assignments, certificates, prerequisites, and continuing education — programmatically. Outbound webhooks notify your systems in real time when records change.
https://app.credentialcamp.com/api/external/v1All responses are JSON. Set Content-Type: application/json on write requests (or multipart/form-data for file uploads). Dates are ISO 8601 strings. IDs are UUIDs.
Authentication
The API supports two authentication methods: API Keys (simple, server-to-server) and OAuth 2.0 (delegated access on behalf of an admin user). Choose API Keys for backend integrations. Use OAuth when your app needs to act on behalf of specific tenant admins.
API Key Authentication
Generate an API key pair from Settings → Integrations → API Keys in your Credential Camp account. Send both headers with every request:
Required headersX-API-Key: cc_a1b2c3d4e5f6... # Key ID (starts with cc_)
X-API-Secret: your-secret-here # Secret key (shown once at creation)
X-Timestamp: 1718400000000 # Optional: Unix ms — enables replay protection
Example — curl
curl https://app.credentialcamp.com/api/external/v1/employees \
-H "X-API-Key: cc_a1b2c3d4e5f6" \
-H "X-API-Secret: your-secret-here"
Example — JavaScript
const response = await fetch('https://app.credentialcamp.com/api/external/v1/employees', {
headers: {
'X-API-Key': process.env.CC_API_KEY,
'X-API-Secret': process.env.CC_API_SECRET,
},
});
const { employees } = await response.json();
OAuth 2.0
For user-delegated access, Credential Camp implements OAuth 2.0 Authorization Code flow with PKCE, and Client Credentials for machine-to-machine integrations.
Authorization Code (user-delegated)
# 1 — Redirect user to consent screen
GET /oauth/authorize
?response_type=code
&client_id=YOUR_CLIENT_ID
&redirect_uri=https://yourapp.com/callback
&scope=employees:read+assignments:read
&state=random-csrf-token
&code_challenge=S256-PKCE-challenge
&code_challenge_method=S256
# 2 — Exchange code for token
POST /oauth/token
Content-Type: application/x-www-form-urlencoded
grant_type=authorization_code
&code=AUTH_CODE
&redirect_uri=https://yourapp.com/callback
&client_id=YOUR_CLIENT_ID
&code_verifier=PKCE_VERIFIER
Client Credentials (machine-to-machine)
POST /oauth/token
Content-Type: application/x-www-form-urlencoded
grant_type=client_credentials
&client_id=YOUR_CLIENT_ID
&client_secret=YOUR_CLIENT_SECRET
&scope=employees:read+assignments:read
Use the returned access_token as a Bearer token:
Authorization: Bearer eyJhbGciOiJIUzI1NiIs...
Scopes
API keys and OAuth tokens carry one or more scopes. The required scope is shown on each endpoint.
Errors & Rate Limits
HTTP Status Codes
| Code | Meaning |
|---|---|
200 | Success |
201 | Created |
204 | No content (successful delete) |
400 | Bad request — validation failed or missing required field |
401 | Unauthorized — missing or invalid credentials |
403 | Forbidden — valid credentials but insufficient scope |
404 | Resource not found or belongs to a different tenant |
429 | Rate limit exceeded |
500 | Internal server error |
Error Response Shape
{
"error": "Validation failed",
"details": {
"employeeId": ["Required"],
"courseId": ["Required"]
}
}
Rate Limits
API key requests are rate-limited to 1,000 requests per hour per key. OAuth tokens are limited to 1,000 requests per hour per client. Rate limit headers are included in every response:
X-RateLimit-Limit: 1000
X-RateLimit-Remaining: 994
X-RateLimit-Reset: 1718403600 # Unix timestamp when the window resets
When the limit is exceeded you receive a 429 with a retryAfter field (seconds to wait).
Employees
List all employees in your organization. Supports pagination and filtering.
Query Parameters
| Parameter | Type | Description |
|---|---|---|
| page | integer | Page number (default: 1) |
| limit | integer | Results per page (default: 50, max: 200) |
| locationId | uuid | Filter by location |
| jobTitleId | uuid | Filter by job title |
| status | string | ACTIVE | INACTIVE | TERMINATED |
| externalId | string | Filter by your HRIS system ID |
{ "employees": [ { "id": "...", "name": "Sam Block", "email": "sam@example.com", ... } ], "total": 42 }
Retrieve a single employee by ID.
Create a new employee. Triggers an employee.created webhook.
Request Body
| Field | Type | Required | Description |
|---|---|---|---|
| name | string | required | Full name |
| string | required | Email address (must be unique per tenant) | |
| locationId | uuid | optional | Location the employee belongs to |
| jobTitleId | uuid | optional | Job title for auto-assignment |
| externalId | string | optional | Your HRIS system ID (for sync matching) |
| phone | string | optional | Phone number |
| department | string | optional | Department name |
| hireDate | ISO date | optional | Date of hire |
| employmentStatus | string | optional | ACTIVE (default) | INACTIVE | TERMINATED |
curl -X POST https://app.credentialcamp.com/api/external/v1/employees \
-H "X-API-Key: cc_..." -H "X-API-Secret: ..." \
-H "Content-Type: application/json" \
-d '{"name":"Alex Rivera","email":"alex@example.com","locationId":"loc_uuid","externalId":"hris_123"}'
Update an employee. All fields are optional — only provided fields are changed. Triggers an employee.updated webhook. Also accepts PUT.
Delete an employee. Triggers an employee.deleted webhook. Returns {"success": true}.
Upsert a single employee by externalId. Creates if not found, updates if found. Useful for HRIS sync.
Request Body
Same fields as POST /employees, but externalId is used as the match key. If a match is found, the record is updated; otherwise a new employee is created.
Upsert multiple employees in one request. Each item uses externalId as the match key.
Request Body
{ "employees": [ { "name": "...", "email": "...", "externalId": "..." }, ... ] }
Response
{ "created": 3, "updated": 12, "errors": [] }
Credential Types
List all training courses. Returns {"courses": [...], "total": N}.
Retrieve a single course.
Create a course. Triggers a course.created webhook.
Request Body
| Field | Type | Required | Description |
|---|---|---|---|
| name | string | required | Credential type name |
| price | number | required | Cost (use 0 for free) |
| description | string | optional | Credential type description |
| provider | string | optional | Issuing provider or body |
| validityMonths | integer | optional | Months until renewal required |
| externalUrl | string | optional | External training URL |
Update a course. Triggers a course.updated webhook. Also accepts PUT.
Delete a course. Triggers a course.deleted webhook.
Credentials
An assignment links an employee to a course and tracks their completion status.
List assignments. Filter by employee or course.
Query Parameters
| Parameter | Description |
|---|---|
| employeeId | Filter by employee UUID |
| courseId | Filter by course UUID |
| status | ASSIGNED | IN_PROGRESS | COMPLETED | EXPIRED | REVIEW_PENDING |
Retrieve a single assignment.
Assign a course to an employee. Triggers an assignment.created webhook.
Request Body
| Field | Type | Required | Description |
|---|---|---|---|
| employeeId | uuid | required | Employee to assign |
| courseId | uuid | required | Course to assign |
| payer | string | required | EMPLOYER | EMPLOYEE |
| dueDate | ISO date | optional | Due date for completion |
| status | string | optional | Initial status (default: ASSIGNED) |
Update an assignment's status, progress, or dates. Triggers assignment.updated or assignment.completed (when status is set to COMPLETED). Also accepts PUT.
Common Update Fields
| Field | Type | Description |
|---|---|---|
| status | string | ASSIGNED | IN_PROGRESS | COMPLETED | EXPIRED |
| progress | integer | 0–100 |
| completedDate | ISO date | Completion date |
| dueDate | ISO date | Updated due date |
Delete an assignment. Triggers an assignment.deleted webhook.
Certificates
Certificates are completion proof documents attached to an assignment.
List certificates. Filter by assignment or approval status.
Query Parameters
| Parameter | Description |
|---|---|
| assignmentId | Filter by assignment UUID |
| approvalStatus | PENDING | APPROVED | REJECTED |
Retrieve a single certificate.
Upload a certificate. Accepts both JSON (with a pre-hosted file URL) and multipart/form-data (with a file upload). Triggers a certificate.created webhook.
Option A — JSON with a URL
curl -X POST https://app.credentialcamp.com/api/external/v1/certificates \
-H "X-API-Key: cc_..." -H "X-API-Secret: ..." \
-H "Content-Type: application/json" \
-d '{"assignmentId":"uuid","fileName":"cert.pdf","fileUrl":"https://storage.example.com/cert.pdf"}'
Option B — Multipart file upload
curl -X POST https://app.credentialcamp.com/api/external/v1/certificates \
-H "X-API-Key: cc_..." -H "X-API-Secret: ..." \
-F "assignmentId=uuid-here" \
-F "file=@/path/to/certificate.pdf"
Fields (JSON body or form fields)
| Field | Type | Required | Description |
|---|---|---|---|
| assignmentId | uuid | required | Assignment this certificate belongs to |
| file | file | required* | Certificate file (multipart only; max 10MB) |
| fileName | string | required* | Filename (JSON only, required if no file upload) |
| fileUrl | string | required* | URL to hosted file (JSON only) |
| approvalStatus | string | optional | PENDING (default) | APPROVED | REJECTED |
* Provide either file (multipart) OR fileName+fileUrl (JSON) — not both.
Update a certificate's approval status or verification result. Triggers certificate.updated and certificate.approved or certificate.rejected depending on the new status. Also accepts PUT.
Updatable Fields
| Field | Type | Description |
|---|---|---|
| approvalStatus | string | PENDING | APPROVED | REJECTED |
| verificationStatus | string | PENDING | VERIFIED | FAILED |
| verificationScore | integer | 0–100 AI verification confidence |
Delete a certificate. Triggers a certificate.deleted webhook.
Locations
List all locations. Returns {"locations": [...], "total": N}.
Retrieve a single location.
Create a location. Triggers a location.created webhook.
Request Body
| Field | Type | Required | Description |
|---|---|---|---|
| name | string | required | Location name |
| address | string | optional | Street address |
| city | string | optional | City |
| state | string | optional | State / province |
| externalId | string | optional | Your system's location ID |
Update a location. Triggers a location.updated webhook. Also accepts PUT.
Delete a location. Triggers a location.deleted webhook.
Job Titles
List all job titles. Returns {"jobTitles": [...], "total": N}.
Retrieve a single job title.
Create a job title. Triggers a job_title.created webhook.
Request Body
| Field | Type | Required | Description |
|---|---|---|---|
| name | string | required | Job title name (e.g. "Line Cook") |
| description | string | optional | Description |
Update a job title. Triggers a job_title.updated webhook. Also accepts PUT.
Delete a job title. Triggers a job_title.deleted webhook.
Credential Type Prerequisites
Prerequisites are requirements that must be met before an employee is considered compliant for a course — they can be a prior course, an uploaded document, or a co-requisite.
List all course prerequisites. Filter by course.
Query Parameters
| Parameter | Description |
|---|---|
| courseId | Filter by parent course UUID |
Retrieve a single prerequisite.
Create a prerequisite for a course. Triggers a prerequisite.created webhook.
Request Body
| Field | Type | Required | Description |
|---|---|---|---|
| courseId | uuid | required | Parent course that has this prerequisite |
| name | string | required | Prerequisite name |
| requirementType | string | required | prerequisite_course | prerequisite_document | co_requisite | other |
| prerequisiteCourseId | uuid | optional | The required prior course (for prerequisite_course type) |
| isRequired | boolean | optional | Whether blocking (default: true) |
| description | string | optional | Instructions for employees |
Update a prerequisite. Triggers a prerequisite.updated webhook. Also accepts PUT.
Delete a prerequisite. Triggers a prerequisite.deleted webhook.
Continuing Education Requirements
CE requirements define recurring training that must be completed to maintain a certification (e.g., "8 hours of food safety CE every 12 months").
List CE requirements. Filter by parent course.
Query Parameters
| Parameter | Description |
|---|---|
| courseId | Filter by parent course UUID |
Retrieve a single CE requirement.
Create a CE requirement. Triggers a ce_requirement.created webhook.
Request Body
| Field | Type | Required | Description |
|---|---|---|---|
| courseId | uuid | required | Parent course this CE belongs to |
| name | string | required | CE requirement name |
| requiredHours | number | required | Hours of CE required |
| validityMonths | integer | required | Frequency — how often this must be completed (months) |
Update a CE requirement. Triggers a ce_requirement.updated webhook. Also accepts PUT.
Delete a CE requirement and all associated completion records. Triggers a ce_requirement.deleted webhook.
CE Completions
CE completions record an employee's fulfilment of a CE requirement, optionally with an uploaded certificate for admin review.
List all CE completions for an employee, newest first. Returns {"ceCompletions": [...], "total": N}.
Submit a CE completion for an employee. Optionally attach a certificate file via multipart/form-data. Triggers a ce_completion.submitted webhook.
Fields (JSON body or form fields)
| Field | Type | Required | Description |
|---|---|---|---|
| requirementId | uuid | required | The CE requirement being fulfilled |
| completionDate | ISO date | optional | Date completed (default: today) |
| hoursCompleted | number | optional | Hours completed (default: requirement's requiredHours) |
| notes | string | optional | Free-text notes |
| file | file | optional | Certificate file (multipart only; max 10MB — triggers admin review) |
curl -X POST https://app.credentialcamp.com/api/external/v1/employees/EMP_UUID/ce-completions \
-H "X-API-Key: cc_..." -H "X-API-Secret: ..." \
-F "requirementId=REQ_UUID" \
-F "completionDate=2026-06-01" \
-F "hoursCompleted=8" \
-F "file=@certificate.pdf"
When a file is attached, the completion is created with reviewStatus: "pending" and the linked assignment moves to REVIEW_PENDING. Admins review via the Credential Camp dashboard, which triggers ce_completion.approved or ce_completion.rejected webhooks.
Employee Documents
List all documents on file for an employee, newest first. Returns {"documents": [...], "total": N}.
Upload a document for an employee. Send as multipart/form-data.
Form Fields
| Field | Type | Required | Description |
|---|---|---|---|
| file | file | required | Document file (max 10MB) |
| description | string | optional | Document description or label |
curl -X POST https://app.credentialcamp.com/api/external/v1/employees/EMP_UUID/documents \
-H "X-API-Key: cc_..." -H "X-API-Secret: ..." \
-F "description=Government ID" \
-F "file=@id-scan.pdf"
Schema Discovery
Discover available fields and their types without reading this documentation — useful for building dynamic integrations.
Returns field schemas for all resource types.
Returns the field schema for a specific module. Available modules: employees, courses, assignments, certificates, locations, job-titles.
Returns the writeable field list for employees specifically — useful for building dynamic sync forms.
Webhooks
Webhooks let Credential Camp notify your server in real time when records change. Configure subscriptions from Settings → Integrations → Webhooks in the Credential Camp dashboard, or programmatically via the admin API.
Every webhook delivery includes an X-Webhook-Signature header. Always verify it before processing the payload to prevent spoofed requests.
Webhook Payload Structure
Every webhook POST to your endpoint follows this envelope:
{
"event": "assignment.completed",
"tenantId": "tenant-uuid",
"timestamp": "2026-06-07T22:00:00.000Z",
"data": {
"assignment": { "id": "...", "status": "COMPLETED", ... }
}
}
Retry Policy
Failed deliveries (non-2xx response or timeout) are retried with exponential backoff: immediately → 1min → 5min → 30min → 2h → 24h. After 6 attempts the subscription is marked as having a delivery failure. Your endpoint should return 200 within 10 seconds — do any heavy processing asynchronously.
Verifying Signatures
Each delivery includes an X-Webhook-Signature header containing an HMAC-SHA256 hex digest of the raw request body, signed with your webhook's secret. Always verify this before trusting the payload.
import crypto from 'crypto';
export function verifyWebhookSignature(
rawBody: string,
signature: string,
secret: string
): boolean {
const expected = crypto
.createHmac('sha256', secret)
.update(rawBody)
.digest('hex');
// Constant-time comparison prevents timing attacks
return crypto.timingSafeEqual(
Buffer.from(expected, 'hex'),
Buffer.from(signature, 'hex')
);
}
// Express handler example
app.post('/webhook', express.raw({ type: 'application/json' }), (req, res) => {
const sig = req.headers['x-webhook-signature'] as string;
if (!verifyWebhookSignature(req.body.toString(), sig, process.env.WEBHOOK_SECRET!)) {
return res.status(401).send('Invalid signature');
}
const event = JSON.parse(req.body.toString());
// process event.event, event.data ...
res.sendStatus(200);
});
Python verification
import hmac, hashlib
def verify_signature(raw_body: bytes, signature: str, secret: str) -> bool:
expected = hmac.new(secret.encode(), raw_body, hashlib.sha256).hexdigest()
return hmac.compare_digest(expected, signature)
# Flask example
@app.route('/webhook', methods=['POST'])
def webhook():
sig = request.headers.get('X-Webhook-Signature', '')
if not verify_signature(request.get_data(), sig, os.environ['WEBHOOK_SECRET']):
return 'Invalid signature', 401
event = request.get_json(force=True)
# handle event['event'], event['data']
return '', 200
Use the raw request body for signature verification — parsing to JSON and re-serialising can change whitespace or key ordering and will cause false failures.
Webhook Event Catalog
Subscribe to individual events or use a wildcard. Events are grouped below by resource.
Employee Events
A new employee was added to the organization.
{
"event": "employee.created",
"data": {
"employee": {
"id": "uuid",
"name": "Alex Rivera",
"email": "alex@example.com",
"locationId": "uuid",
"jobTitleId": "uuid",
"externalId": "hris_123",
"employmentStatus": "ACTIVE",
"createdAt": "2026-06-07T12:00:00.000Z"
}
}
}
An employee's record was updated. The employee object reflects the full record after the update.
{ "event": "employee.updated", "data": { "employee": { "id": "...", ... } } }
An employee was removed from the organization.
{ "event": "employee.deleted", "data": { "employeeId": "uuid" } }
Credential Type Events
A new training course was created.
{ "event": "course.created", "data": { "course": { "id": "...", "name": "ServSafe Manager", "validityMonths": 60, ... } } }
A course was updated.
{ "event": "course.updated", "data": { "course": { ... } } }A course was deleted.
{ "event": "course.deleted", "data": { "courseId": "uuid" } }Assignment Events
A course was assigned to an employee.
{
"event": "assignment.created",
"data": {
"assignment": {
"id": "uuid",
"employeeId": "uuid",
"courseId": "uuid",
"status": "ASSIGNED",
"dueDate": "2026-12-31T00:00:00.000Z",
"payer": "EMPLOYER"
}
}
}
An assignment's status or dates changed (but not to COMPLETED — see below).
{ "event": "assignment.updated", "data": { "assignment": { "id": "...", "status": "IN_PROGRESS", ... } } }An assignment was marked COMPLETED. Fired in addition to assignment.updated.
{ "event": "assignment.completed", "data": { "assignment": { "id": "...", "status": "COMPLETED", "completedDate": "...", ... } } }An assignment was removed.
{ "event": "assignment.deleted", "data": { "assignmentId": "uuid" } }Certificate Events
A certificate was uploaded for an assignment.
{ "event": "certificate.created", "data": { "certificate": { "id": "...", "assignmentId": "...", "fileName": "cert.pdf", "approvalStatus": "PENDING", ... } } }A certificate's approval or verification status changed. Fired on every update including approvals and rejections.
{ "event": "certificate.updated", "data": { "certificate": { "id": "...", "approvalStatus": "APPROVED", ... } } }An admin approved a certificate. Also fires certificate.updated.
{ "event": "certificate.approved", "data": { "certificateId": "uuid", "assignmentId": "uuid", "employeeId": "uuid", "courseId": "uuid", "approvalStatus": "APPROVED" } }An admin rejected a certificate. Also fires certificate.updated.
{ "event": "certificate.rejected", "data": { "certificateId": "uuid", "assignmentId": "uuid", "employeeId": "uuid", "courseId": "uuid", "approvalStatus": "REJECTED", "denialReason": "Expired certificate" } }A certificate was deleted.
{ "event": "certificate.deleted", "data": { "certificateId": "uuid" } }Prerequisite Events
A new course prerequisite definition was created via the external API.
{ "event": "prerequisite.created", "data": { "prerequisite": { "id": "...", "courseId": "...", "requirementType": "prerequisite_document", ... } } }A prerequisite definition was updated.
{ "event": "prerequisite.updated", "data": { "prerequisite": { ... } } }A prerequisite definition was deleted.
{ "event": "prerequisite.deleted", "data": { "prerequisiteId": "uuid" } }An employee submitted a document or checked off a prerequisite requirement.
{ "event": "prerequisite.submitted", "data": { "employeeId": "uuid", "requirementId": "uuid", "documentUrl": "https://..." } }An admin approved or rejected an employee's prerequisite submission.
{
"event": "prerequisite.reviewed",
"data": {
"employeeId": "uuid",
"requirementId": "uuid",
"status": "approved" // "approved" | "rejected"
}
}
CE Requirement & Completion Events
A CE requirement was created for a course.
{ "event": "ce_requirement.created", "data": { "ceRequirement": { "id": "...", "parentCourseId": "...", "name": "Food Safety Refresher", "requiredHours": 8, "frequencyMonths": 12, ... } } }A CE requirement was updated.
{ "event": "ce_requirement.updated", "data": { "ceRequirement": { ... } } }A CE requirement and its completions were deleted.
{ "event": "ce_requirement.deleted", "data": { "ceRequirementId": "uuid" } }An employee submitted a CE completion record, optionally with a certificate for review.
{
"event": "ce_completion.submitted",
"data": {
"ceCompletionId": "uuid",
"employeeId": "uuid",
"requirementId": "uuid",
"documentId": "uuid" // null if no file uploaded
}
}
An admin approved a CE completion with certificate. The linked assignment moves to COMPLETED.
{ "event": "ce_completion.approved", "data": { "ceCompletionId": "uuid", "employeeId": "uuid", "requirementId": "uuid" } }An admin rejected a CE completion. The linked assignment reverts to IN_PROGRESS.
{ "event": "ce_completion.rejected", "data": { "ceCompletionId": "uuid", "employeeId": "uuid", "requirementId": "uuid", "reason": "Certificate illegible" } }Location & Job Title Events
These events fire whenever a location or job title is created, updated, or deleted. Each follows the same pattern:
// location.created | location.updated
{ "event": "location.created", "data": { "location": { "id": "...", "name": "Downtown", ... } } }
// location.deleted
{ "event": "location.deleted", "data": { "locationId": "uuid" } }
// job_title.created | job_title.updated
{ "event": "job_title.created", "data": { "jobTitle": { "id": "...", "name": "Line Cook", ... } } }
// job_title.deleted
{ "event": "job_title.deleted", "data": { "jobTitleId": "uuid" } }