deere-sdk 1.0.9 → 2.0.0

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.
Files changed (143) hide show
  1. package/CHANGELOG.md +148 -0
  2. package/README.md +68 -0
  3. package/dist/api/aemp.d.ts +4 -0
  4. package/dist/api/aemp.d.ts.map +1 -1
  5. package/dist/api/aemp.js +5 -1
  6. package/dist/api/aemp.js.map +1 -1
  7. package/dist/api/assets.d.ts +4 -0
  8. package/dist/api/assets.d.ts.map +1 -1
  9. package/dist/api/assets.js +13 -9
  10. package/dist/api/assets.js.map +1 -1
  11. package/dist/api/boundaries.d.ts +4 -0
  12. package/dist/api/boundaries.d.ts.map +1 -1
  13. package/dist/api/boundaries.js +12 -8
  14. package/dist/api/boundaries.js.map +1 -1
  15. package/dist/api/clients.d.ts +4 -0
  16. package/dist/api/clients.d.ts.map +1 -1
  17. package/dist/api/clients.js +12 -8
  18. package/dist/api/clients.js.map +1 -1
  19. package/dist/api/connection-management.d.ts +4 -0
  20. package/dist/api/connection-management.d.ts.map +1 -1
  21. package/dist/api/connection-management.js +8 -4
  22. package/dist/api/connection-management.js.map +1 -1
  23. package/dist/api/crop-types.d.ts +4 -0
  24. package/dist/api/crop-types.d.ts.map +1 -1
  25. package/dist/api/crop-types.js +9 -5
  26. package/dist/api/crop-types.js.map +1 -1
  27. package/dist/api/equipment-measurement.d.ts +4 -0
  28. package/dist/api/equipment-measurement.d.ts.map +1 -1
  29. package/dist/api/equipment-measurement.js +5 -1
  30. package/dist/api/equipment-measurement.js.map +1 -1
  31. package/dist/api/equipment.d.ts +4 -0
  32. package/dist/api/equipment.d.ts.map +1 -1
  33. package/dist/api/equipment.js +20 -16
  34. package/dist/api/equipment.js.map +1 -1
  35. package/dist/api/farms.d.ts +4 -0
  36. package/dist/api/farms.d.ts.map +1 -1
  37. package/dist/api/farms.js +12 -8
  38. package/dist/api/farms.js.map +1 -1
  39. package/dist/api/field-operations-api.d.ts +4 -0
  40. package/dist/api/field-operations-api.d.ts.map +1 -1
  41. package/dist/api/field-operations-api.js +8 -4
  42. package/dist/api/field-operations-api.js.map +1 -1
  43. package/dist/api/fields.d.ts +4 -0
  44. package/dist/api/fields.d.ts.map +1 -1
  45. package/dist/api/fields.js +12 -8
  46. package/dist/api/fields.js.map +1 -1
  47. package/dist/api/files.d.ts +4 -0
  48. package/dist/api/files.d.ts.map +1 -1
  49. package/dist/api/files.js +10 -6
  50. package/dist/api/files.js.map +1 -1
  51. package/dist/api/flags.d.ts +4 -0
  52. package/dist/api/flags.d.ts.map +1 -1
  53. package/dist/api/flags.js +11 -7
  54. package/dist/api/flags.js.map +1 -1
  55. package/dist/api/guidance-lines.d.ts +4 -0
  56. package/dist/api/guidance-lines.d.ts.map +1 -1
  57. package/dist/api/guidance-lines.js +9 -5
  58. package/dist/api/guidance-lines.js.map +1 -1
  59. package/dist/api/harvest-id.d.ts +4 -0
  60. package/dist/api/harvest-id.d.ts.map +1 -1
  61. package/dist/api/harvest-id.js +7 -3
  62. package/dist/api/harvest-id.js.map +1 -1
  63. package/dist/api/machine-alerts.d.ts +4 -0
  64. package/dist/api/machine-alerts.d.ts.map +1 -1
  65. package/dist/api/machine-alerts.js +6 -2
  66. package/dist/api/machine-alerts.js.map +1 -1
  67. package/dist/api/machine-device-state-reports.d.ts +4 -0
  68. package/dist/api/machine-device-state-reports.d.ts.map +1 -1
  69. package/dist/api/machine-device-state-reports.js +5 -1
  70. package/dist/api/machine-device-state-reports.js.map +1 -1
  71. package/dist/api/machine-engine-hours.d.ts +4 -0
  72. package/dist/api/machine-engine-hours.d.ts.map +1 -1
  73. package/dist/api/machine-engine-hours.js +6 -2
  74. package/dist/api/machine-engine-hours.js.map +1 -1
  75. package/dist/api/machine-hours-of-operation.d.ts +4 -0
  76. package/dist/api/machine-hours-of-operation.d.ts.map +1 -1
  77. package/dist/api/machine-hours-of-operation.js +6 -2
  78. package/dist/api/machine-hours-of-operation.js.map +1 -1
  79. package/dist/api/machine-locations.d.ts +4 -0
  80. package/dist/api/machine-locations.d.ts.map +1 -1
  81. package/dist/api/machine-locations.js +5 -1
  82. package/dist/api/machine-locations.js.map +1 -1
  83. package/dist/api/map-layers.d.ts +4 -0
  84. package/dist/api/map-layers.d.ts.map +1 -1
  85. package/dist/api/map-layers.js +9 -5
  86. package/dist/api/map-layers.js.map +1 -1
  87. package/dist/api/notifications.d.ts +4 -0
  88. package/dist/api/notifications.d.ts.map +1 -1
  89. package/dist/api/notifications.js +9 -5
  90. package/dist/api/notifications.js.map +1 -1
  91. package/dist/api/operators.d.ts +4 -0
  92. package/dist/api/operators.d.ts.map +1 -1
  93. package/dist/api/operators.js +11 -7
  94. package/dist/api/operators.js.map +1 -1
  95. package/dist/api/organizations.d.ts +4 -0
  96. package/dist/api/organizations.d.ts.map +1 -1
  97. package/dist/api/organizations.js +9 -5
  98. package/dist/api/organizations.js.map +1 -1
  99. package/dist/api/partnerships.d.ts +4 -0
  100. package/dist/api/partnerships.d.ts.map +1 -1
  101. package/dist/api/partnerships.js +11 -7
  102. package/dist/api/partnerships.js.map +1 -1
  103. package/dist/api/products.d.ts +4 -0
  104. package/dist/api/products.d.ts.map +1 -1
  105. package/dist/api/products.js +14 -10
  106. package/dist/api/products.js.map +1 -1
  107. package/dist/api/users.d.ts +4 -0
  108. package/dist/api/users.d.ts.map +1 -1
  109. package/dist/api/users.js +5 -1
  110. package/dist/api/users.js.map +1 -1
  111. package/dist/api/webhook.d.ts +4 -0
  112. package/dist/api/webhook.d.ts.map +1 -1
  113. package/dist/api/webhook.js +9 -5
  114. package/dist/api/webhook.js.map +1 -1
  115. package/dist/api-servers.generated.d.ts +72 -0
  116. package/dist/api-servers.generated.d.ts.map +1 -0
  117. package/dist/api-servers.generated.js +344 -0
  118. package/dist/api-servers.generated.js.map +1 -0
  119. package/dist/client.d.ts +122 -36
  120. package/dist/client.d.ts.map +1 -1
  121. package/dist/client.js +302 -71
  122. package/dist/client.js.map +1 -1
  123. package/dist/environment-resolver.d.ts +40 -0
  124. package/dist/environment-resolver.d.ts.map +1 -0
  125. package/dist/environment-resolver.js +79 -0
  126. package/dist/environment-resolver.js.map +1 -0
  127. package/dist/errors.d.ts +36 -0
  128. package/dist/errors.d.ts.map +1 -0
  129. package/dist/errors.js +54 -0
  130. package/dist/errors.js.map +1 -0
  131. package/dist/hateoas-map.d.ts +25 -0
  132. package/dist/hateoas-map.d.ts.map +1 -0
  133. package/dist/hateoas-map.js +176 -0
  134. package/dist/hateoas-map.js.map +1 -0
  135. package/dist/index.d.ts +1 -1
  136. package/dist/index.d.ts.map +1 -1
  137. package/dist/index.js +1 -1
  138. package/dist/index.js.map +1 -1
  139. package/package.json +4 -3
  140. package/dist/api/field-operations.d.ts +0 -83
  141. package/dist/api/field-operations.d.ts.map +0 -1
  142. package/dist/api/field-operations.js +0 -134
  143. package/dist/api/field-operations.js.map +0 -1
