Skip to main content

Response and Error Model

Summary

Confirmed result mapping, DTO responses, arrays, messages, and non-uniform behavior.

Audience

API consumers, engineers, architects, QA, support, security reviewers, implementation partners, and product owners.

Overview

Command and compatibility services return a custom Result<T>. EndpointResults maps its category to HTTP. Direct query and diagnostic endpoints return arrays, DTOs, anonymous projections, or message objects.

Endpoint family

  • Success maps to OK unless create supplies Created.
  • Validation maps to Bad Request with a message object.
  • Missing resource maps to Not Found with a message object.
  • Conflict maps to Conflict with a message object.
  • Forbidden mapping exists and returns Forbidden with a message object.
  • No file response, ApiResponse<T>, or RFC ProblemDetails use was found.
  • Framework model-binding failures are outside the custom Result mapping, so no single uniform envelope exists.

Input DTO catalog

  • Cycle: CreateCycleInput
  • Appraisal creation: CreateAppraisalInput
  • Goal creation: AddGoalInput
  • Employee stage: GoalSelfRatingInput, SubmitSelfReviewInput
  • Manager stage: GoalManagerRatingInput, ManagerReviewInput
  • HR and decision actions: HrReviewInput, ApproveAppraisalInput, ReopenAppraisalInput
  • Workflow completion: WorkflowCallbackDto
  • Compatibility: MonolithPerformanceGoal

Output DTO catalog

  • Core: ReviewCycleDto, AppraisalDto, AppraisalGoalDto, AppraisalReviewDto
  • Dashboard: CycleDashboardDto
  • Distribution: RatingBucketDto, RatingDistributionDto
  • Manager pending: ManagerPendingDto, ManagerPendingReportDto
  • HR pending: HrPendingEmployeeDto, HrCalibrationPendingDto
  • Goal summary: GoalSummaryDto

The catalogs name source contracts but intentionally omit sensitive field examples and values.

Classification

Implemented Result mapping with Transitional response consistency.

Authentication and authorization

Bearer authentication and tenant context are registered. No Performance endpoint in this family declares an authorization requirement unless explicitly stated above.

Requires confirmation

Uniform envelopes, error codes, localization, validation detail, and ProblemDetails adoption require confirmation.

Diagram

See Also

Keywords

  • Performance API
  • Response and Errors
  • Draft API documentation

Source References

  • microservices/src/performance-service/Api/EndpointResults.cs
  • microservices/src/performance-service/Application/Common/Cqrs.cs
  • microservices/src/performance-service/Application/Dtos.cs
  • microservices/src/performance-service/Api/PerformanceEndpoints.cs

Revision Information

  • Status: Draft
  • Last reviewed: 2026-07-16
  • Review cycle: Quarterly