@minipim/sdk 0.5.0 → 0.6.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/dist/openapi.d.ts CHANGED
@@ -166,6 +166,7 @@ interface paths {
166
166
  default_locale?: string;
167
167
  default_channel?: string;
168
168
  default_currency?: string;
169
+ content_pages_enabled?: boolean;
169
170
  };
170
171
  initialAdmin?: {
171
172
  /** Format: email */
@@ -258,7 +259,10 @@ interface paths {
258
259
  path?: never;
259
260
  cookie?: never;
260
261
  };
261
- /** Get the current tenant organization */
262
+ /**
263
+ * Get the current tenant organization
264
+ * @description Includes `features`, the resolved state of optional features for this org. `entitled` is the plan-level answer; `enabled` is the org’s own preference. A feature is usable only when both are true.
265
+ */
262
266
  get: {
263
267
  parameters: {
264
268
  query?: never;
@@ -286,6 +290,12 @@ interface paths {
286
290
  createdAt: string;
287
291
  /** Format: date-time */
288
292
  updatedAt: string;
293
+ features: {
294
+ content_pages: {
295
+ entitled: boolean;
296
+ enabled: boolean;
297
+ };
298
+ };
289
299
  };
290
300
  };
291
301
  };
@@ -328,6 +338,7 @@ interface paths {
328
338
  default_locale?: string;
329
339
  default_channel?: string;
330
340
  default_currency?: string;
341
+ content_pages_enabled?: boolean;
331
342
  };
332
343
  };
333
344
  };
@@ -602,10 +613,15 @@ interface paths {
602
613
  path?: never;
603
614
  cookie?: never;
604
615
  };