@@ -0,0 +1,344 @@
1
+ /**
2
+ * API server configuration per spec — single source of truth for URL resolution.
3
+ *
4
+ * @generated by scripts/generate-api-servers.ts — do not edit manually
5
+ * Last generated: 2026-04-13T20:34:18.775Z
6
+ *
7
+ * Env coverage matrix (X = supported, - = throws UnsupportedEnvironmentError):
8
+ *
9
+ * api sandboxapi partnerapi apicert apiqa.tal partnerapicert partnerapiqa sandboxapiqa apidev.tal
10
+ * aemp X X X - - - - - -
11
+ * assets X X X X X - - - -
12
+ * boundaries X X X X X X X X -
13
+ * clients X X X X X - - - -
14
+ * connection-management X X - X X - - - -
15
+ * crop-types X X X X X X X X -
16
+ * equipment-measurement X - X X X X X X -
17
+ * equipment X - X - - - - - -
18
+ * farms X X X X X - - - -
19
+ * field-operations-api X X X X X X X X -
20
+ * fields X X X X X - - - -
21
+ * files X X X X X X X X X
22
+ * flags X X X X X X X X X
23
+ * guidance-lines X X X X X - - - X
24
+ * harvest-id X X X X X X X X -
25
+ * machine-alerts X X X X X X X X X
26
+ * machine-device-state-reports X X X X X - - - -
27
+ * machine-engine-hours X X X X X - - - -
28
+ * machine-hours-of-operation X X X X X - - - -
29
+ * machine-locations X X X X X X X X X
30
+ * map-layers X X X X X - - - -
31
+ * notifications X X X X X X X X X
32
+ * operators X X - X X - - - -
33
+ * organizations X X X X X X X X X
34
+ * partnerships X X X X X X X X X
35
+ * products X X X X X - - - X
36
+ * users X X X X X - - - -
37
+ * webhook X X X X X - - - X
38
+ *
39
+ * A dash (-) means the env is NOT supported for that spec. Calling a method
40
+ * on that API with that env throws UnsupportedEnvironmentError at request
41
+ * time, before any HTTP call — no silent cross-tier routing.
42
+ */
43
+ export const KNOWN_ENVIRONMENTS = [
44
+ 'api',
45
+ 'sandboxapi',
46
+ 'partnerapi',
47
+ 'apicert',
48
+ 'apiqa.tal',
49
+ 'partnerapicert',
50
+ 'partnerapiqa',
51
+ 'sandboxapiqa',
52
+ 'apidev.tal',
53
+ ];
54
+ /**
55
+ * Default environment for new DeereClient instances when config.environment
56
+ * is not specified. 'sandboxapi' is safe-by-default — never silently hits
57
+ * production data.
58
+ */
59
+ export const DEFAULT_ENVIRONMENT = 'sandboxapi';
60
+ // ============================================================================
61
+ // API_SERVERS — the resolver's lookup table, keyed by spec name
62
+ // ============================================================================
63
+ export const API_SERVERS = {
64
+ aemp: {
65
+ kind: 'static',
66
+ urlByEnvironment: {
67
+ api: 'https://partneraemp.deere.com',
68
+ partnerapi: 'https://partneraemp.deere.com',
69
+ sandboxapi: 'https://sandboxaemp.deere.com',
70
+ },
71
+ },
72
+ assets: {
73
+ kind: 'templated',
74
+ urlTemplate: 'https://{environment}.deere.com/platform',
75
+ supportedEnvironments: ['api', 'apicert', 'apiqa.tal', 'sandboxapi', 'partnerapi'],
76
+ },
77
+ boundaries: {
78
+ kind: 'templated',
79
+ urlTemplate: 'https://{environment}.deere.com/platform',
80
+ supportedEnvironments: [
81
+ 'api',
82
+ 'partnerapi',
83
+ 'sandboxapi',
84
+ 'apicert',
85
+ 'partnerapicert',
86
+ 'apiqa.tal',
87
+ 'partnerapiqa',
88
+ 'sandboxapiqa',
89
+ ],
90
+ },
91
+ clients: {
92
+ kind: 'templated',
93
+ urlTemplate: 'https://{environment}.deere.com/platform',
94
+ supportedEnvironments: ['api', 'apicert', 'apiqa.tal', 'sandboxapi', 'partnerapi'],
95
+ },
96
+ 'connection-management': {
97
+ kind: 'templated',
98
+ urlTemplate: 'https://{environment}.deere.com/platform',
99
+ supportedEnvironments: ['api', 'apicert', 'apiqa.tal', 'sandboxapi'],
100
+ },
101
+ 'crop-types': {
102
+ kind: 'templated',
103
+ urlTemplate: 'https://{environment}.deere.com/platform',
104
+ supportedEnvironments: [
105
+ 'api',
106
+ 'partnerapi',
107
+ 'sandboxapi',
108
+ 'apicert',
109
+ 'partnerapicert',
110
+ 'apiqa.tal',
111
+ 'partnerapiqa',
112
+ 'sandboxapiqa',
113
+ ],
114
+ },
115
+ 'equipment-measurement': {
116
+ kind: 'static',
117
+ urlByEnvironment: {
118
+ api: 'https://equipmentapi.deere.com/isg',
119
+ partnerapi: 'https://equipmentapi.deere.com/isg',
120
+ apicert: 'https://equipmentapi-cert.deere.com/isg',
121
+ partnerapicert: 'https://equipmentapi-cert.deere.com/isg',
122
+ 'apiqa.tal': 'https://equipmentapi-qual.deere.com/isg',
123
+ partnerapiqa: 'https://equipmentapi-qual.deere.com/isg',
124
+ sandboxapiqa: 'https://equipmentapi-qual.deere.com/isg',
125
+ },
126
+ },
127
+ equipment: {
128
+ kind: 'static',
129
+ urlByEnvironment: {
130
+ api: 'https://equipmentapi.deere.com/isg',
131
+ partnerapi: 'https://equipmentapi.deere.com/isg',
132
+ },
133
+ },
134
+ farms: {
135
+ kind: 'templated',
136
+ urlTemplate: 'https://{environment}.deere.com/platform',
137
+ supportedEnvironments: ['api', 'apicert', 'apiqa.tal', 'sandboxapi', 'partnerapi'],
138
+ },
139
+ 'field-operations-api': {
140
+ kind: 'templated',
141
+ urlTemplate: 'https://{environment}.deere.com/platform',
142
+ supportedEnvironments: [
143
+ 'api',
144
+ 'partnerapi',
145
+ 'sandboxapi',
146
+ 'apicert',
147
+ 'partnerapicert',
148
+ 'apiqa.tal',
149
+ 'partnerapiqa',
150
+ 'sandboxapiqa',
151
+ ],
152
+ },
153
+ fields: {
154
+ kind: 'templated',
155
+ urlTemplate: 'https://{environment}.deere.com/platform',
156
+ supportedEnvironments: ['api', 'apicert', 'apiqa.tal', 'sandboxapi', 'partnerapi'],
157
+ },
158
+ files: {
159
+ kind: 'templated',
160
+ urlTemplate: 'https://{environment}.deere.com/platform',
161
+ supportedEnvironments: [
162
+ 'api',
163
+ 'sandboxapi',
164
+ 'partnerapi',
165
+ 'apicert',
166
+ 'apiqa.tal',
167
+ 'apidev.tal',
168
+ 'partnerapicert',
169
+ 'partnerapiqa',
170
+ 'sandboxapiqa',
171
+ ],
172
+ },
173
+ flags: {
174
+ kind: 'templated',
175
+ urlTemplate: 'https://{environment}.deere.com/platform',
176
+ supportedEnvironments: [
177
+ 'api',
178
+ 'sandboxapi',
179
+ 'partnerapi',
180
+ 'apicert',
181
+ 'apiqa.tal',
182
+ 'apidev.tal',
183
+ 'partnerapicert',
184
+ 'partnerapiqa',
185
+ 'sandboxapiqa',
186
+ ],
187
+ },
188
+ 'guidance-lines': {
189
+ kind: 'templated',
190
+ urlTemplate: 'https://{environment}.deere.com/platform',
191
+ supportedEnvironments: [
192
+ 'partnerapi',
193
+ 'sandboxapi',
194
+ 'api',
195
+ 'apicert',
196
+ 'apiqa.tal',
197
+ 'apidev.tal',
198
+ ],
199
+ },
200
+ 'harvest-id': {
201
+ kind: 'templated',
202
+ urlTemplate: 'https://{environment}.deere.com/platform',
203
+ supportedEnvironments: [
204
+ 'api',
205
+ 'partnerapi',
206
+ 'sandboxapi',
207
+ 'apicert',
208
+ 'partnerapicert',
209
+ 'apiqa.tal',
210
+ 'partnerapiqa',
211
+ 'sandboxapiqa',
212
+ ],
213
+ },
214
+ 'machine-alerts': {
215
+ kind: 'templated',
216
+ urlTemplate: 'https://{environment}.deere.com/platform',
217
+ supportedEnvironments: [
218
+ 'api',
219
+ 'sandboxapi',
220
+ 'partnerapi',
221
+ 'apicert',
222
+ 'apiqa.tal',
223
+ 'apidev.tal',
224
+ 'partnerapicert',
225
+ 'partnerapiqa',
226
+ 'sandboxapiqa',
227
+ ],
228
+ },
229
+ 'machine-device-state-reports': {
230
+ kind: 'templated',
231
+ urlTemplate: 'https://{environment}.deere.com/platform',
232
+ supportedEnvironments: ['api', 'apicert', 'apiqa.tal', 'sandboxapi', 'partnerapi'],
233
+ },
234
+ 'machine-engine-hours': {
235
+ kind: 'templated',
236
+ urlTemplate: 'https://{environment}.deere.com/platform',
237
+ supportedEnvironments: ['api', 'apicert', 'apiqa.tal', 'sandboxapi', 'partnerapi'],
238
+ },
239
+ 'machine-hours-of-operation': {
240
+ kind: 'templated',
241
+ urlTemplate: 'https://{environment}.deere.com/platform',
242
+ supportedEnvironments: ['api', 'apicert', 'apiqa.tal', 'sandboxapi', 'partnerapi'],
243
+ },
244
+ 'machine-locations': {
245
+ kind: 'templated',
246
+ urlTemplate: 'https://{environment}.deere.com/platform',
247
+ supportedEnvironments: [
248
+ 'api',
249
+ 'sandboxapi',
250
+ 'partnerapi',
251
+ 'apicert',
252
+ 'apiqa.tal',
253
+ 'apidev.tal',
254
+ 'partnerapicert',
255
+ 'partnerapiqa',
256
+ 'sandboxapiqa',
257
+ ],
258
+ },
259
+ 'map-layers': {
260
+ kind: 'templated',
261
+ urlTemplate: 'https://{environment}.deere.com/platform',
262
+ supportedEnvironments: ['api', 'apicert', 'apiqa.tal', 'sandboxapi', 'partnerapi'],
263
+ },
264
+ notifications: {
265
+ kind: 'templated',
266
+ urlTemplate: 'https://{environment}.deere.com/platform',
267
+ supportedEnvironments: [
268
+ 'api',
269
+ 'sandboxapi',
270
+ 'partnerapi',
271
+ 'apicert',
272
+ 'apiqa.tal',
273
+ 'apidev.tal',
274
+ 'partnerapicert',
275
+ 'partnerapiqa',
276
+ 'sandboxapiqa',
277
+ ],
278
+ },
279
+ operators: {
280
+ kind: 'templated',
281
+ urlTemplate: 'https://{environment}.deere.com/platform',
282
+ supportedEnvironments: ['api', 'apicert', 'apiqa.tal', 'sandboxapi'],
283
+ },
284
+ organizations: {
285
+ kind: 'templated',
286
+ urlTemplate: 'https://{environment}.deere.com/platform',
287
+ supportedEnvironments: [
288
+ 'api',
289
+ 'sandboxapi',
290
+ 'partnerapi',
291
+ 'apicert',
292
+ 'apiqa.tal',
293
+ 'apidev.tal',
294
+ 'partnerapicert',
295
+ 'partnerapiqa',
296
+ 'sandboxapiqa',
297
+ ],
298
+ },
299
+ partnerships: {
300
+ kind: 'templated',
301
+ urlTemplate: 'https://{environment}.deere.com/platform',
302
+ supportedEnvironments: [
303
+ 'api',
304
+ 'sandboxapi',
305
+ 'partnerapi',
306
+ 'apicert',
307
+ 'apiqa.tal',
308
+ 'apidev.tal',
309
+ 'partnerapicert',
310
+ 'partnerapiqa',
311
+ 'sandboxapiqa',
312
+ ],
313
+ },
314
+ products: {
315
+ kind: 'templated',
316
+ urlTemplate: 'https://{environment}.deere.com/platform',
317
+ supportedEnvironments: [
318
+ 'partnerapi',
319
+ 'sandboxapi',
320
+ 'api',
321
+ 'apicert',
322
+ 'apiqa.tal',
323
+ 'apidev.tal',
324
+ ],
325
+ },
326
+ users: {
327
+ kind: 'templated',
328
+ urlTemplate: 'https://{environment}.deere.com/platform',
329
+ supportedEnvironments: ['api', 'apicert', 'apiqa.tal', 'sandboxapi', 'partnerapi'],
330
+ },
331
+ webhook: {
332
+ kind: 'templated',
333
+ urlTemplate: 'https://{environment}.deere.com/platform',
334
+ supportedEnvironments: [
335
+ 'api',
336
+ 'apicert',
337
+ 'apiqa.tal',
338
+ 'apidev.tal',
339
+ 'sandboxapi',
340
+ 'partnerapi',
341
+ ],
342
+ },
343
+ };
344
+ //# sourceMappingURL=api-servers.generated.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"api-servers.generated.js","sourceRoot":"","sources":["../src/api-servers.generated.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;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YAAY;YACZ,YAAY;YACZ,KAAK;YACL,SAAS;YACT,WAAW;YACX,YAAY;SACb;KACF;IACD,KAAK,EAAE;QACL,IAAI,EAAE,WAAW;QACjB,WAAW,EAAE,0CAA0C;QACvD,qBAAqB,EAAE,CAAC,KAAK,EAAE,SAAS,EAAE,WAAW,EAAE,YAAY,EAAE,YAAY,CAAC;KACnF;IACD,OAAO,EAAE;QACP,IAAI,EAAE,WAAW;QACjB,WAAW,EAAE,0CAA0C;QACvD,qBAAqB,EAAE;YACrB,KAAK;YACL,SAAS;YACT,WAAW;YACX,YAAY;YACZ,YAAY;YACZ,YAAY;SACb;KACF;CACF,CAAC"}
package/dist/client.d.ts CHANGED
@@ -2,16 +2,49 @@
2
2
  * John Deere API Client
