How GET /orgs/{org}/labels orders its results — the sort parameter of that endpoint.
==This one the spec does enumerate==
Unlike QuotaSubject, the sort parameter carries an explicit enum in spec/swagger.v1.json: mostissues, leastissues, reversealphabetically. Those three are the three cases below, verbatim, so this is a closed set the spec states rather than one this library inferred.
'''There is no case for the default.''' The parameter is optional, and omitting it is not the same request as sending any value — Forgejo then orders labels its own way, which the spec does not describe. That is why OrganizationLabelApi.list takes an Option and sends nothing when it is None, rather than this enum carrying an Alphabetically case that would have to guess the wire spelling of a value the spec does not list.
==Why it lives in this package==
GET /repos/{owner}/{repo}/labels declares the identical enum, so this ordering is not organisation-specific. docs/LEDGER.md makes the wave that first needs a shared model its owner, and no repository-label listing in this library sends sort today — com.worxbend.codeberg4s.issues.IssueApi does not offer it — so there is nothing to reuse and nothing yet to conflict with. If the issues group later grows a sorted label listing, this type moves there and this package imports it; what must not happen is a second copy.
Attributes
- Companion
- object
- Graph
-
- Supertypes
-
trait Enumtrait Serializabletrait Producttrait Equalsclass Objecttrait Matchableclass Any