605
- /** List attributes */
616
+ /**
617
+ * List attributes
618
+ * @description Defaults to product attributes. Pass `entityKind=content` for content-page fields.
619
+ */
606
620
  get: {
607
621
  parameters: {
608
- query?: never;
622
+ query?: {
623
+ entityKind?: "product" | "content";
624
+ };
609
625
  header?: never;
610
626
  path?: never;
611
627
  cookie?: never;
@@ -628,6 +644,8 @@ interface paths {
628
644
  /** Format: date-time */
629
645
  updatedAt: string;
630
646
  code: string;
647
+ /** @enum {string} */
648
+ entityKind: "product" | "content";
631
649
  label: (string | number | boolean | ("null" | null)) | unknown[] | {
632
650
  [key: string]: unknown;
633
651
  };
@@ -669,6 +687,11 @@ interface paths {
669
687
  content: {
670
688
  "application/json": {
671
689
  code: string;
690
+ /**
691
+ * @default product
692
+ * @enum {string}
693
+ */
694
+ entityKind?: "product" | "content";
672
695
  label: {
673
696
  [key: string]: string;
674
697
  };
@@ -710,6 +733,8 @@ interface paths {
710
733
  /** Format: date-time */
711
734
  updatedAt: string;
712
735
  code: string;
736
+ /** @enum {string} */
737
+ entityKind: "product" | "content";
713
738
  label: (string | number | boolean | ("null" | null)) | unknown[] | {
714
739
  [key: string]: unknown;
715
740
  };
@@ -791,6 +816,8 @@ interface paths {
791
816
  /** Format: date-time */
792
817
  updatedAt: string;
793
818
  code: string;
819
+ /** @enum {string} */
820
+ entityKind: "product" | "content";
794
821
  label: (string | number | boolean | ("null" | null)) | unknown[] | {
795
822
  [key: string]: unknown;
796
823
  };
@@ -887,6 +914,11 @@ interface paths {
887
914
  content: {
888
915
  "application/json": {
889
916
  code?: string;
917
+ /**
918
+ * @default product
919
+ * @enum {string}
920
+ */
921
+ entityKind?: "product" | "content";
890
922
  label?: {
891
923
  [key: string]: string;
892
924
  };
@@ -928,6 +960,8 @@ interface paths {
928
960
  /** Format: date-time */
929
961
  updatedAt: string;
930
962
  code: string;
963
+ /** @enum {string} */
964
+ entityKind: "product" | "content";
931
965
  label: (string | number | boolean | ("null" | null)) | unknown[] | {
932
966
  [key: string]: unknown;
933
967
  };
@@ -992,10 +1026,15 @@ interface paths {
992
1026
  path?: never;
993
1027
  cookie?: never;
994
1028
  };
995
- /** List attribute families */
1029
+ /**
1030
+ * List attribute families
1031
+ * @description Defaults to product families. Pass `entityKind=content` for content-page types.
1032
+ */
996
1033
  get: {
997
1034
  parameters: {
998
- query?: never;
1035
+ query?: {
1036
+ entityKind?: "product" | "content";
1037
+ };
999
1038
  header?: never;
1000
1039
  path?: never;
1001
1040
  cookie?: never;
@@ -1018,6 +1057,8 @@ interface paths {
1018
1057
  /** Format: date-time */
1019
1058
  updatedAt: string;
1020
1059
  code: string;
1060
+ /** @enum {string} */
1061
+ entityKind: "product" | "content";
1021
1062
  label: (string | number | boolean | ("null" | null)) | unknown[] | {
1022
1063
  [key: string]: unknown;
1023
1064
  };
@@ -1040,6 +1081,11 @@ interface paths {
1040
1081
  content: {
1041
1082
  "application/json": {
1042
1083
  code: string;
1084
+ /**
1085
+ * @default product
1086
+ * @enum {string}
1087
+ */
1088
+ entityKind?: "product" | "content";
1043
1089
  label: {
1044
1090
  [key: string]: string;
1045
1091
  };
@@ -1064,6 +1110,8 @@ interface paths {
1064
1110
  /** Format: date-time */
1065
1111
  updatedAt: string;
1066
1112
  code: string;
1113
+ /** @enum {string} */
1114
+ entityKind: "product" | "content";
1067
1115
  label: (string | number | boolean | ("null" | null)) | unknown[] | {
1068
1116
  [key: string]: unknown;
1069
1117
  };
@@ -1129,6 +1177,8 @@ interface paths {
1129
1177
  /** Format: date-time */
1130
1178
  updatedAt: string;
1131
1179
  code: string;
1180
+ /** @enum {string} */
1181
+ entityKind: "product" | "content";
1132
1182
  label: (string | number | boolean | ("null" | null)) | unknown[] | {
1133
1183
  [key: string]: unknown;
1134
1184
  };
@@ -1258,6 +1308,8 @@ interface paths {
1258
1308
  /** Format: date-time */
1259
1309
  updatedAt: string;
1260
1310
  code: string;
1311
+ /** @enum {string} */
1312
+ entityKind: "product" | "content";
1261
1313
  label: (string | number | boolean | ("null" | null)) | unknown[] | {
1262
1314
  [key: string]: unknown;
1263
1315
  };
@@ -3452,7 +3504,7 @@ interface paths {
3452
3504
  patch?: never;
3453
3505
  trace?: never;
3454
3506
  };
3455
- "/v1/channels": {
3507
+ "/v1/content": {
3456
3508
  parameters: {
3457
3509
  query?: never;
3458
3510
  header?: never;
@@ -3460,48 +3512,22 @@ interface paths {
3460
3512
  cookie?: never;
3461
3513
  };
3462
3514
  /**
3463
- * List channels
3464
- * @description Channels are the surfaces your catalog publishes to
3465
- * storefronts, marketplaces, ad platforms. Used in attribute-value resolution
3466
- * together with locale: `(locale, channel)` keys each value. `settings` is
3467
- * free-form per-channel config; `settings.required_attributes` drives the
3468
- * per-channel completeness score on products.
3469
- *
3470
- * **Example response**
3471
- * ```json
3472
- * [
3473
- * {
3474
- * "id": "3ac5ab02-93fd-49b7-91a3-681fc36eabdd",
3475
- * "code": "headless-main",
3476
- * "name": "Headless Storefront",
3477
- * "locales": ["en_US"],
3478
- * "settings": null,
3479
- * "createdAt": "2026-06-02T22:28:01.926Z",
3480
- * "updatedAt": "2026-06-02T22:28:01.926Z"
3481
- * },
3482
- * {
3483
- * "id": "f1c2b3a4-...",
3484
- * "code": "bc_pdo6b28kp8_default",
3485
- * "name": "BigCommerce (default)",
3486
- * "locales": ["en_US"],
3487
- * "settings": {
3488
- * "bc_channel_id": 1,
3489
- * "bc_store_hash": "pdo6b28kp8",
3490
- * "required_attributes": ["description", "price", "brand", "weight"]
3491
- * },
3492
- * "createdAt": "...",
3493
- * "updatedAt": "..."
3494
- * }
3495
- * ]
3496
- * ```
3497
- *
3498
- * Channels seeded by connectors carry `bc_*` / `shopify_*` keys in
3499
- * `settings` so they can be identified and scoped-wiped on connector
3500
- * uninstall — leave those alone unless you know what you're doing.
3515
+ * List content pages
3516
+ * @description Filters and pagination mirror `GET /v1/products`. `tag` is repeatable and matches pages carrying ALL listed tags.
3501
3517
  */
3502
3518
  get: {
3503
3519
  parameters: {
3504
- query?: never;
3520
+ query?: {
3521
+ status?: "draft" | "active" | "archived";
3522
+ q?: string;
3523
+ familyId?: string;
3524
+ categoryId?: string;
3525
+ channelId?: string;
3526
+ tag?: string | string[];
3527
+ updatedSince?: string;
3528
+ limit?: number;
3529
+ offset?: number;
3530
+ };
3505
3531
  header?: never;
3506
3532
  path?: never;
3507
3533
  cookie?: never;
@@ -3515,27 +3541,63 @@ interface paths {
3515
3541
  };
3516
3542
  content: {
3517
3543
  "application/json": {
3518
- /** Format: uuid */
3519
- id: string;
3520
- /** Format: uuid */
3521
- organizationId: string;
3522
- /** Format: date-time */
3523
- createdAt: string;
3524
- /** Format: date-time */
3525
- updatedAt: string;
3526
- code: string;
3527
- name: string;
3528
- locales: string[];
3529
- settings: ((string | number | boolean | ("null" | null)) | unknown[] | {
3530
- [key: string]: unknown;
3531
- }) | null;
3532
- }[];
3544
+ data: {
3545
+ /** Format: uuid */
3546
+ id: string;
3547
+ /** Format: uuid */
3548
+ organizationId: string;
3549
+ /** Format: date-time */
3550
+ createdAt: string;
3551
+ /** Format: date-time */
3552
+ updatedAt: string;
3553
+ /** Format: uuid */
3554
+ familyId: string;
3555
+ title: string;
3556
+ slug: string;
3557
+ /** @enum {string} */
3558
+ status: "draft" | "active" | "archived";
3559
+ /** Format: date-time */
3560
+ publishedAt: string | null;
3561
+ /** Format: uuid */
3562
+ channelId: string | null;
3563
+ attributes: (string | number | boolean | ("null" | null)) | unknown[] | {
3564
+ [key: string]: unknown;
3565
+ };
3566
+ tags: string[];
3567
+ /** Format: uuid */
3568
+ createdBy: string | null;
3569
+ /** Format: uuid */
3570
+ updatedBy: string | null;
3571
+ }[];
3572
+ limit: number;
3573
+ offset: number;
3574
+ hasMore?: boolean;
3575
+ total?: number;
3576
+ };
3577
+ };
3578
+ };
3579
+ /** @description Default Response */
3580
+ 403: {
3581
+ headers: {
3582
+ [name: string]: unknown;
3583
+ };
3584
+ content: {
3585
+ "application/json": {
3586
+ error: {
3587
+ code: string;
3588
+ message: string;
3589
+ details?: unknown;
3590
+ };
3591
+ };
3533
3592
  };
3534
3593
  };
3535
3594
  };
3536
3595
  };
3537
3596
  put?: never;
3538
- /** Create a channel */
3597
+ /**
3598
+ * Create a content page
3599
+ * @description Validates `attributes` against the family at write time, exactly as products do — an undeclared attribute code is a 422. Required attributes are enforced only for `active` pages, so a draft may be saved incomplete. Emits `content_page.created`.
3600
+ */
3539
3601
  post: {
3540
3602
  parameters: {
3541
3603
  query?: never;
@@ -3546,13 +3608,29 @@ interface paths {
3546
3608
  requestBody: {
3547
3609
  content: {
3548
3610
  "application/json": {
3549
- code: string;
3550
- name: string;
3551
- /** @default [] */
3552
- locales?: string[];
3553
- settings?: {
3554
- [key: string]: unknown;
3611
+ /** Format: uuid */
3612
+ familyId: string;
3613
+ title: string;
3614
+ slug?: string;
3615
+ /**
3616
+ * @default draft
3617
+ * @enum {string}
3618
+ */
3619
+ status?: "draft" | "active" | "archived";
3620
+ /** Format: date-time */
3621
+ publishedAt?: string;
3622
+ /** Format: uuid */
3623
+ channelId?: string | null;
3624
+ /** @default {} */
3625
+ attributes?: {
3626
+ [key: string]: {
3627
+ locale: string | null;
3628
+ channel: string | null;
3629
+ value?: unknown;
3630
+ }[];
3555
3631
  };
3632
+ /** @default [] */
3633
+ tags?: string[];
3556
3634
  };
3557
3635
  };
3558
3636
  };
@@ -3572,12 +3650,69 @@ interface paths {
3572
3650
  createdAt: string;
3573
3651
  /** Format: date-time */
3574
3652
  updatedAt: string;
3575
- code: string;
3576
- name: string;
3577
- locales: string[];
3578
- settings: ((string | number | boolean | ("null" | null)) | unknown[] | {
3653
+ /** Format: uuid */
3654
+ familyId: string;
3655
+ title: string;
3656
+ slug: string;
3657
+ /** @enum {string} */
3658
+ status: "draft" | "active" | "archived";
3659
+ /** Format: date-time */
3660
+ publishedAt: string | null;
3661
+ /** Format: uuid */
3662
+ channelId: string | null;
3663
+ attributes: (string | number | boolean | ("null" | null)) | unknown[] | {
3579
3664
  [key: string]: unknown;
3580
- }) | null;
3665
+ };
3666
+ tags: string[];
3667
+ /** Format: uuid */
3668
+ createdBy: string | null;
3669
+ /** Format: uuid */
3670
+ updatedBy: string | null;
3671
+ };
3672
+ };
3673
+ };
3674
+ /** @description Default Response */
3675
+ 403: {
3676
+ headers: {
3677
+ [name: string]: unknown;
3678
+ };
3679
+ content: {
3680
+ "application/json": {
3681
+ error: {
3682
+ code: string;
3683
+ message: string;
3684
+ details?: unknown;
3685
+ };
3686
+ };
3687
+ };
3688
+ };
3689
+ /** @description Default Response */
3690
+ 404: {
3691
+ headers: {
3692
+ [name: string]: unknown;
3693
+ };
3694
+ content: {
3695
+ "application/json": {
3696
+ error: {
3697
+ code: string;
3698
+ message: string;
3699
+ details?: unknown;
3700
+ };
3701
+ };
3702
+ };
3703
+ };
3704
+ /** @description Default Response */
3705
+ 409: {
3706
+ headers: {
3707
+ [name: string]: unknown;
3708
+ };
3709
+ content: {
3710
+ "application/json": {
3711
+ error: {
3712
+ code: string;
3713
+ message: string;
3714
+ details?: unknown;
3715
+ };
3581
3716
  };
3582
3717
  };
3583
3718
  };
@@ -3604,21 +3739,15 @@ interface paths {
3604
3739
  patch?: never;
3605
3740
  trace?: never;
3606
3741
  };
3607
- "/v1/channels/{id}": {
3742
+ "/v1/content/{id}": {
3608
3743
  parameters: {
3609
3744
  query?: never;
3610
3745
  header?: never;
3611
3746
  path?: never;
3612
3747
  cookie?: never;
3613
3748
  };
3614
- get?: never;
3615
- put?: never;
3616
- post?: never;
3617
- /**
3618
- * Delete a channel (surface)
3619
- * @description Removes a channel and its per-product publish records (ON DELETE CASCADE). The channel stops appearing as a completeness/readiness surface. Channel-scoped attribute values are stored in the product JSONB (not FKs) and are left untouched — they simply no longer resolve to a live channel. Use this to clear a surface left behind after uninstalling the connector that seeded it (channels are decoupled from connectors by design).
3620
- */
3621
- delete: {
3749
+ /** Get a content page */
3750
+ get: {
3622
3751
  parameters: {
3623
3752
  query?: never;
3624
3753
  header?: never;
@@ -3630,18 +3759,545 @@ interface paths {
3630
3759
  requestBody?: never;
3631
3760
  responses: {
3632
3761
  /** @description Default Response */
3633
- 204: {
3762
+ 200: {
3634
3763
  headers: {
3635
3764
  [name: string]: unknown;
3636
3765
  };
3637
3766
  content: {
3638
- "application/json": "null" | null;
3639
- };
3640
- };
3641
- /** @description Default Response */
3642
- 404: {
3643
- headers: {
3644
- [name: string]: unknown;
3767
+ "application/json": {
3768
+ /** Format: uuid */
3769
+ id: string;
3770
+ /** Format: uuid */
3771
+ organizationId: string;
3772
+ /** Format: date-time */
3773
+ createdAt: string;
3774
+ /** Format: date-time */
3775
+ updatedAt: string;
3776
+ /** Format: uuid */
3777
+ familyId: string;
3778
+ title: string;
3779
+ slug: string;
3780
+ /** @enum {string} */
3781
+ status: "draft" | "active" | "archived";
3782
+ /** Format: date-time */
3783
+ publishedAt: string | null;
3784
+ /** Format: uuid */
3785
+ channelId: string | null;
3786
+ attributes: (string | number | boolean | ("null" | null)) | unknown[] | {
3787
+ [key: string]: unknown;
3788
+ };
3789
+ tags: string[];
3790
+ /** Format: uuid */
3791
+ createdBy: string | null;
3792
+ /** Format: uuid */
3793
+ updatedBy: string | null;
3794
+ categoryIds: string[];
3795
+ };
3796
+ };
3797
+ };
3798
+ /** @description Default Response */
3799
+ 403: {
3800
+ headers: {
3801
+ [name: string]: unknown;
3802
+ };
3803
+ content: {
3804
+ "application/json": {
3805
+ error: {
3806
+ code: string;
3807
+ message: string;
3808
+ details?: unknown;
3809
+ };
3810
+ };
3811
+ };
3812
+ };
3813
+ /** @description Default Response */
3814
+ 404: {
3815
+ headers: {
3816
+ [name: string]: unknown;
3817
+ };
3818
+ content: {
3819
+ "application/json": {
3820
+ error: {
3821
+ code: string;
3822
+ message: string;
3823
+ details?: unknown;
3824
+ };
3825
+ };
3826
+ };
3827
+ };
3828
+ };
3829
+ };
3830
+ put?: never;
3831
+ post?: never;
3832
+ /**
3833
+ * Delete a content page
3834
+ * @description Emits `content_page.deleted`.
3835
+ */
3836
+ delete: {
3837
+ parameters: {
3838
+ query?: never;
3839
+ header?: never;
3840
+ path: {
3841
+ id: string;
3842
+ };
3843
+ cookie?: never;
3844
+ };
3845
+ requestBody?: never;
3846
+ responses: {
3847
+ /** @description Default Response */
3848
+ 204: {
3849
+ headers: {
3850
+ [name: string]: unknown;
3851
+ };
3852
+ content: {
3853
+ "application/json": "null" | null;
3854
+ };
3855
+ };
3856
+ /** @description Default Response */
3857
+ 403: {
3858
+ headers: {
3859
+ [name: string]: unknown;
3860
+ };
3861
+ content: {
3862
+ "application/json": {
3863
+ error: {
3864
+ code: string;
3865
+ message: string;
3866
+ details?: unknown;
3867
+ };
3868
+ };
3869
+ };
3870
+ };
3871
+ /** @description Default Response */
3872
+ 404: {
3873
+ headers: {
3874
+ [name: string]: unknown;
3875
+ };
3876
+ content: {
3877
+ "application/json": {
3878
+ error: {
3879
+ code: string;
3880
+ message: string;
3881
+ details?: unknown;
3882
+ };
3883
+ };
3884
+ };
3885
+ };
3886
+ };
3887
+ };
3888
+ options?: never;
3889
+ head?: never;
3890
+ /**
3891
+ * Update a content page
3892
+ * @description `attributes` is merged per code, not replaced wholesale. Stamps `publishedAt` on the first transition to `active` unless the caller supplies one. Emits `content_page.updated` carrying `previous_status`.
3893
+ */
3894
+ patch: {
3895
+ parameters: {
3896
+ query?: never;
3897
+ header?: never;
3898
+ path: {
3899
+ id: string;
3900
+ };
3901
+ cookie?: never;
3902
+ };
3903
+ requestBody: {
3904
+ content: {
3905
+ "application/json": {
3906
+ title?: string;
3907
+ slug?: string;
3908
+ /** @enum {string} */
3909
+ status?: "draft" | "active" | "archived";
3910
+ /** Format: date-time */
3911
+ publishedAt?: string | null;
3912
+ /** Format: uuid */
3913
+ channelId?: string | null;
3914
+ attributes?: {
3915
+ [key: string]: {
3916
+ locale: string | null;
3917
+ channel: string | null;
3918
+ value?: unknown;
3919
+ }[];
3920
+ };
3921
+ tags?: string[];
3922
+ };
3923
+ };
3924
+ };
3925
+ responses: {
3926
+ /** @description Default Response */
3927
+ 200: {
3928
+ headers: {
3929
+ [name: string]: unknown;
3930
+ };
3931
+ content: {
3932
+ "application/json": {
3933
+ /** Format: uuid */
3934
+ id: string;
3935
+ /** Format: uuid */
3936
+ organizationId: string;
3937
+ /** Format: date-time */
3938
+ createdAt: string;
3939
+ /** Format: date-time */
3940
+ updatedAt: string;
3941
+ /** Format: uuid */
3942
+ familyId: string;
3943
+ title: string;
3944
+ slug: string;
3945
+ /** @enum {string} */
3946
+ status: "draft" | "active" | "archived";
3947
+ /** Format: date-time */
3948
+ publishedAt: string | null;
3949
+ /** Format: uuid */
3950
+ channelId: string | null;
3951
+ attributes: (string | number | boolean | ("null" | null)) | unknown[] | {
3952
+ [key: string]: unknown;
3953
+ };
3954
+ tags: string[];
3955
+ /** Format: uuid */
3956
+ createdBy: string | null;
3957
+ /** Format: uuid */
3958
+ updatedBy: string | null;
3959
+ };
3960
+ };
3961
+ };
3962
+ /** @description Default Response */
3963
+ 403: {
3964
+ headers: {
3965
+ [name: string]: unknown;
3966
+ };
3967
+ content: {
3968
+ "application/json": {
3969
+ error: {
3970
+ code: string;
3971
+ message: string;
3972
+ details?: unknown;
3973
+ };
3974
+ };
3975
+ };
3976
+ };
3977
+ /** @description Default Response */
3978
+ 404: {
3979
+ headers: {
3980
+ [name: string]: unknown;
3981
+ };
3982
+ content: {
3983
+ "application/json": {
3984
+ error: {
3985
+ code: string;
3986
+ message: string;
3987
+ details?: unknown;
3988
+ };
3989
+ };
3990
+ };
3991
+ };
3992
+ /** @description Default Response */
3993
+ 409: {
3994
+ headers: {
3995
+ [name: string]: unknown;
3996
+ };
3997
+ content: {
3998
+ "application/json": {
3999
+ error: {
4000
+ code: string;
4001
+ message: string;
4002
+ details?: unknown;
4003
+ };
4004
+ };
4005
+ };
4006
+ };
4007
+ /** @description Default Response */
4008
+ 422: {
4009
+ headers: {
4010
+ [name: string]: unknown;
4011
+ };
4012
+ content: {
4013
+ "application/json": {
4014
+ error: {
4015
+ code: string;
4016
+ message: string;
4017
+ details?: unknown;
4018
+ };
4019
+ };
4020
+ };
4021
+ };
4022
+ };
4023
+ };
4024
+ trace?: never;
4025
+ };
4026
+ "/v1/content/{id}/categories": {
4027
+ parameters: {
4028
+ query?: never;
4029
+ header?: never;
4030
+ path?: never;
4031
+ cookie?: never;
4032
+ };
4033
+ get?: never;
4034
+ /**
4035
+ * Replace a content page’s categories
4036
+ * @description Replaces the full set — pass an empty array to clear. Uses the same `categories` table products do, so a category means one thing across the whole org.
4037
+ */
4038
+ put: {
4039
+ parameters: {
4040
+ query?: never;
4041
+ header?: never;
4042
+ path: {
4043
+ id: string;
4044
+ };
4045
+ cookie?: never;
4046
+ };
4047
+ requestBody: {
4048
+ content: {
4049
+ "application/json": {
4050
+ categoryIds: string[];
4051
+ };
4052
+ };
4053
+ };
4054
+ responses: {
4055
+ /** @description Default Response */
4056
+ 200: {
4057
+ headers: {
4058
+ [name: string]: unknown;
4059
+ };
4060
+ content: {
4061
+ "application/json": {
4062
+ data: {
4063
+ /** Format: uuid */
4064
+ contentPageId: string;
4065
+ /** Format: uuid */
4066
+ categoryId: string;
4067
+ position: number;
4068
+ }[];
4069
+ };
4070
+ };
4071
+ };
4072
+ /** @description Default Response */
4073
+ 403: {
4074
+ headers: {
4075
+ [name: string]: unknown;
4076
+ };
4077
+ content: {
4078
+ "application/json": {
4079
+ error: {
4080
+ code: string;
4081
+ message: string;
4082
+ details?: unknown;
4083
+ };
4084
+ };
4085
+ };
4086
+ };
4087
+ /** @description Default Response */
4088
+ 404: {
4089
+ headers: {
4090
+ [name: string]: unknown;
4091
+ };
4092
+ content: {
4093
+ "application/json": {
4094
+ error: {
4095
+ code: string;
4096
+ message: string;
4097
+ details?: unknown;
4098
+ };
4099
+ };
4100
+ };
4101
+ };
4102
+ };
4103
+ };
4104
+ post?: never;
4105
+ delete?: never;
4106
+ options?: never;
4107
+ head?: never;
4108
+ patch?: never;
4109
+ trace?: never;
4110
+ };
4111
+ "/v1/channels": {
4112
+ parameters: {
4113
+ query?: never;
4114
+ header?: never;
4115
+ path?: never;
4116
+ cookie?: never;
4117
+ };
4118
+ /**
4119
+ * List channels
4120
+ * @description Channels are the surfaces your catalog publishes to —
4121
+ * storefronts, marketplaces, ad platforms. Used in attribute-value resolution
4122
+ * together with locale: `(locale, channel)` keys each value. `settings` is
4123
+ * free-form per-channel config; `settings.required_attributes` drives the
4124
+ * per-channel completeness score on products.
4125
+ *
4126
+ * **Example response**
4127
+ * ```json
4128
+ * [
4129
+ * {
4130
+ * "id": "3ac5ab02-93fd-49b7-91a3-681fc36eabdd",
4131
+ * "code": "headless-main",
4132
+ * "name": "Headless Storefront",
4133
+ * "locales": ["en_US"],
4134
+ * "settings": null,
4135
+ * "createdAt": "2026-06-02T22:28:01.926Z",
4136
+ * "updatedAt": "2026-06-02T22:28:01.926Z"
4137
+ * },
4138
+ * {
4139
+ * "id": "f1c2b3a4-...",
4140
+ * "code": "bc_pdo6b28kp8_default",
4141
+ * "name": "BigCommerce (default)",
4142
+ * "locales": ["en_US"],
4143
+ * "settings": {
4144
+ * "bc_channel_id": 1,
4145
+ * "bc_store_hash": "pdo6b28kp8",
4146
+ * "required_attributes": ["description", "price", "brand", "weight"]
4147
+ * },
4148
+ * "createdAt": "...",
4149
+ * "updatedAt": "..."
4150
+ * }
4151
+ * ]
4152
+ * ```
4153
+ *
4154
+ * Channels seeded by connectors carry `bc_*` / `shopify_*` keys in
4155
+ * `settings` so they can be identified and scoped-wiped on connector
4156
+ * uninstall — leave those alone unless you know what you're doing.
4157
+ */
4158
+ get: {
4159
+ parameters: {
4160
+ query?: never;
4161
+ header?: never;
4162
+ path?: never;
4163
+ cookie?: never;
4164
+ };
4165
+ requestBody?: never;
4166
+ responses: {
4167
+ /** @description Default Response */
4168
+ 200: {
4169
+ headers: {
4170
+ [name: string]: unknown;
4171
+ };
4172
+ content: {
4173
+ "application/json": {
4174
+ /** Format: uuid */
4175
+ id: string;
4176
+ /** Format: uuid */
4177
+ organizationId: string;
4178
+ /** Format: date-time */
4179
+ createdAt: string;
4180
+ /** Format: date-time */
4181
+ updatedAt: string;
4182
+ code: string;
4183
+ name: string;
4184
+ locales: string[];
4185
+ settings: ((string | number | boolean | ("null" | null)) | unknown[] | {
4186
+ [key: string]: unknown;
4187
+ }) | null;
4188
+ }[];
4189
+ };
4190
+ };
4191
+ };
4192
+ };
4193
+ put?: never;
4194
+ /** Create a channel */
4195
+ post: {
4196
+ parameters: {
4197
+ query?: never;
4198
+ header?: never;
4199
+ path?: never;
4200
+ cookie?: never;
4201
+ };
4202
+ requestBody: {
4203
+ content: {
4204
+ "application/json": {
4205
+ code: string;
4206
+ name: string;
4207
+ /** @default [] */
4208
+ locales?: string[];
4209
+ settings?: {
4210
+ [key: string]: unknown;
4211
+ };
4212
+ };
4213
+ };
4214
+ };
4215
+ responses: {
4216
+ /** @description Default Response */
4217
+ 201: {
4218
+ headers: {
4219
+ [name: string]: unknown;
4220
+ };
4221
+ content: {
4222
+ "application/json": {
4223
+ /** Format: uuid */
4224
+ id: string;
4225
+ /** Format: uuid */
4226
+ organizationId: string;
4227
+ /** Format: date-time */
4228
+ createdAt: string;
4229
+ /** Format: date-time */
4230
+ updatedAt: string;
4231
+ code: string;
4232
+ name: string;
4233
+ locales: string[];
4234
+ settings: ((string | number | boolean | ("null" | null)) | unknown[] | {
4235
+ [key: string]: unknown;
4236
+ }) | null;
4237
+ };
4238
+ };
4239
+ };
4240
+ /** @description Default Response */
4241
+ 422: {
4242
+ headers: {
4243
+ [name: string]: unknown;
4244
+ };
4245
+ content: {
4246
+ "application/json": {
4247
+ error: {
4248
+ code: string;
4249
+ message: string;
4250
+ details?: unknown;
4251
+ };
4252
+ };
4253
+ };
4254
+ };
4255
+ };
4256
+ };
4257
+ delete?: never;
4258
+ options?: never;
4259
+ head?: never;
4260
+ patch?: never;
4261
+ trace?: never;
4262
+ };
4263
+ "/v1/channels/{id}": {
4264
+ parameters: {
4265
+ query?: never;
4266
+ header?: never;
4267
+ path?: never;
4268
+ cookie?: never;
4269
+ };
4270
+ get?: never;
4271
+ put?: never;
4272
+ post?: never;
4273
+ /**
4274
+ * Delete a channel (surface)
4275
+ * @description Removes a channel and its per-product publish records (ON DELETE CASCADE). The channel stops appearing as a completeness/readiness surface. Channel-scoped attribute values are stored in the product JSONB (not FKs) and are left untouched — they simply no longer resolve to a live channel. Use this to clear a surface left behind after uninstalling the connector that seeded it (channels are decoupled from connectors by design).
4276
+ */
4277
+ delete: {
4278
+ parameters: {
4279
+ query?: never;
4280
+ header?: never;
4281
+ path: {
4282
+ id: string;
4283
+ };
4284
+ cookie?: never;
4285
+ };
4286
+ requestBody?: never;
4287
+ responses: {
4288
+ /** @description Default Response */
4289
+ 204: {
4290
+ headers: {
4291
+ [name: string]: unknown;
4292
+ };
4293
+ content: {
4294
+ "application/json": "null" | null;
4295
+ };
4296
+ };
4297
+ /** @description Default Response */
4298
+ 404: {
4299
+ headers: {
4300
+ [name: string]: unknown;
3645
4301
  };
3646
4302
  content: {
3647
4303
  "application/json": {
@@ -4992,7 +5648,110 @@ interface paths {
4992
5648
  /** Format: uuid */
4993
5649
  mediaId: string;
4994
5650
  /** @enum {string} */
4995
- entityType: "product" | "variant";
5651
+ entityType: "product" | "variant" | "content_page";
5652
+ /** Format: uuid */
5653
+ entityId: string;
5654
+ /** @enum {string} */
5655
+ role: "hero" | "gallery" | "thumbnail" | "technical" | "lifestyle" | "swatch";
5656
+ position: number;
5657
+ altText: ((string | number | boolean | ("null" | null)) | unknown[] | {
5658
+ [key: string]: unknown;
5659
+ }) | null;
5660
+ /** Format: uuid */
5661
+ channelId: string | null;
5662
+ };
5663
+ url: string | null;
5664
+ }[];
5665
+ };
5666
+ };
5667
+ };
5668
+ /** @description Default Response */
5669
+ 404: {
5670
+ headers: {
5671
+ [name: string]: unknown;
5672
+ };
5673
+ content: {
5674
+ "application/json": {
5675
+ error: {
5676
+ code: string;
5677
+ message: string;
5678
+ details?: unknown;
5679
+ };
5680
+ };
5681
+ };
5682
+ };
5683
+ };
5684
+ };
5685
+ put?: never;
5686
+ post?: never;
5687
+ delete?: never;
5688
+ options?: never;
5689
+ head?: never;
5690
+ patch?: never;
5691
+ trace?: never;
5692
+ };
5693
+ "/v1/content/{id}/media": {
5694
+ parameters: {
5695
+ query?: never;
5696
+ header?: never;
5697
+ path?: never;
5698
+ cookie?: never;
5699
+ };
5700
+ /**
5701
+ * List media attached to a content page
5702
+ * @description Same shape as the product/variant galleries. Lives here rather than under /v1/content so it sits with its siblings and reuses the same URL resolution; associations are tenant-scoped by RLS regardless.
5703
+ */
5704
+ get: {
5705
+ parameters: {
5706
+ query?: never;
5707
+ header?: never;
5708
+ path: {
5709
+ id: string;
5710
+ };
5711
+ cookie?: never;
5712
+ };
5713
+ requestBody?: never;
5714
+ responses: {
5715
+ /** @description Default Response */
5716
+ 200: {
5717
+ headers: {
5718
+ [name: string]: unknown;
5719
+ };
5720
+ content: {
5721
+ "application/json": {
5722
+ data: {
5723
+ /** Format: uuid */
5724
+ id: string;
5725
+ /** Format: uuid */
5726
+ organizationId: string;
5727
+ /** Format: date-time */
5728
+ createdAt: string;
5729
+ /** Format: date-time */
5730
+ updatedAt: string;
5731
+ /** @enum {string} */
5732
+ type: "image" | "video" | "document" | "model_3d";
5733
+ storageKey: string;
5734
+ filename: string;
5735
+ mimeType: string;
5736
+ sizeBytes: number;
5737
+ width: number | null;
5738
+ height: number | null;
5739
+ metadata: ((string | number | boolean | ("null" | null)) | unknown[] | {
5740
+ [key: string]: unknown;
5741
+ }) | null;
5742
+ association: {
5743
+ /** Format: uuid */
5744
+ id: string;
5745
+ /** Format: uuid */
5746
+ organizationId: string;
5747
+ /** Format: date-time */
5748
+ createdAt: string;
5749
+ /** Format: date-time */
5750
+ updatedAt: string;
5751
+ /** Format: uuid */
5752
+ mediaId: string;
5753
+ /** @enum {string} */
5754
+ entityType: "product" | "variant" | "content_page";
4996
5755
  /** Format: uuid */
4997
5756
  entityId: string;
4998
5757
  /** @enum {string} */
@@ -5092,7 +5851,7 @@ interface paths {
5092
5851
  /** Format: uuid */
5093
5852
  mediaId: string;
5094
5853
  /** @enum {string} */
5095
- entityType: "product" | "variant";
5854
+ entityType: "product" | "variant" | "content_page";
5096
5855
  /** Format: uuid */
5097
5856
  entityId: string;
5098
5857
  /** @enum {string} */
@@ -5194,7 +5953,7 @@ interface paths {
5194
5953
  /** Format: uuid */
5195
5954
  mediaId: string;
5196
5955
  /** @enum {string} */
5197
- entityType: "product" | "variant";
5956
+ entityType: "product" | "variant" | "content_page";
5198
5957
  /** Format: uuid */
5199
5958
  entityId: string;
5200
5959
  /** @enum {string} */
@@ -5271,7 +6030,7 @@ interface paths {
5271
6030
  /** Format: uuid */
5272
6031
  mediaId: string;
5273
6032
  /** @enum {string} */
5274
- entityType: "product" | "variant";
6033
+ entityType: "product" | "variant" | "content_page";
5275
6034
  /** Format: uuid */
5276
6035
  entityId: string;
5277
6036
  /**
@@ -5308,7 +6067,7 @@ interface paths {
5308
6067
  /** Format: uuid */
5309
6068
  mediaId: string;
5310
6069
  /** @enum {string} */
5311
- entityType: "product" | "variant";
6070
+ entityType: "product" | "variant" | "content_page";
5312
6071
  /** Format: uuid */
5313
6072
  entityId: string;
5314
6073
  /** @enum {string} */
@@ -5436,7 +6195,7 @@ interface paths {
5436
6195
  /** Format: uuid */
5437
6196
  mediaId: string;
5438
6197
  /** @enum {string} */
5439
- entityType: "product" | "variant";
6198
+ entityType: "product" | "variant" | "content_page";
5440
6199
  /** Format: uuid */
5441
6200
  entityId: string;
5442
6201
  /** @enum {string} */
@@ -5492,7 +6251,7 @@ interface paths {
5492
6251
  content: {
5493
6252
  "application/json": {
5494
6253
  /** @enum {string} */
5495
- entityType: "product" | "variant";
6254
+ entityType: "product" | "variant" | "content_page";
5496
6255
  /** Format: uuid */
5497
6256
  entityId: string;
5498
6257
  orderedIds: string[];
@@ -5519,7 +6278,7 @@ interface paths {
5519
6278
  /** Format: uuid */
5520
6279
  mediaId: string;
5521
6280
  /** @enum {string} */
5522
- entityType: "product" | "variant";
6281
+ entityType: "product" | "variant" | "content_page";
5523
6282
  /** Format: uuid */
5524
6283
  entityId: string;
5525
6284
  /** @enum {string} */
@@ -5598,7 +6357,7 @@ interface paths {
5598
6357
  /** Format: uuid */
5599
6358
  mediaId: string;
5600
6359
  /** @enum {string} */
5601
- entityType: "product" | "variant";
6360
+ entityType: "product" | "variant" | "content_page";
5602
6361
  /** Format: uuid */
5603
6362
  entityId: string;
5604
6363
  /** @enum {string} */