diff --git a/packages/taler-util/src/transactions-types.ts b/packages/taler-util/src/transactions-types.ts index 083124afa..88830d82b 100644 --- a/packages/taler-util/src/transactions-types.ts +++ b/packages/taler-util/src/transactions-types.ts @@ -43,6 +43,8 @@ import { codecForList, codecForAny, codecForBoolean, + codecForEither, + codecForConstString, } from "./codec.js"; import { RefreshReason, @@ -697,6 +699,15 @@ export const codecForTransactionsRequest = (): Codec => buildCodecForObject() .property("currency", codecOptional(codecForString())) .property("search", codecOptional(codecForString())) + .property( + "sort", + codecOptional( + codecForEither( + codecForConstString("ascending"), + codecForConstString("descending"), + ), + ), + ) .property("includeRefreshes", codecOptional(codecForBoolean())) .build("TransactionsRequest");