3
3
  *
4
4
  * Unofficial TypeScript SDK for John Deere Operations Center API.
5
- * Provides typed access to all John Deere agricultural APIs.
5
+ *
6
+ * URL resolution flow (v2.0):
7
+ *
8
+ * User code
9
+ * │
10
+ * ▼
11
+ * deere.equipmentMeasurement.post(params)
12
+ * │
13
+ * ▼
14
+ * this.client.post('equipment-measurement', '/orgs/.../measurements', data, options)
15
+ * │
16
+ * ▼
17
+ * DeereClient.post()
18
+ * ├─ resolveRequestUrl(spec, path, this.environment)
19
+ * │ ├─ API_SERVERS[spec] lookup
20
+ * │ ├─ templated → urlTemplate.replace('{environment}', env)
21
+ * │ ├─ static → urlByEnvironment[env] (throws UnsupportedEnvironmentError if missing)
22
+ * │ └─ unavailable → throws NoServerConfigError
23
+ * └─ requestUrl('POST', url, body, options)
24
+ * └─ fetch(url, ...) with retry + timeout
25
+ *
26
+ * Absolute URLs bypass the resolver via fetchUrl() — used for HATEOAS next-page
27
+ * links and power-user escape hatches. fetchUrl attaches the Bearer token ONLY
28
+ * to *.deere.com hosts; third-party URLs get no Authorization header.
29
+ *
30
+ * URL data lives in src/api-servers.generated.ts, built from OpenAPI specs at
31
+ * build time by scripts/generate-api-servers.ts. Never hand-edit that file.
6
32
  */
