Skip to main content
POST
Register Company

Endpoint

Base URL: http://localhost:3000/api/v1
This endpoint is public and does not require authentication.

Request Body

email
string
required
Company’s email address. Must be unique and valid format.
password
string
required
Company account password. Minimum 6 characters.
name
string
required
Company name.
industry
string
required
Industry sector (e.g., “Technology”, “Healthcare”, “Finance”).
size
string
required
Company size. Must be one of: - SIZE_1_50 - 1-50 employees - SIZE_51_200 - 51-200 employees - SIZE_201_1000 - 201-1,000 employees - SIZE_1000_PLUS - 1,000+ employees
type
string
required
Company type. Must be one of: - STARTUP - SCALE_UP - ENTERPRISE - NON_PROFIT - GOVERNMENT

Request Shape

Response

Success Response (201 Created)

success
boolean
Indicates if the registration was successful.
data
object
Contains the registered company’s email.
message
string
Success message: “Company registration successful. Please check your email to verify your account.”
meta
object
Request metadata from global response interceptor.

What Happens After Registration

1

Company Account Created

Company account is created in database with: - isVerified: false - isActive: true - All optional fields set to null (description, logoUrl, etc.)
2

Password Hashed

Password is securely hashed using bcrypt before storage
3

OTP Generated

A 6-digit OTP code is generated and stored in Redis (valid for 10 minutes)
4

Email Queued

Verification email with OTP is queued via BullMQ for async delivery
5

Next Step

Company must verify email using the Verify Email endpoint

Error Responses

400 Bad Request - Validation Error

Returned when request validation fails.
Common validation errors:
  • email must be an email - Invalid email format
  • password must be longer than or equal to 6 characters - Password too short
  • name should not be empty - Missing company name
  • industry should not be empty - Missing industry
  • size must be one of the following values: ... - Invalid company size
  • type must be one of the following values: ... - Invalid company type

409 Conflict - Email Already Exists

Returned when the email is already registered.
Solution: Use a different email or login with existing account.

500 Internal Server Error

Returned when an unexpected error occurs.
Error responses follow the global API envelope: success: false and an error object containing message, statusCode, timestamp, path, method, and details.

Validation Rules

Enums Reference

Company Size

Company Type

TypeScript Types

Notes

Email Verification Required: Companies cannot login until they verify their email using the OTP sent to their inbox.
OTP Expiration: The verification OTP expires after 10 minutes. If expired, companies will need to request a new OTP.
Use Company Email: It’s recommended to use an official company email address (e.g., hr@company.com) rather than personal email addresses.