Standard HTTP Responses

SeamlessHR employs standard HTTP response codes to signify the success or failure of an API request.

Success Status Codes (2xx)

CodeNameDescription
200OKThe request was successful.
201CreatedThe resource was successfully created. Confirms a success when creating a new employee, time off request, etc.
204UpdatedThe request was successful with no content

Client Error Status Codes (4xx)

CodeNameDescription
400Bad RequestThe request was invalid or could not be understood by the server. Resubmitting the request will likely result in the same error.
401UnauthorizedThis can be a result of a missing API key, incorrect key name, or invalid key value etc
403ForbiddenThe application is attempting to perform an action it does not have privileges to access. Verify your API key belongs to an enabled user with the required permissions.
404Not FoundThe resource was not found with the given identifier. Either the URL given is not a valid API or the ID of the object specified in the request is invalid.
406Not AcceptableThe request contains references to non-existent fields.
409ConflictThe request attempts to create a duplicate. For employees, duplicate emails are not allowed. For lists, duplicate values are not allowed.
429Limit ExceededThe account has reached its employee limit. No additional employees could be added.

Server Error Status Codes (5xx)

CodeNameDescription
500Internal ErrorThe server encountered an error while processing your request and failed. Retrying may be appropriate.
502Gateway ErrorThe load balancer or web server had trouble connecting to the server. Please try the request again.
503UnavailableThis endpoint is currently unavailable. Retrying may be appropriate. Commonly, this is due to rate limiting, and a "Retry-After" header may be available.