Skip to main content
POST
Create Employee

Create Employee

Create a new employee record in your organization. After creating an employee, you can add commuting periods to track their transportation emissions.
Name or Email Required: At least one of name or email must be provided when creating an employee.

Request

Headers

string
required
Your API key for authenticationExample: sk_live_1234567890abcdef
string
required
Your organization UUIDExample: a8315ef3-dd50-43f8-b7ce-d839e68d51fa

Body Parameters

string
Employee’s full name (1-255 characters)Required if email is not providedExample: "John Smith"
string
Employee’s email addressRequired if name is not providedExample: "john.smith@company.com"
string
required
Employment situationAvailable values: active, inactive, terminatedExample: "active"
string
required
Data collection statusAvailable values: uploaded, loadingExample: "uploaded"

Response

string
Unique identifier (UUID) for the employee
string | null
Employee’s full name
string | null
Employee’s email address
string
Organization UUID
string | null
Employment status: active, inactive, or terminated
string
Data status: uploaded or loading
array | null
List of commuting periods (empty for new employees)
datetime
Timestamp when the employee was created
datetime | null
Timestamp when the employee was last updated

Example

Successful Response

Common Errors

401 Unauthorized

Cause: Missing or invalid API key
Solution: Verify your API key is valid and active. Get a new one from Settings -> API.

404 Not Found

Cause: Organization not found
Solution: Verify that the x-organization-id header contains a valid organization UUID.

422 Validation Error

Cause: Missing required parameters or invalid values
Solution: Ensure at least name or email is provided, and situation and status have valid enum values.

Use Cases

Create Employee with Full Details

Add an employee with all available information:

Create Employee for Survey

Create an employee with just email for survey distribution:

Create Employee and Add Commuting Period

Complete workflow to track an employee’s commuting:

Bulk Create Employees

Add multiple employees from a list:

Next Steps

After creating an employee, you’ll typically want to:
  1. Add Commuting Period: Create a commuting period to track their transportation
  2. Send Survey: Use the survey feature to collect commuting data from the employee
  3. View Emissions: Retrieve the employee to see calculated CO2e

Create Commuting Period

Add commuting data for the employee

List Employees

View all employees and their emissions

Employee Commuting Guide

Learn about tracking commuting emissions

Update Employee

Modify employee details