softwaremill / softwaremill/tapir

[Feature] Semi-auto enum schema derivation configuration

Open
#3,737 0 comments 2 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Scala
Stars
1.5k
Forks
468
Avg merge
5h 37m
Merged PRs (30d)
34

Description

Scala version: Scala 3

Describe the feature
In some types of derivation we can manually choose how to transform member names by Configuration (f.e. snake_case, kebab-case etc).
For deriving enum's schema by using Schema.derivedEnumeration we have only two options: defaultStringBased or writing our own transformation to raw string value. It would be useful to have different options like above out of the box

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reading Schema.derivedEnumeration and the existing Configuration-based derivation options to understand how member-name transformations are represented. Define the supported enum transformations and verify the derived schema output with tests; the feature is done when enum schema derivation accepts configuration-based transformations beyond defaultStringBased.

Written by the indexing model from the issue text.

Assessment

Tech stack
scala
Domain
api
Issue type
Feature
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.