partnermax 0.2.1 → 0.4.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.
- package/CHANGELOG.md +38 -0
- package/README.md +41 -17
- package/client.d.mts +12 -6
- package/client.d.mts.map +1 -1
- package/client.d.ts +12 -6
- package/client.d.ts.map +1 -1
- package/client.js +14 -4
- package/client.js.map +1 -1
- package/client.mjs +14 -4
- package/client.mjs.map +1 -1
- package/core/pagination.d.mts +57 -0
- package/core/pagination.d.mts.map +1 -0
- package/core/pagination.d.ts +57 -0
- package/core/pagination.d.ts.map +1 -0
- package/core/pagination.js +108 -0
- package/core/pagination.js.map +1 -0
- package/core/pagination.mjs +102 -0
- package/core/pagination.mjs.map +1 -0
- package/index.d.mts +1 -0
- package/index.d.mts.map +1 -1
- package/index.d.ts +1 -0
- package/index.d.ts.map +1 -1
- package/index.js +3 -1
- package/index.js.map +1 -1
- package/index.mjs +1 -0
- package/index.mjs.map +1 -1
- package/internal/tslib.js +17 -17
- package/package.json +11 -1
- package/pagination.d.mts +3 -0
- package/pagination.d.mts.map +1 -0
- package/pagination.d.ts +3 -0
- package/pagination.d.ts.map +1 -0
- package/pagination.js +6 -0
- package/pagination.js.map +1 -0
- package/pagination.mjs +3 -0
- package/pagination.mjs.map +1 -0
- package/resources/dealers/dealers.d.mts +7 -71
- package/resources/dealers/dealers.d.mts.map +1 -1
- package/resources/dealers/dealers.d.ts +7 -71
- package/resources/dealers/dealers.d.ts.map +1 -1
- package/resources/dealers/dealers.js +2 -15
- package/resources/dealers/dealers.js.map +1 -1
- package/resources/dealers/dealers.mjs +2 -15
- package/resources/dealers/dealers.mjs.map +1 -1
- package/resources/dealers/index.d.mts +2 -2
- package/resources/dealers/index.d.mts.map +1 -1
- package/resources/dealers/index.d.ts +2 -2
- package/resources/dealers/index.d.ts.map +1 -1
- package/resources/dealers/index.js.map +1 -1
- package/resources/dealers/index.mjs.map +1 -1
- package/resources/dealers/nlt/index.d.mts +1 -1
- package/resources/dealers/nlt/index.d.mts.map +1 -1
- package/resources/dealers/nlt/index.d.ts +1 -1
- package/resources/dealers/nlt/index.d.ts.map +1 -1
- package/resources/dealers/nlt/nlt.d.mts +2 -2
- package/resources/dealers/nlt/nlt.d.mts.map +1 -1
- package/resources/dealers/nlt/nlt.d.ts +2 -2
- package/resources/dealers/nlt/nlt.d.ts.map +1 -1
- package/resources/dealers/nlt/offers.d.mts +55 -78
- package/resources/dealers/nlt/offers.d.mts.map +1 -1
- package/resources/dealers/nlt/offers.d.ts +55 -78
- package/resources/dealers/nlt/offers.d.ts.map +1 -1
- package/resources/dealers/nlt/offers.js +9 -11
- package/resources/dealers/nlt/offers.js.map +1 -1
- package/resources/dealers/nlt/offers.mjs +9 -11
- package/resources/dealers/nlt/offers.mjs.map +1 -1
- package/resources/dealers/nlt-settings.d.mts +24 -64
- package/resources/dealers/nlt-settings.d.mts.map +1 -1
- package/resources/dealers/nlt-settings.d.ts +24 -64
- package/resources/dealers/nlt-settings.d.ts.map +1 -1
- package/resources/dealers/nlt-settings.js +4 -13
- package/resources/dealers/nlt-settings.js.map +1 -1
- package/resources/dealers/nlt-settings.mjs +4 -13
- package/resources/dealers/nlt-settings.mjs.map +1 -1
- package/resources/dealers/vehicles/images.d.mts +3 -2
- package/resources/dealers/vehicles/images.d.mts.map +1 -1
- package/resources/dealers/vehicles/images.d.ts +3 -2
- package/resources/dealers/vehicles/images.d.ts.map +1 -1
- package/resources/dealers/vehicles/images.js +3 -2
- package/resources/dealers/vehicles/images.js.map +1 -1
- package/resources/dealers/vehicles/images.mjs +3 -2
- package/resources/dealers/vehicles/images.mjs.map +1 -1
- package/resources/dealers/vehicles/index.d.mts +1 -1
- package/resources/dealers/vehicles/index.d.mts.map +1 -1
- package/resources/dealers/vehicles/index.d.ts +1 -1
- package/resources/dealers/vehicles/index.d.ts.map +1 -1
- package/resources/dealers/vehicles/index.js.map +1 -1
- package/resources/dealers/vehicles/index.mjs.map +1 -1
- package/resources/dealers/vehicles/vehicles.d.mts +57 -70
- package/resources/dealers/vehicles/vehicles.d.mts.map +1 -1
- package/resources/dealers/vehicles/vehicles.d.ts +57 -70
- package/resources/dealers/vehicles/vehicles.d.ts.map +1 -1
- package/resources/dealers/vehicles/vehicles.js +18 -18
- package/resources/dealers/vehicles/vehicles.js.map +1 -1
- package/resources/dealers/vehicles/vehicles.mjs +18 -18
- package/resources/dealers/vehicles/vehicles.mjs.map +1 -1
- package/resources/index.d.mts +1 -1
- package/resources/index.d.mts.map +1 -1
- package/resources/index.d.ts +1 -1
- package/resources/index.d.ts.map +1 -1
- package/resources/index.js.map +1 -1
- package/resources/index.mjs.map +1 -1
- package/resources/keys.d.mts +7 -6
- package/resources/keys.d.mts.map +1 -1
- package/resources/keys.d.ts +7 -6
- package/resources/keys.d.ts.map +1 -1
- package/resources/keys.js +7 -6
- package/resources/keys.js.map +1 -1
- package/resources/keys.mjs +7 -6
- package/resources/keys.mjs.map +1 -1
- package/src/client.ts +37 -10
- package/src/core/pagination.ts +170 -0
- package/src/index.ts +1 -0
- package/src/pagination.ts +2 -0
- package/src/resources/dealers/dealers.ts +9 -97
- package/src/resources/dealers/index.ts +2 -2
- package/src/resources/dealers/nlt/index.ts +1 -1
- package/src/resources/dealers/nlt/nlt.ts +2 -2
- package/src/resources/dealers/nlt/offers.ts +60 -84
- package/src/resources/dealers/nlt-settings.ts +24 -64
- package/src/resources/dealers/vehicles/images.ts +3 -2
- package/src/resources/dealers/vehicles/index.ts +1 -0
- package/src/resources/dealers/vehicles/vehicles.ts +62 -72
- package/src/resources/index.ts +1 -2
- package/src/resources/keys.ts +7 -6
- package/src/version.ts +1 -1
- package/version.d.mts +1 -1
- package/version.d.ts +1 -1
- package/version.js +1 -1
- package/version.mjs +1 -1
|
@@ -11,6 +11,7 @@ import {
|
|
|
11
11
|
VehicleImageList,
|
|
12
12
|
} from './images';
|
|
13
13
|
import { APIPromise } from '../../../core/api-promise';
|
|
14
|
+
import { CursorPage, type CursorPageParams, PagePromise } from '../../../core/pagination';
|
|
14
15
|
import { buildHeaders } from '../../../internal/headers';
|
|
15
16
|
import { RequestOptions } from '../../../internal/request-options';
|
|
16
17
|
import { path } from '../../../internal/utils/path';
|
|
@@ -24,11 +25,10 @@ export class Vehicles extends APIResource {
|
|
|
24
25
|
/**
|
|
25
26
|
* Provision a new used vehicle in a dealer's stock.
|
|
26
27
|
*
|
|
27
|
-
*
|
|
28
|
-
*
|
|
29
|
-
*
|
|
30
|
-
*
|
|
31
|
-
* embedding — at which point the vehicle becomes discoverable on the cross-network
|
|
28
|
+
* The write is atomic: a plate conflict or catalogue-code error leaves no partial
|
|
29
|
+
* stock record behind. On success the asynchronous AI-content worker picks up the
|
|
30
|
+
* new vehicle within 60 seconds and generates the SEO body plus semantic
|
|
31
|
+
* embedding; at that point the vehicle becomes discoverable on the cross-network
|
|
32
32
|
* MCP / Custom GPT / NLWeb surfaces. The response returns immediately (no
|
|
33
33
|
* synchronous wait on the worker).
|
|
34
34
|
*/
|
|
@@ -59,9 +59,9 @@ export class Vehicles extends APIResource {
|
|
|
59
59
|
/**
|
|
60
60
|
* Partial update of a vehicle.
|
|
61
61
|
*
|
|
62
|
-
*
|
|
63
|
-
*
|
|
64
|
-
*
|
|
62
|
+
* Applies the transmitted fields inside a single transaction. Fields not present
|
|
63
|
+
* in the body are not touched; explicit `null` clears only fields that are
|
|
64
|
+
* nullable in the public contract.
|
|
65
65
|
*/
|
|
66
66
|
update(
|
|
67
67
|
vehicleID: string,
|
|
@@ -91,25 +91,25 @@ export class Vehicles extends APIResource {
|
|
|
91
91
|
dealerID: string,
|
|
92
92
|
query: VehicleListParams | null | undefined = {},
|
|
93
93
|
options?: RequestOptions,
|
|
94
|
-
):
|
|
95
|
-
return this._client.
|
|
94
|
+
): PagePromise<VehicleSummariesCursorPage, VehicleSummary> {
|
|
95
|
+
return this._client.getAPIList(path`/v1/dealers/${dealerID}/vehicles`, CursorPage<VehicleSummary>, {
|
|
96
|
+
query,
|
|
97
|
+
...options,
|
|
98
|
+
});
|
|
96
99
|
}
|
|
97
100
|
|
|
98
101
|
/**
|
|
99
102
|
* Withdraw a vehicle from sale without deleting the row.
|
|
100
103
|
*
|
|
101
|
-
*
|
|
102
|
-
*
|
|
103
|
-
* active-uniqueness check excludes rows where `visibile = FALSE` OR
|
|
104
|
-
* `venduto_il IS NOT NULL`).
|
|
104
|
+
* Marks the vehicle as no longer for sale. The plate becomes reusable on the
|
|
105
|
+
* network the moment this returns.
|
|
105
106
|
*
|
|
106
107
|
* Soft-delete is the canonical "remove this vehicle from sale" surface. The
|
|
107
108
|
* AI-citation consumers (MCP `_tool_search_vehicles`, Custom GPT
|
|
108
|
-
* `search_vehicles_network`, NLWeb `/ask`) each filter their own
|
|
109
|
-
*
|
|
110
|
-
*
|
|
111
|
-
*
|
|
112
|
-
* surface within the next index cycle.
|
|
109
|
+
* `search_vehicles_network`, NLWeb `/ask`) each filter their own
|
|
110
|
+
* public-availability state. The result on the partner side is the same: a
|
|
111
|
+
* soft-deleted vehicle disappears from every AI surface within the next index
|
|
112
|
+
* cycle.
|
|
113
113
|
*
|
|
114
114
|
* Returns `409 vehicle_already_deleted` if the row is already soft- deleted — same
|
|
115
115
|
* idempotency pattern as the dealers DELETE endpoint.
|
|
@@ -163,6 +163,8 @@ export class Vehicles extends APIResource {
|
|
|
163
163
|
}
|
|
164
164
|
}
|
|
165
165
|
|
|
166
|
+
export type VehicleSummariesCursorPage = CursorPage<VehicleSummary>;
|
|
167
|
+
|
|
166
168
|
/**
|
|
167
169
|
* AI-generated editorial content for a single vehicle.
|
|
168
170
|
*
|
|
@@ -272,20 +274,16 @@ export interface BulkRowOutcome {
|
|
|
272
274
|
*
|
|
273
275
|
* - **Partner-supplied** — what the partner posted (`plate`, `description`,
|
|
274
276
|
* `sale_price_eur`, etc.).
|
|
275
|
-
* - **Catalogue-derived** — `technical_details` is
|
|
276
|
-
*
|
|
277
|
-
* `
|
|
278
|
-
* `NltOfferDetail` per `feedback_partnermax_field_naming_us_english`.
|
|
277
|
+
* - **Catalogue-derived** — `technical_details` is a flat dictionary of
|
|
278
|
+
* Motornet-backed technical attributes using Italian domain labels such as
|
|
279
|
+
* `cilindrata`, `kw`, `hp`, `lunghezza`, `consumo_medio`, and `emissioni_co2`.
|
|
279
280
|
* - **AI-derived** — `ai_content` carries the editorial output the cross-network
|
|
280
281
|
* consumers display (descriptions, highlights, FAQ, SEO meta). `null` until the
|
|
281
282
|
* worker has processed the vehicle.
|
|
282
283
|
*
|
|
283
|
-
*
|
|
284
|
-
*
|
|
285
|
-
*
|
|
286
|
-
* `previous_owner_count`, `previous_ownership_transfer_date`, `last_service_*`.
|
|
287
|
-
* These exist in the underlying DB tables for the DealerMAX dashboard but are
|
|
288
|
-
* intentionally not exposed via the SDK.
|
|
284
|
+
* Dealer-internal margin and operations data remains outside this SDK surface;
|
|
285
|
+
* partners receive only the inventory, commercial, catalogue, media, and
|
|
286
|
+
* AI-derived fields needed to publish the vehicle.
|
|
289
287
|
*/
|
|
290
288
|
vehicle?: VehicleDetail | null;
|
|
291
289
|
}
|
|
@@ -298,20 +296,16 @@ export interface BulkRowOutcome {
|
|
|
298
296
|
*
|
|
299
297
|
* - **Partner-supplied** — what the partner posted (`plate`, `description`,
|
|
300
298
|
* `sale_price_eur`, etc.).
|
|
301
|
-
* - **Catalogue-derived** — `technical_details` is
|
|
302
|
-
*
|
|
303
|
-
* `
|
|
304
|
-
* `NltOfferDetail` per `feedback_partnermax_field_naming_us_english`.
|
|
299
|
+
* - **Catalogue-derived** — `technical_details` is a flat dictionary of
|
|
300
|
+
* Motornet-backed technical attributes using Italian domain labels such as
|
|
301
|
+
* `cilindrata`, `kw`, `hp`, `lunghezza`, `consumo_medio`, and `emissioni_co2`.
|
|
305
302
|
* - **AI-derived** — `ai_content` carries the editorial output the cross-network
|
|
306
303
|
* consumers display (descriptions, highlights, FAQ, SEO meta). `null` until the
|
|
307
304
|
* worker has processed the vehicle.
|
|
308
305
|
*
|
|
309
|
-
*
|
|
310
|
-
*
|
|
311
|
-
*
|
|
312
|
-
* `previous_owner_count`, `previous_ownership_transfer_date`, `last_service_*`.
|
|
313
|
-
* These exist in the underlying DB tables for the DealerMAX dashboard but are
|
|
314
|
-
* intentionally not exposed via the SDK.
|
|
306
|
+
* Dealer-internal margin and operations data remains outside this SDK surface;
|
|
307
|
+
* partners receive only the inventory, commercial, catalogue, media, and
|
|
308
|
+
* AI-derived fields needed to publish the vehicle.
|
|
315
309
|
*/
|
|
316
310
|
export interface VehicleDetail {
|
|
317
311
|
certified_km: number;
|
|
@@ -376,9 +370,9 @@ export interface VehicleDetail {
|
|
|
376
370
|
registration_month?: number | null;
|
|
377
371
|
|
|
378
372
|
/**
|
|
379
|
-
* Flat
|
|
380
|
-
* `motornet_code`. Keys stay in Italian
|
|
381
|
-
*
|
|
373
|
+
* Flat dictionary of Motornet-backed technical attributes for this
|
|
374
|
+
* `motornet_code`. Keys stay in Italian domain vocabulary; native units are
|
|
375
|
+
* preserved (mm, kg, kW, CV, g/km, etc.).
|
|
382
376
|
*/
|
|
383
377
|
technical_details?: { [key: string]: unknown };
|
|
384
378
|
|
|
@@ -402,8 +396,9 @@ export interface VehicleList {
|
|
|
402
396
|
* Compact vehicle payload for list endpoints.
|
|
403
397
|
*
|
|
404
398
|
* Catalogue fields (`brand`, `model`, `trim`, `fuel_type`) are derived from
|
|
405
|
-
*
|
|
406
|
-
*
|
|
399
|
+
* DealerMAX's licensed Motornet-backed catalogue at read time. Italian raw labels
|
|
400
|
+
* are surfaced verbatim so partner clients see the same vocabulary as
|
|
401
|
+
* consumer-facing DealerMAX surfaces.
|
|
407
402
|
*/
|
|
408
403
|
export interface VehicleSummary {
|
|
409
404
|
certified_km: number;
|
|
@@ -445,16 +440,17 @@ export interface VehicleCreateParams {
|
|
|
445
440
|
|
|
446
441
|
/**
|
|
447
442
|
* Body param: Motornet UNI code identifying the exact vehicle configuration. Must
|
|
448
|
-
* exist in
|
|
449
|
-
* 422 `motornet_code_not_in_catalogue`.
|
|
450
|
-
*
|
|
443
|
+
* exist in the used-vehicle catalogue at submission time; otherwise the call
|
|
444
|
+
* returns 422 `motornet_code_not_in_catalogue`. Partners may send a code from
|
|
445
|
+
* their own Motornet agreement or use the paid control-plane targa/VIN resolver
|
|
446
|
+
* before creating the vehicle.
|
|
451
447
|
*/
|
|
452
448
|
motornet_code: string;
|
|
453
449
|
|
|
454
450
|
/**
|
|
455
451
|
* Body param: Italian licence plate. Uppercased server-side. UNIQUE across the
|
|
456
|
-
* network for active vehicles
|
|
457
|
-
*
|
|
452
|
+
* network for active vehicles; reusable once the previous holder withdraws the
|
|
453
|
+
* vehicle from sale.
|
|
458
454
|
*/
|
|
459
455
|
plate: string;
|
|
460
456
|
|
|
@@ -496,20 +492,18 @@ export interface VehicleCreateParams {
|
|
|
496
492
|
extended_warranty_months?: number | null;
|
|
497
493
|
|
|
498
494
|
/**
|
|
499
|
-
* Body param:
|
|
500
|
-
* is in stock but not offered for sale.
|
|
495
|
+
* Body param: When false the vehicle remains in stock but is not offered for sale.
|
|
501
496
|
*/
|
|
502
497
|
is_for_sale?: boolean;
|
|
503
498
|
|
|
504
499
|
/**
|
|
505
500
|
* Body param: Soft-publish flag. When false the row exists in stock but is
|
|
506
|
-
* excluded from consumer-facing AI surfaces.
|
|
501
|
+
* excluded from consumer-facing AI surfaces.
|
|
507
502
|
*/
|
|
508
503
|
is_visible?: boolean;
|
|
509
504
|
|
|
510
505
|
/**
|
|
511
|
-
* Body param: Free-form short notes
|
|
512
|
-
* `mnet_dettagli.precisazioni`-style.
|
|
506
|
+
* Body param: Free-form short notes for partner-facing vehicle detail views.
|
|
513
507
|
*/
|
|
514
508
|
notes?: string | null;
|
|
515
509
|
|
|
@@ -632,9 +626,7 @@ export interface VehicleUpdateParams {
|
|
|
632
626
|
'Idempotency-Key'?: string;
|
|
633
627
|
}
|
|
634
628
|
|
|
635
|
-
export interface VehicleListParams {
|
|
636
|
-
cursor?: string | null;
|
|
637
|
-
|
|
629
|
+
export interface VehicleListParams extends CursorPageParams {
|
|
638
630
|
/**
|
|
639
631
|
* If true, soft-deleted rows (`venduto_il` populated) are also returned. Default
|
|
640
632
|
* false — listings hide soft-deleted vehicles.
|
|
@@ -650,8 +642,6 @@ export interface VehicleListParams {
|
|
|
650
642
|
* Filter on the visibility flag.
|
|
651
643
|
*/
|
|
652
644
|
is_visible?: boolean | null;
|
|
653
|
-
|
|
654
|
-
limit?: number;
|
|
655
645
|
}
|
|
656
646
|
|
|
657
647
|
export interface VehicleDeleteParams {
|
|
@@ -678,9 +668,8 @@ export namespace VehicleBulkParams {
|
|
|
678
668
|
*
|
|
679
669
|
* The partner sends a small, vehicle-specific payload. All technical specs (brand,
|
|
680
670
|
* model, trim, fuel type, displacement, dimensions, CO2, etc.) are derived
|
|
681
|
-
* server-side from
|
|
682
|
-
* never types them.
|
|
683
|
-
* matches the platform rule `feedback_motornet_authoritative`.
|
|
671
|
+
* server-side from DealerMAX's licensed Motornet-backed catalogue — the partner
|
|
672
|
+
* never types them.
|
|
684
673
|
*
|
|
685
674
|
* Fields immutable after creation: `motornet_code`, `plate`, `vin`. Other fields
|
|
686
675
|
* may be updated via PATCH.
|
|
@@ -692,17 +681,18 @@ export namespace VehicleBulkParams {
|
|
|
692
681
|
certified_km: number;
|
|
693
682
|
|
|
694
683
|
/**
|
|
695
|
-
* Motornet UNI code identifying the exact vehicle configuration. Must exist in
|
|
696
|
-
*
|
|
697
|
-
* `motornet_code_not_in_catalogue`.
|
|
698
|
-
*
|
|
684
|
+
* Motornet UNI code identifying the exact vehicle configuration. Must exist in the
|
|
685
|
+
* used-vehicle catalogue at submission time; otherwise the call returns 422
|
|
686
|
+
* `motornet_code_not_in_catalogue`. Partners may send a code from their own
|
|
687
|
+
* Motornet agreement or use the paid control-plane targa/VIN resolver before
|
|
688
|
+
* creating the vehicle.
|
|
699
689
|
*/
|
|
700
690
|
motornet_code: string;
|
|
701
691
|
|
|
702
692
|
/**
|
|
703
693
|
* Italian licence plate. Uppercased server-side. UNIQUE across the network for
|
|
704
|
-
* active vehicles
|
|
705
|
-
*
|
|
694
|
+
* active vehicles; reusable once the previous holder withdraws the vehicle from
|
|
695
|
+
* sale.
|
|
706
696
|
*/
|
|
707
697
|
plate: string;
|
|
708
698
|
|
|
@@ -731,19 +721,18 @@ export namespace VehicleBulkParams {
|
|
|
731
721
|
extended_warranty_months?: number | null;
|
|
732
722
|
|
|
733
723
|
/**
|
|
734
|
-
*
|
|
735
|
-
* but not offered for sale.
|
|
724
|
+
* When false the vehicle remains in stock but is not offered for sale.
|
|
736
725
|
*/
|
|
737
726
|
is_for_sale?: boolean;
|
|
738
727
|
|
|
739
728
|
/**
|
|
740
729
|
* Soft-publish flag. When false the row exists in stock but is excluded from
|
|
741
|
-
* consumer-facing AI surfaces.
|
|
730
|
+
* consumer-facing AI surfaces.
|
|
742
731
|
*/
|
|
743
732
|
is_visible?: boolean;
|
|
744
733
|
|
|
745
734
|
/**
|
|
746
|
-
* Free-form short notes
|
|
735
|
+
* Free-form short notes for partner-facing vehicle detail views.
|
|
747
736
|
*/
|
|
748
737
|
notes?: string | null;
|
|
749
738
|
|
|
@@ -777,6 +766,7 @@ export declare namespace Vehicles {
|
|
|
777
766
|
type VehicleDetail as VehicleDetail,
|
|
778
767
|
type VehicleList as VehicleList,
|
|
779
768
|
type VehicleSummary as VehicleSummary,
|
|
769
|
+
type VehicleSummariesCursorPage as VehicleSummariesCursorPage,
|
|
780
770
|
type VehicleCreateParams as VehicleCreateParams,
|
|
781
771
|
type VehicleRetrieveParams as VehicleRetrieveParams,
|
|
782
772
|
type VehicleUpdateParams as VehicleUpdateParams,
|
package/src/resources/index.ts
CHANGED
|
@@ -4,9 +4,8 @@ export {
|
|
|
4
4
|
Dealers,
|
|
5
5
|
type DealerDetail,
|
|
6
6
|
type DealerSummary,
|
|
7
|
-
type DealerListResponse,
|
|
8
|
-
type DealerCreateParams,
|
|
9
7
|
type DealerUpdateParams,
|
|
10
8
|
type DealerListParams,
|
|
9
|
+
type DealerSummariesCursorPage,
|
|
11
10
|
} from './dealers/dealers';
|
|
12
11
|
export { Keys, type KeyListResponse, type KeyIssueResponse, type KeyIssueParams } from './keys';
|
package/src/resources/keys.ts
CHANGED
|
@@ -7,7 +7,7 @@ import { RequestOptions } from '../internal/request-options';
|
|
|
7
7
|
import { path } from '../internal/utils/path';
|
|
8
8
|
|
|
9
9
|
/**
|
|
10
|
-
* API key lifecycle management
|
|
10
|
+
* API key lifecycle management. PartnerMAX v1 allows one active API key per partner/environment; partners authenticate every request with `X-Api-Key` (preferred) or `Authorization: Bearer <key>`, and replacement is handled through DealerMAX support.
|
|
11
11
|
*/
|
|
12
12
|
export class Keys extends APIResource {
|
|
13
13
|
/**
|
|
@@ -21,12 +21,13 @@ export class Keys extends APIResource {
|
|
|
21
21
|
}
|
|
22
22
|
|
|
23
23
|
/**
|
|
24
|
-
*
|
|
24
|
+
* Rotate the partner API key during a DealerMAX support flow.
|
|
25
25
|
*
|
|
26
|
-
*
|
|
27
|
-
*
|
|
28
|
-
*
|
|
29
|
-
*
|
|
26
|
+
* Plaintext is returned exactly once. The key authenticating this request is
|
|
27
|
+
* deactivated in the same transaction that inserts the replacement, preserving
|
|
28
|
+
* PartnerMAX v1's one-active-key invariant. Callers must not use this endpoint for
|
|
29
|
+
* per-deployment, CI, or engineer credentials. Capability gate: caller's key must
|
|
30
|
+
* hold `can_issue_keys`.
|
|
30
31
|
*/
|
|
31
32
|
issue(params: KeyIssueParams, options?: RequestOptions): APIPromise<KeyIssueResponse> {
|
|
32
33
|
const { 'Idempotency-Key': idempotencyKey, ...body } = params;
|
package/src/version.ts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export const VERSION = '0.
|
|
1
|
+
export const VERSION = '0.4.0'; // x-release-please-version
|
package/version.d.mts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export declare const VERSION = "0.
|
|
1
|
+
export declare const VERSION = "0.4.0";
|
|
2
2
|
//# sourceMappingURL=version.d.mts.map
|
package/version.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export declare const VERSION = "0.
|
|
1
|
+
export declare const VERSION = "0.4.0";
|
|
2
2
|
//# sourceMappingURL=version.d.ts.map
|
package/version.js
CHANGED
package/version.mjs
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export const VERSION = '0.
|
|
1
|
+
export const VERSION = '0.4.0'; // x-release-please-version
|
|
2
2
|
//# sourceMappingURL=version.mjs.map
|