mirror of
https://github.com/bitechdev/ResolveSpec.git
synced 2026-10-02 03:22:09 +00:00
Tests / Integration Tests (push) Failing after 1m39s
Build , Vet Test, and Lint / Build (push) Successful in 2m3s
Tests / Unit Tests (push) Successful in 2m8s
Build , Vet Test, and Lint / Lint Code (push) Successful in 2m51s
Build , Vet Test, and Lint / Run Vet Tests (1.24.x) (push) Successful in 2m57s
Build , Vet Test, and Lint / Run Vet Tests (1.23.x) (push) Successful in 2m59s
Tests / Race Detector (push) Successful in 5m9s
Move .github/workflows to .gitea/workflows with Gitea-compatible action versions, fix make_tag outputs/major bump, and add release_clients.yml to build and publish all clients to the Gitea package registries. Rename the Go client module to git.warky.dev/wdevs and add LICENSE/CHANGELOG for Dart.
resolvespec (Dart)
Dart / Flutter client for ResolveSpec (JSON body) and FunctionSpec. Depends on package:http. Dart >= 3.3.
Clients
| Type | Constructor | Methods |
|---|---|---|
ResolveSpecClient |
(baseUrl, [ClientOptions]) |
getMetadata read create update delete close |
FuncSpecClient |
(baseUrl, [ClientOptions]) |
query queryList close |
ClientOptions(token:, headers:, timeout:, httpClient:). Precedence: Content-Type < custom headers < bearer token.
ResolveSpec
id:int/String→ URL,List<String>→ body. Named args:id:,options:.Options,FilterOption(column, operator, [value, logic]),SortOption(column, [direction]).- Result:
Response{success, data (decoded JSON), metadata}.
FunctionSpec
- Routes are server-defined: pass the
path. params:map → query string (list → repeated keys, null skipped).FuncSpecOptions→X-*headers:filters,searchFilters,customSqlWhere,customSqlOr,sort,limit,offset,distinct,skipCount,skipCache,responseFormat.queryListfillsmetadatafromContent-Range; 206 is success.- Helpers:
buildHeaders,buildQuery,encodeHeaderValue,decodeHeaderValue.
Server quirks
sortis raw SQL in ORDER BY (client sendscol ASC|DESC).- One search operator per column.
- Values starting
ZIP_/__are base64-decoded by the server. - Non-ASCII, control chars and edge spaces are auto-encoded (
ZIP_).
Errors
ResolveSpecException{statusCode, message, error: ApiError{code, detail, sql}}.
Test
dart test