Overview
The WEDA API implements a standardized error response format based on RFC 9457 (Problem Details for HTTP APIs). This industry-standard specification provides a machine-readable, language-agnostic format for describing HTTP API errors, ensuring consistency and predictability across all API endpoints.
Why RFC 9457?
We adopted RFC 9457 to provide:
- Cross-platform compatibility - The standard JSON format works seamlessly across web, mobile, desktop, and embedded applications
- Language independence - Client applications can be built in any programming language (JavaScript, Java, C#, Python, Swift, Kotlin, etc.)
- Industry best practices - Aligns with modern API design standards used by major technology companies
- Future-proof architecture - As an IETF standard, RFC 9457 ensures long-term compatibility and tooling support
Benefits for API Consumers
This structured approach enables client applications to:
- Implement consistent error handling logic across the entire application, regardless of the platform or technology stack
- Display localized error messages to end users based on the
Accept-Languageheader, improving accessibility - Programmatically distinguish between different error types using the
typefield for intelligent error routing - Debug issues efficiently using
traceIdfor correlation with server logs and support diagnostics - Handle validation errors gracefully by mapping
validationItemsto specific input fields in the user interface - Reduce integration time by following a well-documented, predictable error format
Error Response Schema
All API errors return a structured JSON response conforming to RFC 9457. The response includes the following fields:
Standard Error Fields
| Field | Type | Description |
|---|---|---|
type | string | A URI reference that identifies the problem type. May be a full URI (e.g., https://api.example.com/problems/validation-error) or a simple error code (e.g., License.Expired). |
title | string | A short, human-readable summary of the problem type. This value is localized based on the request's Accept-Language header. |
status | integer | The HTTP status code (400, 401, 403, 404, 500, etc.). |
detail | string | A human-readable explanation specific to this occurrence of the problem. Runtime values are substituted into placeholders. |
detailFormat | string | A template string showing the format of the detail field with placeholder names (e.g., "The field {FieldName} is required."). |
instance | string | A URI reference identifying the specific occurrence of the problem, typically the API endpoint path. |
timestamp | string | ISO 8601 timestamp indicating when the error occurred (e.g., 2026-04-14T02:26:01.1247685+00:00). |
traceId | string | A unique identifier for this request, useful for debugging and correlating logs. |
extension | object | Additional custom properties specific to the error context. |
Validation Error Fields
For validation errors (HTTP 400), the response includes an additional validationItems array:
| Field | Type | Description |
|---|---|---|
validationItems | array | An array of validation error details. Only present when one or more input fields fail validation. |
Each item in the validationItems array contains:
| Field | Type | Description |
|---|---|---|
fieldName | string | The name of the field that failed validation. |
title | string | The error code for this validation failure (e.g., CommonModelError.RequiredError). |
detail | string | A human-readable explanation of the validation error with values substituted. |
detailFormat | string | The template string showing the format of the detail field with placeholder names. |
extension | object | Additional context-specific data about the validation failure (e.g., field constraints, values). |
Example: Validation Error Response
{
"type": "https://api.example.com/problems/validation-error",
"title": "ValidationError",
"status": 400,
"detail": "One or more properties is invalid, see the details",
"detailFormat": null,
"instance": "/api/v1/notifications/audit-logs",
"timestamp": "2026-04-14T02:26:01.1247685+00:00",
"traceId": "e00edf3ac5896f918770e70ef17b65b7",
"extension": null,
"validationItems": [
{
"fieldName": "EndTime",
"title": "CommonModelError.RequiredError",
"detail": "The field EndTime is required.",
"detailFormat": "The field {FieldName} is required.",
"extension": {
"fieldName": "EndTime",
"required": true
}
},
{
"fieldName": "StartTime",
"title": "CommonModelError.RequiredError",
"detail": "The field StartTime is required.",
"detailFormat": "The field {FieldName} is required.",
"extension": {
"fieldName": "StartTime",
"required": true
}
}
]
}
Internationalization Support
The WEDA API is designed with internationalization (i18n) support in mind.
- Always check the
statuscode to determine the error category (client error 4xx vs server error 5xx) - Use the
typefield for programmatic error handling and routing - Display the localized
titleto end users for better UX - For validation errors, iterate through
validationItemsto show field-specific error messages - Include the
traceIdwhen reporting issues to support teams for faster troubleshooting
How to Read Error Codes
Each error code follows the format Category.ErrorName.
| Component | Description |
|---|---|
Category | The module or domain the error belongs to (e.g. License, User) |
ErrorName | A descriptive identifier for the specific error condition |
Placeholder Values
Some error messages contain placeholders enclosed in curly braces {}.
These are runtime values substituted by the server when the error occurs.
Example:
| Error Code | Message |
|---|---|
Device.NotFound | Device with ID {deviceId} not found. |
When this error is returned, {deviceId} is replaced with the actual device ID: Device with ID abc-123 not found.
Common
| Error Code | Message |
|---|---|
Common.AlreadyExists | {resource} with identifier '{identifier}' already exists. |
Common.NotFound | Resource '{resource}' not found |
Common.NotFoundWithKey | Resource '{resource}'({identifier}) not found |
CommonDevice.NotFound | Device with ID {deviceId} not found. |
CommonDevice.OrganizationNotFoundOrNoPermission | Organization not found or you do not have permission to access the specified organization. |
CommonModelError.AllowedValuesError | The field {FieldName} must be one of the allowed values: {AllowedValues}. |
CommonModelError.Base64StringError | The field {FieldName} must be a valid Base64 string. |
CommonModelError.CompareError | The field {FieldName} must match the field {OtherProperty}. |
CommonModelError.CreditCardError | The field {FieldName} is not a valid credit card number. |
CommonModelError.DeniedValuesError | The field {FieldName} must not be one of the denied values: {DeniedValues}. |
CommonModelError.EmailError | The field {FieldName} is not a valid e-mail address. |
CommonModelError.EnumDataTypeError | The field {FieldName} must be a valid value of type {EnumType}. |
CommonModelError.FileExtensionsError | The field {FieldName} must have a file extension of {Extensions}. |
CommonModelError.JwtAudienceNotMatch | The request token audience does not match the required audience. |
CommonModelError.JwtEmptyRole | The request token role is empty. |
CommonModelError.JwtParsingError | The request token cannot be parsing. |
CommonModelError.JwtRoleNotMatch | The request token expect get {expect} role but current role is not match. |
CommonModelError.JwtScopeNotMatch | The request token expect get {expect} scope but current scope is not match. |
CommonModelError.JwtTokenExpired | The JWT token has expired. |
CommonModelError.JwtVerificationFailed | JWT verification failed. Please confirm your login status or whether the token is valid. |
CommonModelError.LengthError | The field {FieldName} must be a string or collection with a minimum length of {MinimumLength} and a maximum length of {MaximumLength}. |
CommonModelError.MaxLengthError | The field {FieldName} must be a string with a maximum length of {MaxLength}. |
CommonModelError.MinLengthError | The field {FieldName} must be a string with a minimum length of {MinLength}. |
CommonModelError.PhoneError | The field {FieldName} is not a valid phone number. |
CommonModelError.RangeError | The field {FieldName} must be between {Minimum} and {Maximum}. |
CommonModelError.RegularExpressionError | The field {FieldName} must match the regular expression '{Pattern}'. |
CommonModelError.RequiredError | The field {FieldName} is required. |
CommonModelError.ResourceNotFound | The resource you requested could not be found. |
CommonModelError.StringLengthError | The field {FieldName} must be a string with a minimum length of {MinimumLength} and a maximum length of {MaximumLength}. |
CommonModelError.UnExpectedError | System are facing some unexpected error. |
CommonModelError.UnknownValidationError | The field {FieldName} validation failed. |
CommonModelError.UrlError | The field {FieldName} is not a valid URL. |
CommonOrganization.IdPermissionDenied | You do not have permission to access Org {orgId}. |
CommonOrganization.InvalidOrgId | Invalid organization ID format. |
Common.AccessTokenMissing | Access token is missing. |
Common.ApiFetchFail | Unable to process your request: {ReasonPhrase}. Please try again later |
Common.FormatError | Invalid data format |
Common.InvalidGuid | invalid Guid |
Common.InvalidGuidEmptyString | invalid Guid empty string |
Common.InvalidGuidNullValue | Invalid Guid null value |
Common.InvalidNaming | Invalid property naming. {details} |
Common.InvalidTimeInterval | Invalid start or end time. {details} |
Common.JsonSchemaFormatInvalidWithDetail | The provided json schema format is invalid: {details}. |
Common.MailFormat | Invalid email format |
Common.MailSendError | Failed to send email. Please try again later |
Common.PropertyFormatError | Invalid format for property '{propertyName}'. Expected format: {format} |
Common.PropertyRequire | The property '{propertyName}' is required. |
Common.RequestNotMatchUrlPath | Request does not match the URL path |
Common.Require | Require field |
Common.SettingFail | Required configuration '{propertyName}' is missing. Please contact support |
Common.UnknownError | An unexpected error occurred. Please try again or contact support |
AnalyticExpression
| Error Code | Message |
|---|---|
AnalyticExpression.AlreadyExists | Analytic expression with name '{name}' already exists. |
AnalyticExpression.BuiltInTypeIsReadOnly | Built-in type is read-only and cannot be modified. |
AnalyticExpression.JsonSchemaFormatInvalid | The provided json schema format is invalid: {details}. |
AnalyticExpression.NotFound | Analytic expression not found with ID {analyticExpressionId}. |
AnalyticExpression.SystemResourceIsReadOnly | System resource is read-only and cannot be modified. |
AnalyticModule
| Error Code | Message |
|---|---|
AnalyticModule.AlreadyExists | Analytic module with name '{name}' already exists. |
AnalyticModule.ConfigurationsFormatInvalid | The provided configurations don't match the JSON schema format: {details}. |
AnalyticModule.NotFound | Analytic module not found with ID {analyticModuleId}. |
AnalyticModule.SystemResourceIsReadOnly | System resource is read-only and cannot be modified. |
Application
| Error Code | Message |
|---|---|
Application.AppNotExistOrNotReady | The application: {AppName} is not ready for installation, please contact the support. |
Application.NotFound | Application not found. |
Application.UniqueNameInvalid | Application unique name is invalid. |
Application.UrlInvalid | Application URL is invalid. |
Batch
| Error Code | Message |
|---|---|
Batch.ActionLogsNotFound | No batch action logs found for batch ID {batchId}. |
Batch.ActionNotFound | No actions could be executed for batch {actionId}. |
Batch.BatchIdOrgIdNotFound | Batch with ID {batchId} and Organization ID {orgId} does not exist. |
Batch.BatchNotFoundUnderOrg | Batch with ID {batchId} under Org {orgId} does not exist. |
Batch.CronExpressionFormatInvalid | The provided 'cronExpression' value does not follow a valid CRON format. |
Batch.DeleteFailed | Failed to delete batch {errorMessage} |
Batch.FetchFailed | unexpected error while fetching batch {errorMessage} |
Batch.GetFailed | Unexpected error while getting batchs: {errorMessage} |
Batch.InvalidDeleteEnabledBatch | Cannot delete an enabled batch. Please disable it (IsEnabled = false) before deletion. |
Batch.InvalidSortingExpression | Sorting {sorting} caused an error: {errorMessage} |
Batch.InvalidTriggeredByValue | Invalid triggeredBy value: {triggeredBy}. Allowed values: Manual, Scheduler. |
Batch.JobSchedulerNotFound | JobScheduler related to BatchId {batchId} does not exist. |
Batch.NameExists | A Batch with the name {batchName} already exists under Org {orgId}. Please use a different name. |
Batch.NameLengthExceeded | The provided 'name' exceeds the maximum allowed length of 100 characters. |
Batch.NotFound | Batch with ID {batchId} does not exist. |
Batch.UnitOfWorkNotAvailable | The current UnitOfWork is not available. Cannot save batch. |