apimo.js 1.0.1 → 1.0.3
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/README.md +314 -48
- package/dist/{src/core → core}/api.d.ts +1 -1
- package/dist/{src/core → core}/api.js +1 -1
- package/dist/index.d.ts +11 -0
- package/dist/index.js +10 -0
- package/dist/{src/schemas → schemas}/agency.d.ts +8 -8
- package/dist/{src/schemas → schemas}/property.d.ts +151 -151
- package/package.json +16 -2
- package/.github/workflows/ci.yml +0 -37
- package/.github/workflows/publish.yml +0 -69
- package/.idea/apimo.js.iml +0 -13
- package/.idea/copilotDiffState.xml +0 -43
- package/.idea/inspectionProfiles/Project_Default.xml +0 -6
- package/.idea/jsLinters/eslint.xml +0 -6
- package/.idea/modules.xml +0 -8
- package/.idea/prettier.xml +0 -6
- package/.idea/vcs.xml +0 -6
- package/dist/src/core/api.test.d.ts +0 -1
- package/dist/src/core/api.test.js +0 -246
- package/dist/src/services/storage/dummy.cache.test.d.ts +0 -1
- package/dist/src/services/storage/dummy.cache.test.js +0 -96
- package/dist/src/services/storage/filesystem.cache.test.d.ts +0 -1
- package/dist/src/services/storage/filesystem.cache.test.js +0 -197
- package/dist/src/services/storage/memory.cache.test.d.ts +0 -1
- package/dist/src/services/storage/memory.cache.test.js +0 -80
- package/dist/src/utils/url.test.d.ts +0 -1
- package/dist/src/utils/url.test.js +0 -18
- package/dist/vitest.config.d.ts +0 -2
- package/dist/vitest.config.js +0 -6
- package/eslint.config.mjs +0 -3
- package/src/consts/catalogs.ts +0 -55
- package/src/consts/languages.ts +0 -22
- package/src/core/api.test.ts +0 -308
- package/src/core/api.ts +0 -230
- package/src/core/converters.ts +0 -7
- package/src/schemas/agency.ts +0 -66
- package/src/schemas/common.ts +0 -67
- package/src/schemas/internal.ts +0 -13
- package/src/schemas/property.ts +0 -257
- package/src/services/storage/dummy.cache.test.ts +0 -110
- package/src/services/storage/dummy.cache.ts +0 -21
- package/src/services/storage/filesystem.cache.test.ts +0 -243
- package/src/services/storage/filesystem.cache.ts +0 -94
- package/src/services/storage/memory.cache.test.ts +0 -94
- package/src/services/storage/memory.cache.ts +0 -69
- package/src/services/storage/types.ts +0 -20
- package/src/types/index.ts +0 -5
- package/src/utils/url.test.ts +0 -21
- package/src/utils/url.ts +0 -27
- package/tsconfig.json +0 -13
- package/vitest.config.ts +0 -7
- /package/dist/{src/consts → consts}/catalogs.d.ts +0 -0
- /package/dist/{src/consts → consts}/catalogs.js +0 -0
- /package/dist/{src/consts → consts}/languages.d.ts +0 -0
- /package/dist/{src/consts → consts}/languages.js +0 -0
- /package/dist/{src/core → core}/converters.d.ts +0 -0
- /package/dist/{src/core → core}/converters.js +0 -0
- /package/dist/{src/schemas → schemas}/agency.js +0 -0
- /package/dist/{src/schemas → schemas}/common.d.ts +0 -0
- /package/dist/{src/schemas → schemas}/common.js +0 -0
- /package/dist/{src/schemas → schemas}/internal.d.ts +0 -0
- /package/dist/{src/schemas → schemas}/internal.js +0 -0
- /package/dist/{src/schemas → schemas}/property.js +0 -0
- /package/dist/{src/services → services}/storage/dummy.cache.d.ts +0 -0
- /package/dist/{src/services → services}/storage/dummy.cache.js +0 -0
- /package/dist/{src/services → services}/storage/filesystem.cache.d.ts +0 -0
- /package/dist/{src/services → services}/storage/filesystem.cache.js +0 -0
- /package/dist/{src/services → services}/storage/memory.cache.d.ts +0 -0
- /package/dist/{src/services → services}/storage/memory.cache.js +0 -0
- /package/dist/{src/services → services}/storage/types.d.ts +0 -0
- /package/dist/{src/services → services}/storage/types.js +0 -0
- /package/dist/{src/types → types}/index.d.ts +0 -0
- /package/dist/{src/types → types}/index.js +0 -0
- /package/dist/{src/utils → utils}/url.d.ts +0 -0
- /package/dist/{src/utils → utils}/url.js +0 -0
package/README.md
CHANGED
|
@@ -1,91 +1,357 @@
|
|
|
1
1
|
# Apimo.js
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
[](https://badge.fury.io/js/apimo.js)
|
|
4
|
+
[](https://github.com/Neikow/apimo.js/actions/workflows/ci.yml)
|
|
5
|
+
[](https://codecov.io/gh/Neikow/apimo.js)
|
|
4
6
|
|
|
5
|
-
|
|
7
|
+
A comprehensive TypeScript wrapper for the [Apimo API](https://apimo.net/en/api/webservice/) with intelligent caching,
|
|
8
|
+
rate limiting, and automatic catalog transformation for building custom Real Estate websites.
|
|
6
9
|
|
|
7
|
-
|
|
8
|
-
|
|
10
|
+
## Features
|
|
11
|
+
|
|
12
|
+
- 🚀 **TypeScript-first** - Full type safety with Zod schema validation
|
|
13
|
+
- 📦 **Smart Caching** - Multiple cache adapters (Memory, Filesystem, Dummy) with automatic invalidation
|
|
14
|
+
- 🔄 **Rate Limiting** - Built-in request throttling to respect API limits (1000 requests/day)
|
|
15
|
+
- 🌍 **Multi-language Support** - Automatic catalog transformation for localized content
|
|
16
|
+
- 🏗️ **Property & Agency APIs** - Complete coverage of Apimo's real estate endpoints
|
|
17
|
+
- ⚡ **Optimized Performance** - Intelligent catalog caching reduces API calls by 90%
|
|
18
|
+
|
|
19
|
+
## Installation
|
|
20
|
+
|
|
21
|
+
```bash
|
|
22
|
+
npm install apimo.js
|
|
23
|
+
# or
|
|
24
|
+
yarn add apimo.js
|
|
25
|
+
```
|
|
26
|
+
|
|
27
|
+
## Quick Start
|
|
28
|
+
|
|
29
|
+
```typescript
|
|
30
|
+
import { Apimo } from 'apimo.js'
|
|
9
31
|
|
|
10
32
|
const api = new Apimo(
|
|
11
|
-
'
|
|
12
|
-
'
|
|
33
|
+
'YOUR_BRIDGE_ID', // Get from Apimo support
|
|
34
|
+
'YOUR_API_TOKEN', // Get from Apimo support
|
|
13
35
|
{
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
properties: 1000 * 60 * 5, // 5 minutes
|
|
21
|
-
catalogs: 1000 * 60 * 60 * 24, // 24 hours
|
|
36
|
+
culture: 'en', // Default language
|
|
37
|
+
catalogs: {
|
|
38
|
+
cache: {
|
|
39
|
+
active: true,
|
|
40
|
+
adapter: new MemoryCache() // or FilesystemCache()
|
|
41
|
+
}
|
|
22
42
|
}
|
|
23
43
|
}
|
|
24
44
|
)
|
|
45
|
+
|
|
46
|
+
// Fetch properties with automatic catalog transformation
|
|
47
|
+
const properties = await api.getProperties({
|
|
48
|
+
limit: 10,
|
|
49
|
+
offset: 0
|
|
50
|
+
})
|
|
51
|
+
|
|
52
|
+
// Get a specific property
|
|
53
|
+
const property = await api.getProperty(123)
|
|
54
|
+
|
|
55
|
+
// Fetch agencies
|
|
56
|
+
const agencies = await api.getAgencies()
|
|
57
|
+
```
|
|
58
|
+
|
|
59
|
+
## Configuration
|
|
60
|
+
|
|
61
|
+
### Basic Configuration
|
|
62
|
+
|
|
63
|
+
```typescript
|
|
64
|
+
const api = new Apimo(bridgeId, token, {
|
|
65
|
+
baseUrl: 'https://api.apimo.pro', // API base URL
|
|
66
|
+
culture: 'en', // Default language (en, fr)
|
|
67
|
+
catalogs: {
|
|
68
|
+
cache: {
|
|
69
|
+
active: true, // Enable catalog caching
|
|
70
|
+
adapter: new MemoryCache() // Cache implementation
|
|
71
|
+
},
|
|
72
|
+
transform: {
|
|
73
|
+
active: true, // Enable catalog transformation
|
|
74
|
+
transformFn: customTransformer // Optional custom transformer
|
|
75
|
+
}
|
|
76
|
+
}
|
|
77
|
+
})
|
|
78
|
+
```
|
|
79
|
+
|
|
80
|
+
### Cache Adapters
|
|
81
|
+
|
|
82
|
+
#### Memory Cache (Default)
|
|
83
|
+
|
|
84
|
+
```typescript
|
|
85
|
+
import { MemoryCache } from 'apimo.js'
|
|
86
|
+
|
|
87
|
+
const api = new Apimo(bridgeId, token, {
|
|
88
|
+
catalogs: {
|
|
89
|
+
cache: {
|
|
90
|
+
adapter: new MemoryCache()
|
|
91
|
+
}
|
|
92
|
+
}
|
|
93
|
+
})
|
|
25
94
|
```
|
|
26
95
|
|
|
27
|
-
|
|
96
|
+
#### Filesystem Cache
|
|
28
97
|
|
|
29
|
-
|
|
98
|
+
```typescript
|
|
99
|
+
import { FilesystemCache } from 'apimo.js'
|
|
30
100
|
|
|
31
|
-
|
|
101
|
+
const api = new Apimo(bridgeId, token, {
|
|
102
|
+
catalogs: {
|
|
103
|
+
cache: {
|
|
104
|
+
adapter: new FilesystemCache('./cache')
|
|
105
|
+
}
|
|
106
|
+
}
|
|
107
|
+
})
|
|
108
|
+
```
|
|
32
109
|
|
|
33
|
-
|
|
110
|
+
#### Dummy Cache (No Caching)
|
|
111
|
+
|
|
112
|
+
```typescript
|
|
113
|
+
import { DummyCache } from 'apimo.js'
|
|
114
|
+
|
|
115
|
+
const api = new Apimo(bridgeId, token, {
|
|
116
|
+
catalogs: {
|
|
117
|
+
cache: {
|
|
118
|
+
adapter: new DummyCache()
|
|
119
|
+
}
|
|
120
|
+
}
|
|
121
|
+
})
|
|
122
|
+
```
|
|
34
123
|
|
|
35
|
-
|
|
36
|
-
It can cache requests in order to avoid reaching the API rate limit, which are pretty low (1000 requests per day).
|
|
37
|
-
The data can be set to be updated automatically, given a certain interval.
|
|
124
|
+
## API Reference
|
|
38
125
|
|
|
39
|
-
|
|
126
|
+
### Properties
|
|
40
127
|
|
|
41
|
-
|
|
128
|
+
#### `getProperties(options?)`
|
|
42
129
|
|
|
43
|
-
|
|
130
|
+
Fetch a list of properties with optional filtering.
|
|
44
131
|
|
|
45
|
-
```
|
|
46
|
-
|
|
47
|
-
|
|
132
|
+
```typescript
|
|
133
|
+
const properties = await api.getProperties({
|
|
134
|
+
limit: 20,
|
|
135
|
+
offset: 0,
|
|
136
|
+
culture: 'fr',
|
|
137
|
+
// Add property filters as needed
|
|
48
138
|
})
|
|
49
139
|
```
|
|
50
140
|
|
|
51
|
-
|
|
141
|
+
#### `getProperty(id, options?)`
|
|
52
142
|
|
|
53
|
-
|
|
143
|
+
Fetch a specific property by ID.
|
|
54
144
|
|
|
55
|
-
```
|
|
56
|
-
api.
|
|
57
|
-
|
|
145
|
+
```typescript
|
|
146
|
+
const property = await api.getProperty(123, {
|
|
147
|
+
culture: 'en'
|
|
58
148
|
})
|
|
59
149
|
```
|
|
60
150
|
|
|
61
|
-
|
|
62
|
-
the [Apimo API documentation](https://apimo.net/en/api/webservice/?child=agencies/properties#get-agencies/propertiesagencies-{agency_id}-properties).
|
|
151
|
+
### Agencies
|
|
63
152
|
|
|
64
|
-
|
|
153
|
+
#### `getAgencies(options?)`
|
|
65
154
|
|
|
66
|
-
|
|
155
|
+
Fetch a list of agencies.
|
|
67
156
|
|
|
68
|
-
```
|
|
69
|
-
api.
|
|
70
|
-
|
|
157
|
+
```typescript
|
|
158
|
+
const agencies = await api.getAgencies({
|
|
159
|
+
limit: 10,
|
|
160
|
+
culture: 'fr'
|
|
71
161
|
})
|
|
72
162
|
```
|
|
73
163
|
|
|
74
|
-
|
|
75
|
-
|
|
164
|
+
#### `getAgency(id, options?)`
|
|
165
|
+
|
|
166
|
+
Fetch a specific agency by ID.
|
|
167
|
+
|
|
168
|
+
```typescript
|
|
169
|
+
const agency = await api.getAgency(456)
|
|
170
|
+
```
|
|
171
|
+
|
|
172
|
+
### Catalogs
|
|
76
173
|
|
|
77
|
-
|
|
174
|
+
#### `fetchCatalogs()`
|
|
78
175
|
|
|
79
|
-
|
|
176
|
+
Get all available catalog definitions.
|
|
80
177
|
|
|
81
|
-
```
|
|
82
|
-
api.
|
|
83
|
-
|
|
178
|
+
```typescript
|
|
179
|
+
const catalogs = await api.fetchCatalogs()
|
|
180
|
+
```
|
|
181
|
+
|
|
182
|
+
#### `fetchCatalog(catalogName, options?)`
|
|
183
|
+
|
|
184
|
+
Fetch entries for a specific catalog.
|
|
185
|
+
|
|
186
|
+
```typescript
|
|
187
|
+
const propertyTypes = await api.fetchCatalog('property_type', {
|
|
188
|
+
culture: 'en'
|
|
84
189
|
})
|
|
85
190
|
```
|
|
86
191
|
|
|
87
|
-
|
|
192
|
+
#### `getCatalogEntries(catalogName, options?)`
|
|
193
|
+
|
|
194
|
+
Get catalog entries from cache (populates cache if needed).
|
|
195
|
+
|
|
196
|
+
```typescript
|
|
197
|
+
const entries = await api.getCatalogEntries('property_category', {
|
|
198
|
+
culture: 'fr'
|
|
199
|
+
})
|
|
200
|
+
```
|
|
201
|
+
|
|
202
|
+
### Low-level API
|
|
203
|
+
|
|
204
|
+
#### `get(path, schema, options?)`
|
|
205
|
+
|
|
206
|
+
Make a direct API call with schema validation.
|
|
207
|
+
|
|
208
|
+
```typescript
|
|
209
|
+
import { z } from 'zod'
|
|
210
|
+
|
|
211
|
+
const customSchema = z.object({
|
|
212
|
+
id: z.number(),
|
|
213
|
+
name: z.string()
|
|
214
|
+
})
|
|
215
|
+
|
|
216
|
+
const result = await api.get(['custom', 'endpoint'], customSchema, {
|
|
217
|
+
culture: 'en',
|
|
218
|
+
limit: 10
|
|
219
|
+
})
|
|
220
|
+
```
|
|
221
|
+
|
|
222
|
+
#### `fetch(...args)`
|
|
223
|
+
|
|
224
|
+
Direct fetch with automatic authentication headers.
|
|
225
|
+
|
|
226
|
+
```typescript
|
|
227
|
+
const response = await api.fetch('https://api.apimo.pro/properties')
|
|
228
|
+
```
|
|
229
|
+
|
|
230
|
+
## Data Transformation
|
|
231
|
+
|
|
232
|
+
Apimo.js automatically transforms catalog IDs into human-readable names:
|
|
233
|
+
|
|
234
|
+
```typescript
|
|
235
|
+
// Raw API response
|
|
236
|
+
const rawResponse = {
|
|
237
|
+
type: 1,
|
|
238
|
+
category: 2
|
|
239
|
+
}
|
|
240
|
+
|
|
241
|
+
// Transformed response
|
|
242
|
+
const transformedResponse = {
|
|
243
|
+
type: 'House',
|
|
244
|
+
category: 'Sale'
|
|
245
|
+
}
|
|
246
|
+
```
|
|
247
|
+
|
|
248
|
+
### Custom Transformers
|
|
249
|
+
|
|
250
|
+
```typescript
|
|
251
|
+
async function customTransformer(catalogName, culture, id) {
|
|
252
|
+
// Your custom transformation logic
|
|
253
|
+
return await myCustomCatalogLookup(catalogName, culture, id)
|
|
254
|
+
}
|
|
255
|
+
|
|
256
|
+
const api = new Apimo(bridgeId, token, {
|
|
257
|
+
catalogs: {
|
|
258
|
+
transform: {
|
|
259
|
+
active: true,
|
|
260
|
+
transformFn: customTransformer
|
|
261
|
+
}
|
|
262
|
+
}
|
|
263
|
+
})
|
|
264
|
+
```
|
|
265
|
+
|
|
266
|
+
## Rate Limiting
|
|
267
|
+
|
|
268
|
+
The library includes built-in rate limiting to respect Apimo's API limits:
|
|
269
|
+
|
|
270
|
+
- **10 requests per second** (configurable)
|
|
271
|
+
- **Automatic queuing** of excess requests
|
|
272
|
+
- **Bottleneck integration** for advanced rate limiting scenarios
|
|
273
|
+
|
|
274
|
+
## Error Handling
|
|
275
|
+
|
|
276
|
+
```typescript
|
|
277
|
+
try {
|
|
278
|
+
const properties = await api.getProperties()
|
|
279
|
+
}
|
|
280
|
+
catch (error) {
|
|
281
|
+
if (error instanceof CacheExpiredError) {
|
|
282
|
+
// Handle cache expiration
|
|
283
|
+
}
|
|
284
|
+
else {
|
|
285
|
+
// Handle other API errors
|
|
286
|
+
console.error('API Error:', error.message)
|
|
287
|
+
}
|
|
288
|
+
}
|
|
289
|
+
```
|
|
290
|
+
|
|
291
|
+
## TypeScript Support
|
|
292
|
+
|
|
293
|
+
Full TypeScript support with comprehensive type definitions:
|
|
294
|
+
|
|
295
|
+
```typescript
|
|
296
|
+
import type { Agency, CatalogEntry, Property } from 'apimo.js'
|
|
297
|
+
|
|
298
|
+
const property: Property = await api.getProperty(123)
|
|
299
|
+
const agency: Agency = await api.getAgency(456)
|
|
300
|
+
```
|
|
301
|
+
|
|
302
|
+
## Supported Languages
|
|
303
|
+
|
|
304
|
+
- English (`en`)
|
|
305
|
+
- French (`fr`)
|
|
306
|
+
|
|
307
|
+
More languages can be added based on Apimo API support.
|
|
308
|
+
|
|
309
|
+
## Contributing
|
|
310
|
+
|
|
311
|
+
1. Fork the repository
|
|
312
|
+
2. Create your feature branch (`git checkout -b feature/amazing-feature`)
|
|
313
|
+
3. Commit your changes (`git commit -m 'Add some amazing feature'`)
|
|
314
|
+
4. Push to the branch (`git push origin feature/amazing-feature`)
|
|
315
|
+
5. Open a Pull Request
|
|
316
|
+
|
|
317
|
+
### Development
|
|
88
318
|
|
|
89
319
|
```bash
|
|
90
|
-
|
|
320
|
+
# Install dependencies
|
|
321
|
+
yarn install
|
|
322
|
+
|
|
323
|
+
# Run tests
|
|
324
|
+
yarn test
|
|
325
|
+
|
|
326
|
+
# Run tests with coverage
|
|
327
|
+
yarn test-coverage
|
|
328
|
+
|
|
329
|
+
# Run linting
|
|
330
|
+
yarn lint
|
|
331
|
+
|
|
332
|
+
# Build the package
|
|
333
|
+
yarn build
|
|
91
334
|
```
|
|
335
|
+
|
|
336
|
+
## License
|
|
337
|
+
|
|
338
|
+
MIT License - see the [LICENSE](LICENSE) file for details.
|
|
339
|
+
|
|
340
|
+
## Getting API Credentials
|
|
341
|
+
|
|
342
|
+
To use this library, you need:
|
|
343
|
+
|
|
344
|
+
1. **Bridge ID** - Your site identifier (string of numbers)
|
|
345
|
+
2. **API Token** - Secret token for authentication
|
|
346
|
+
|
|
347
|
+
Contact [Apimo customer service](https://apimo.net/en/contact/) to request your credentials.
|
|
348
|
+
|
|
349
|
+
## Support
|
|
350
|
+
|
|
351
|
+
- 📖 [Apimo API Documentation](https://apimo.net/en/api/webservice/)
|
|
352
|
+
- 🐛 [Issue Tracker](https://github.com/Neikow/apimo.js/issues)
|
|
353
|
+
- 💬 [Discussions](https://github.com/Neikow/apimo.js/discussions)
|
|
354
|
+
|
|
355
|
+
---
|
|
356
|
+
|
|
357
|
+
Made with ❤️ by [Vitaly Lysen](https://lysen.dev)
|
|
@@ -29,7 +29,7 @@ export interface AdditionalConfig {
|
|
|
29
29
|
}
|
|
30
30
|
export declare const DEFAULT_BASE_URL = "https://api.apimo.pro";
|
|
31
31
|
export declare const DEFAULT_ADDITIONAL_CONFIG: AdditionalConfig;
|
|
32
|
-
export declare class
|
|
32
|
+
export declare class Apimo {
|
|
33
33
|
private readonly provider;
|
|
34
34
|
private readonly token;
|
|
35
35
|
readonly config: AdditionalConfig;
|
package/dist/index.d.ts
ADDED
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
export type { CatalogName } from './consts/catalogs';
|
|
2
|
+
export type { ApiCulture } from './consts/languages';
|
|
3
|
+
export { type AdditionalConfig, Apimo, DEFAULT_ADDITIONAL_CONFIG, DEFAULT_BASE_URL } from './core/api';
|
|
4
|
+
export { Apimo as Api } from './core/api';
|
|
5
|
+
export type { CatalogDefinition, CatalogEntry, CatalogTransformer, LocalizedCatalogTransformer } from './schemas/common';
|
|
6
|
+
export { DummyCache } from './services/storage/dummy.cache';
|
|
7
|
+
export { FilesystemCache } from './services/storage/filesystem.cache';
|
|
8
|
+
export { MemoryCache } from './services/storage/memory.cache';
|
|
9
|
+
export { type ApiCacheAdapter, CacheExpiredError, type CatalogEntryName } from './services/storage/types';
|
|
10
|
+
export type { DeepPartial } from './types';
|
|
11
|
+
export type { ApiSearchParams } from './utils/url';
|
package/dist/index.js
ADDED
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
// Main exports
|
|
2
|
+
export { Apimo, DEFAULT_ADDITIONAL_CONFIG, DEFAULT_BASE_URL } from './core/api';
|
|
3
|
+
// Backward compatibility - keep Api as alias
|
|
4
|
+
export { Apimo as Api } from './core/api';
|
|
5
|
+
export { DummyCache } from './services/storage/dummy.cache';
|
|
6
|
+
export { FilesystemCache } from './services/storage/filesystem.cache';
|
|
7
|
+
// Cache adapters
|
|
8
|
+
export { MemoryCache } from './services/storage/memory.cache';
|
|
9
|
+
// Cache types and errors
|
|
10
|
+
export { CacheExpiredError } from './services/storage/types';
|
|
@@ -3,7 +3,7 @@ import type { LocalizedCatalogTransformer } from './common';
|
|
|
3
3
|
import { z } from 'zod';
|
|
4
4
|
export declare function getRateSchema(transformer: LocalizedCatalogTransformer): z.ZodObject<{
|
|
5
5
|
id: z.ZodNumber;
|
|
6
|
-
category: z.ZodEffects<z.ZodNumber, string | import("
|
|
6
|
+
category: z.ZodEffects<z.ZodNumber, string | import("..").CatalogEntryName | null, number>;
|
|
7
7
|
range_min: z.ZodNullable<z.ZodNumber>;
|
|
8
8
|
range_max: z.ZodNullable<z.ZodNumber>;
|
|
9
9
|
commission_price: z.ZodNullable<z.ZodNumber>;
|
|
@@ -12,7 +12,7 @@ export declare function getRateSchema(transformer: LocalizedCatalogTransformer):
|
|
|
12
12
|
url: z.ZodNullable<z.ZodString>;
|
|
13
13
|
}, "strip", z.ZodTypeAny, {
|
|
14
14
|
id: number;
|
|
15
|
-
category: string | import("
|
|
15
|
+
category: string | import("..").CatalogEntryName | null;
|
|
16
16
|
range_min: number | null;
|
|
17
17
|
range_max: number | null;
|
|
18
18
|
commission_price: number | null;
|
|
@@ -103,7 +103,7 @@ export declare function getAgencySchema(transformer: LocalizedCatalogTransformer
|
|
|
103
103
|
providers: z.ZodEffects<z.ZodString, string, string>;
|
|
104
104
|
rates: z.ZodArray<z.ZodObject<{
|
|
105
105
|
id: z.ZodNumber;
|
|
106
|
-
category: z.ZodEffects<z.ZodNumber, string | import("
|
|
106
|
+
category: z.ZodEffects<z.ZodNumber, string | import("..").CatalogEntryName | null, number>;
|
|
107
107
|
range_min: z.ZodNullable<z.ZodNumber>;
|
|
108
108
|
range_max: z.ZodNullable<z.ZodNumber>;
|
|
109
109
|
commission_price: z.ZodNullable<z.ZodNumber>;
|
|
@@ -112,7 +112,7 @@ export declare function getAgencySchema(transformer: LocalizedCatalogTransformer
|
|
|
112
112
|
url: z.ZodNullable<z.ZodString>;
|
|
113
113
|
}, "strip", z.ZodTypeAny, {
|
|
114
114
|
id: number;
|
|
115
|
-
category: string | import("
|
|
115
|
+
category: string | import("..").CatalogEntryName | null;
|
|
116
116
|
range_min: number | null;
|
|
117
117
|
range_max: number | null;
|
|
118
118
|
commission_price: number | null;
|
|
@@ -164,7 +164,7 @@ export declare function getAgencySchema(transformer: LocalizedCatalogTransformer
|
|
|
164
164
|
password: z.ZodOptional<z.ZodString>;
|
|
165
165
|
language: z.ZodString;
|
|
166
166
|
spoken_languages: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
167
|
-
group: z.ZodEffects<z.ZodNumber, string | import("
|
|
167
|
+
group: z.ZodEffects<z.ZodNumber, string | import("..").CatalogEntryName | null, number>;
|
|
168
168
|
email: z.ZodString;
|
|
169
169
|
phone: z.ZodNullable<z.ZodString>;
|
|
170
170
|
mobile: z.ZodString;
|
|
@@ -194,7 +194,7 @@ export declare function getAgencySchema(transformer: LocalizedCatalogTransformer
|
|
|
194
194
|
firstname: string;
|
|
195
195
|
lastname: string;
|
|
196
196
|
language: string;
|
|
197
|
-
group: string | import("
|
|
197
|
+
group: string | import("..").CatalogEntryName | null;
|
|
198
198
|
email: string;
|
|
199
199
|
phone: string | null;
|
|
200
200
|
mobile: string;
|
|
@@ -269,7 +269,7 @@ export declare function getAgencySchema(transformer: LocalizedCatalogTransformer
|
|
|
269
269
|
stories: unknown[];
|
|
270
270
|
rates: {
|
|
271
271
|
id: number;
|
|
272
|
-
category: string | import("
|
|
272
|
+
category: string | import("..").CatalogEntryName | null;
|
|
273
273
|
range_min: number | null;
|
|
274
274
|
range_max: number | null;
|
|
275
275
|
commission_price: number | null;
|
|
@@ -304,7 +304,7 @@ export declare function getAgencySchema(transformer: LocalizedCatalogTransformer
|
|
|
304
304
|
firstname: string;
|
|
305
305
|
lastname: string;
|
|
306
306
|
language: string;
|
|
307
|
-
group: string | import("
|
|
307
|
+
group: string | import("..").CatalogEntryName | null;
|
|
308
308
|
email: string;
|
|
309
309
|
phone: string | null;
|
|
310
310
|
mobile: string;
|