@simpleapps-com/augur-api 2026.9.5 → 2026.9.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/SKILL.md +12 -9
- package/dist/client-BdaR6MZK.d.mts +9057 -0
- package/dist/client-BdaR6MZK.d.ts +9057 -0
- package/dist/index.d.mts +18 -4
- package/dist/index.d.ts +18 -4
- package/dist/index.js +11073 -9315
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +11073 -9315
- package/dist/index.mjs.map +1 -1
- package/dist/testing.d.mts +1 -1
- package/dist/testing.d.ts +1 -1
- package/package.json +5 -4
- package/dist/client-CcgcognS.d.mts +0 -7215
- package/dist/client-CcgcognS.d.ts +0 -7215
package/SKILL.md
CHANGED
|
@@ -194,20 +194,23 @@ response.message // Status message
|
|
|
194
194
|
response.status // HTTP status code
|
|
195
195
|
```
|
|
196
196
|
|
|
197
|
-
##
|
|
197
|
+
## Types and Validation
|
|
198
198
|
|
|
199
|
-
|
|
199
|
+
Request params and responses are validated with Valibot schemas. Types are exported per service as
|
|
200
|
+
a namespace (`{Service}Types`): params are `{Chain}{Action}Params`, request bodies
|
|
201
|
+
`{Chain}{Action}Body`, response data `{Chain}{Action}Data`.
|
|
200
202
|
|
|
201
203
|
```typescript
|
|
202
|
-
import {
|
|
204
|
+
import type { ItemsTypes } from '@simpleapps-com/augur-api';
|
|
203
205
|
|
|
204
206
|
// Type-safe params
|
|
205
|
-
const params:
|
|
206
|
-
const response = await api.items.invMast.list(params);
|
|
207
|
+
const params: ItemsTypes.InvMastFaqListParams = { limit: 10, offset: 0 };
|
|
208
|
+
const response = await api.items.invMast.faq.list(invMastUid, params);
|
|
207
209
|
|
|
208
|
-
// Type-safe response
|
|
209
|
-
|
|
210
|
-
|
|
210
|
+
// Type-safe response data
|
|
211
|
+
const faqs: ItemsTypes.InvMastFaqListData = response.data;
|
|
212
|
+
for (const faq of faqs) {
|
|
213
|
+
console.log(faq.question); // IDE autocomplete works
|
|
211
214
|
}
|
|
212
215
|
```
|
|
213
216
|
|
|
@@ -219,4 +222,4 @@ for (const item of response.data) {
|
|
|
219
222
|
| Service: brand-folder | api.brandFolder | api.brand_folder |
|
|
220
223
|
| Resource: inv-mast | .invMast | .inv_mast |
|
|
221
224
|
| Method: invMastUid | invMastUid | inv_mast_uid |
|
|
222
|
-
| Validation |
|
|
225
|
+
| Validation | Valibot | Pydantic v2 |
|