Commit Graph

8 Commits

Author SHA1 Message Date
Jean Claveau
cc29b626ab Add message property to sdk error (#25474)
* feat(sdk): add a message entry on api error to be catchable normally

* feat(sdk): FetchInterface MUST return unknown to support alternative fetch implementations

* feat(sdk): empty default error message to match js Error spec

* Improve DirectusError type

* add tests

* account for non object reason in message

* add non object reason test

* simplify error message check

* add changeset

* Error result is not necessarily a directus error

* Remove unnecessary errors existence check

---------

Co-authored-by: daedalus <44623501+ComfortablyCoding@users.noreply.github.com>
2025-07-21 09:13:19 -04:00
Brainslug
cca6ca05f4 Improved output types for relational fields in the SDK (#25428)
* Add type test for the issue

* improve relational output typing

* add more relations to tests

* prettier

* Create slow-toes-study.md
2025-07-11 11:27:59 -04:00
WoLfulus
a7178a35d2 Add test to to ensure all SDK schemas/types are exported (#24531)
Co-authored-by: Pascal Jufer <pascal-jufer@bluewin.ch>
2025-03-02 14:14:21 +01:00
Pascal Jufer
e8d96d4706 Update TypeScript to 5.6.2 (#23741) 2024-09-26 10:00:39 +02:00
Brainslug
3aef9bbc48 SDK Core Field type checking fails (#21089)
* updated relational fields to use the complete schema

* prettier

* Create few-horses-join.md

* Revert "updated relational fields to use the complete schema"

This reverts commit ac839c0ec8.

* Added type test for the core collection fallback

* fixed core collection fallback

* QoL set default schema for core collections

* prettier

* removed docs reference

---------

Co-authored-by: Rijk van Zanten <rijkvanzanten@me.com>
2024-07-16 17:01:25 -04:00
Brainslug
6bacead457 [SDK] Fix inferred partial field types, when using _and/_or filters in queries (#22288)
Co-authored-by: Pascal Jufer <pascal-jufer@bluewin.ch>
2024-05-03 15:28:00 +00:00
Brainslug
d37a16a31e SDK TypeScript 5.4 compatibility (#22211)
* replaced "a few" type constraints

* updated lockfile

* prettier

* Fixed fields infer issue

* Added schema fallback tests

* Create soft-pigs-applaud.md
2024-04-18 09:16:31 -04:00
Brainslug
1398692c1c SDK relational field type validation fails (#21803)
Co-authored-by: Pascal Jufer <pascal-jufer@bluewin.ch>
2024-03-15 15:23:59 +00:00