7
- export type Environment = 'production' | 'sandbox' | 'partner' | 'cert' | 'qa';
33
+ import { type Environment, type SpecName } from './api-servers.generated.js';
34
+ export type { Environment, SpecName };
8
35
  export interface DeereClientConfig {
9
36
  /** OAuth access token */
10
37
  accessToken: string;
11
- /** API environment. Defaults to 'sandbox' */
38
+ /**
39
+ * API environment — uses raw JD subdomain names. Defaults to 'sandboxapi'.
40
+ *
41
+ * Valid values: 'api' | 'sandboxapi' | 'partnerapi' | 'apicert' | 'apiqa.tal'
42
+ * | 'partnerapicert' | 'partnerapiqa' | 'sandboxapiqa' | 'apidev.tal'
43
+ *
44
+ * Migration from v1: 'production' → 'api', 'sandbox' → 'sandboxapi',
45
+ * 'partner' → 'partnerapi', 'cert' → 'apicert', 'qa' → 'apiqa.tal'.
46
+ */
12
47
  environment?: Environment;
13
- /** Custom base URL (overrides environment) */
14
- baseUrl?: string;
15
48
  /** Custom fetch implementation */
16
49
  fetch?: typeof fetch;
17
50
  /** Default headers to include in all requests */
@@ -20,6 +53,15 @@ export interface DeereClientConfig {
20
53
  timeout?: number;
21
54
  /** Maximum number of retry attempts for failed requests. Defaults to 3. Set to 0 to disable retries. */
22
55
  maxRetries?: number;
56
+ /**
57
+ * Enable HATEOAS link traversal. When true, the client fetches parent resources
58
+ * and follows HAL links instead of constructing URLs directly.
59
+ * Required for John Deere production API certification.
60
+ * @default false
61
+ */
62
+ hateoas?: boolean;
63
+ /** Log HATEOAS resolution details to console for debugging. @default false */
64
+ hateoasDebug?: boolean;
23
65
  }
24
66
  export interface RetryConfig {
25
67
  /** Maximum number of retry attempts */
@@ -47,19 +89,8 @@ export interface Link {
47
89
  rel: string;
48
90
  uri: string;
49
91
  }
50
- export declare class DeereError extends Error {
51
- readonly status: number;
52
- readonly statusText: string;
53
- readonly body?: unknown | undefined;
54
- constructor(message: string, status: number, statusText: string, body?: unknown | undefined);
55
- }
56
- export declare class RateLimitError extends DeereError {
57
- readonly retryAfter?: number | undefined;
58
- constructor(message: string, status: number, statusText: string, retryAfter?: number | undefined, body?: unknown);
59
- }
60
- export declare class AuthError extends DeereError {
61
- constructor(message: string, status: number, statusText: string, body?: unknown);
62
- }
92
+ import { AuthError, DeereError, HateoasError, RateLimitError } from './errors.js';
93
+ export { AuthError, DeereError, HateoasError, RateLimitError };
63
94
  /**
64
95
  * John Deere API Client
65
96
  *
@@ -67,11 +98,12 @@ export declare class AuthError extends DeereError {
67
98
  * ```typescript
68
99
  * const client = new DeereClient({
69
100
  * accessToken: 'your-token',
70
- * environment: 'sandbox',
101
+ * environment: 'sandboxapi', // v2: raw JD subdomain, not 'sandbox'
71
102
  * maxRetries: 3, // Retries with exponential backoff (default: 3)
72
103
  * });
73
104
  *
74
- * const orgs = await client.get('/organizations');
105
+ * // v2: first arg is the spec name (generated classes do this for you)
106
+ * const orgs = await client.get('organizations', '/organizations');
75
107
  * ```
76
108
  *
77
109
  * @remarks
@@ -81,47 +113,101 @@ export declare class AuthError extends DeereError {
81
113
  * Set `maxRetries: 0` to disable automatic retries.
82
114
  */
83
115
  export declare class DeereClient {
84
- private readonly baseUrl;
116
+ private readonly environment;
85
117
  private readonly accessToken;
86
118
  private readonly fetchFn;
87
119
  private readonly defaultHeaders;
88
120
  private readonly timeout;
89
121
  private readonly retryConfig;
122
+ private readonly hateoas;
123
+ private readonly hateoasDebug;
124
+ private readonly linkCache;
90
125
  constructor(config: DeereClientConfig);
91
126
  /**
92
- * Make a GET request to the John Deere API
127
+ * Validates the environment string from config. Throws at construction
128
+ * time with a migration hint if the user passed a v1 friendly name or an
129
+ * unknown string — catches errors immediately instead of at first request.
93
130
  */
94
- get<T = unknown>(path: string, options?: RequestOptions): Promise<T>;
131
+ private validateEnvironment;
95
132
  /**
96
- * Make a POST request to the John Deere API
133
+ * GET request, spec-aware. Generated API classes call this with their own
134
+ * `spec` as the first argument — consumers don't normally call it directly.
97
135
  */
98
- post<T = unknown>(path: string, body?: unknown, options?: RequestOptions): Promise<T>;
136
+ get<T = unknown>(specName: SpecName, path: string, options?: RequestOptions): Promise<T>;
99
137
  /**
100
- * Make a PUT request to the John Deere API
138
+ * POST request, spec-aware.
101
139
  */
102
- put<T = unknown>(path: string, body?: unknown, options?: RequestOptions): Promise<T>;
140
+ post<T = unknown>(specName: SpecName, path: string, body?: unknown, options?: RequestOptions): Promise<T>;
103
141
  /**
104
- * Make a DELETE request to the John Deere API
142
+ * PUT request, spec-aware.
105
143
  */
106
- delete<T = unknown>(path: string, options?: RequestOptions): Promise<T>;
144
+ put<T = unknown>(specName: SpecName, path: string, body?: unknown, options?: RequestOptions): Promise<T>;
107
145
  /**
108
- * Make a PATCH request to the John Deere API
146
+ * DELETE request, spec-aware.
109
147
  */
110
- patch<T = unknown>(path: string, body?: unknown, options?: RequestOptions): Promise<T>;
148
+ delete<T = unknown>(specName: SpecName, path: string, options?: RequestOptions): Promise<T>;
111
149
  /**
112
- * Follow a HAL link from a response
150
+ * PATCH request, spec-aware.
151
+ */
152
+ patch<T = unknown>(specName: SpecName, path: string, body?: unknown, options?: RequestOptions): Promise<T>;
153
+ /**
154
+ * Fetch an absolute URL directly. Escape hatch for HATEOAS next-page links,
155
+ * HAL link traversal, and power users with pre-resolved URLs.
156
+ *
157
+ * **Security**: Attaches the Bearer token ONLY when the target hostname
158
+ * matches a trusted `*.deere.com` origin. Third-party URLs get NO
159
+ * Authorization header — prevents accidental token leakage to tracking or
160
+ * proxy services. If you need to send auth to a non-JD host, set
161
+ * `Authorization` explicitly via `options.headers`.
162
+ */
163
+ fetchUrl<T = unknown>(method: string, url: string, body?: unknown, options?: RequestOptions): Promise<T>;
164
+ /**
165
+ * Follow a HAL link from a response. Accepts a Link object or a raw URL
166
+ * string. Delegates to fetchUrl() so the trusted-host check applies.
113
167
  */
114
168
  followLink<T = unknown>(link: Link | string, options?: RequestOptions): Promise<T>;
115
169
  /**
116
- * Paginate through all results following nextPage links
170
+ * Paginate through all results following nextPage links. First page is
171
+ * resolved via the spec's URL config; subsequent pages use the absolute
172
+ * URLs returned by the API in `response.links`.
117
173
  */
118
- paginate<T>(path: string, options?: RequestOptions): AsyncGenerator<T[], void, unknown>;
174
+ paginate<T>(specName: SpecName, path: string, options?: RequestOptions): AsyncGenerator<T[], void, unknown>;
119
175
  /**
120
- * Get all items from a paginated endpoint
176
+ * Get all items from a paginated endpoint, spec-aware.
121
177
  */
122
- getAll<T>(path: string, options?: RequestOptions): Promise<T[]>;
178
+ getAll<T>(specName: SpecName, path: string, options?: RequestOptions): Promise<T[]>;
123
179
  private request;
124
180
  private requestUrl;
181
+ /**
182
+ * Clear the HATEOAS link cache. Useful for long-lived clients or testing.
183
+ */
184
+ clearLinkCache(): void;
185
+ /**
186
+ * Pre-fetch parent resources to warm the HATEOAS link cache.
187
+ * Reduces latency for subsequent HATEOAS-resolved requests.
188
+ *
189
+ * @param specName - Spec that owns the paths (e.g. 'organizations')
190
+ * @param paths - Parent resource paths to pre-fetch (defaults to '/organizations')
191
+ */
192
+ warmLinkCache(specName: SpecName, paths?: string[]): Promise<void>;
193
+ /**
194
+ * Match a concrete path against the HATEOAS route map.
195
+ * Returns the concrete parent path, rel name, and optional parentSpec
196
+ * (which spec owns the parent resource — used for cross-spec HATEOAS).
197
+ * Returns null if no map entry matches.
198
+ */
199
+ private matchHateoasPattern;
200
+ /**
201
+ * Resolve a path via HATEOAS link traversal, spec-aware.
202
+ *
203
+ * Fetches the parent resource (via the parent's own spec host, not the
204
+ * child's — critical for cross-spec flows like equipment.yaml's org-scoped
205
+ * endpoints whose parent `/organizations/{orgId}` lives on the platform
206
+ * host, not equipmentapi.deere.com/isg).
207
+ *
208
+ * Throws HateoasError if resolution fails.
209
+ */
210
+ private resolveHateoasUrl;
125
211
  /**
126
212
  * Check if an error/status code is retryable
127
213
  */
@@ -1 +1 @@
1
- {"version":3,"file":"client.d.ts","sourceRoot":"","sources":["../src/client.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,MAAM,MAAM,WAAW,GAAG,YAAY,GAAG,SAAS,GAAG,SAAS,GAAG,MAAM,GAAG,IA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