Keep API interfaces simple and focused by avoiding unnecessary input wrapping, extracting context parameters appropriately, and limiting exposure of internal implementation details.

Key principles:

Example:

// ❌ Avoid unnecessary input wrapping
async createPublicDomain(
  @Args('input') { domain }: PublicDomainInput,
) { ... }

// ✅ Put properties directly at root level
async createPublicDomain(
  @Args('domain') domain: string,
) { ... }

// ❌ Don't mix context with business data
async create(
  viewFieldData: Partial<ViewFieldEntity>, // contains workspaceId
) { ... }

// ✅ Extract context parameters
async create(
  viewFieldData: CreateViewFieldInput,
  workspaceId: string,
) { ... }

This approach reduces API complexity, improves type safety, and maintains clear boundaries between public interfaces and internal implementation details.