@nautical-commerce/graphql-schema 3.12.0 → 3.12.2

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.
@@ -2595,6 +2595,96 @@ type BulkStockError {
2595
2595
  index: Int
2596
2596
  }
2597
2597
 
2598
+ """Result of the bundleCreate mutation."""
2599
+ type BundleCreate {
2600
+ product: Product
2601
+ productErrors: [ProductError!]!
2602
+ }
2603
+
2604
+ """Fields required to create a product bundle."""
2605
+ input BundleCreateInput {
2606
+ """Bundle display name."""
2607
+ name: String!
2608
+
2609
+ """URL slug. Auto-generated from name when omitted."""
2610
+ slug: String = null
2611
+
2612
+ """
2613
+ Seller that owns this bundle. Defaults to the caller's seller for non-MPO users. MPO must provide this field.
2614
+ """
2615
+ seller: ID = null
2616
+
2617
+ """Fixed bundle price (the customer-facing amount)."""
2618
+ price: PositiveDecimal!
2619
+
2620
+ """Bundle currency. Defaults to the seller's default currency."""
2621
+ currency: String = null
2622
+
2623
+ """SKU for the bundle's sellable variant."""
2624
+ sku: String = null
2625
+
2626
+ """Whether the bundle is immediately published."""
2627
+ isPublished: Boolean! = false
2628
+
2629
+ """
2630
+ List of component variants composing the bundle. Must contain at least 2 components.
2631
+ """
2632
+ components: [BundleItemInput!]!
2633
+ }
2634
+
2635
+ """Result of the bundleDelete mutation."""
2636
+ type BundleDelete {
2637
+ product: Product
2638
+ productErrors: [ProductError!]!
2639
+ }
2640
+
2641
+ """
2642
+ A single component within a product bundle: how many of one ProductVariant are included in the bundle. SPEC-020 Feature 2.
2643
+ """
2644
+ type BundleItem implements Node {
2645
+ """The Globally Unique ID of this object"""
2646
+ id: ID!
2647
+
2648
+ """How many units of this component are included per bundle."""
2649
+ quantity: Int!
2650
+
2651
+ """Display order of this component within the bundle."""
2652
+ sortOrder: Int
2653
+
2654
+ """The component variant this entry refers to."""
2655
+ componentVariant: ProductVariant!
2656
+ }
2657
+
2658
+ """A single component slot within a bundle."""
2659
+ input BundleItemInput {
2660
+ """Global ID of the ProductVariant included as a component."""
2661
+ componentVariantId: ID!
2662
+
2663
+ """How many units of this component are included per bundle. Must be ≥ 1."""
2664
+ quantity: Int! = 1
2665
+
2666
+ """Display order of this component within the bundle."""
2667
+ sortOrder: Int = null
2668
+ }
2669
+
2670
+ """Result of the bundleUpdate mutation."""
2671
+ type BundleUpdate {
2672
+ product: Product
2673
+ productErrors: [ProductError!]!
2674
+ }
2675
+
2676
+ """Fields for updating a product bundle."""
2677
+ input BundleUpdateInput {
2678
+ name: String = null
2679
+ price: PositiveDecimal = null
2680
+ isPublished: Boolean = null
2681
+
2682
+ """
2683
+ Optional replacement set of components. When provided, replaces the current component set entirely (atomic). Omit to keep components unchanged.
2684
+ """
2685
+ components: [BundleItemInput!] = null
2686
+ }
2687
+
2598
2688
  """CSV file metadata extracted during parsing."""
2599
2689
  type CSVMetadata {
2600
2690
  """Column headers from the CSV"""
@@ -8494,13 +8584,19 @@ type Mutation {
8494
8584
  """Publish pages."""
8495
8585
  pageBulkPublish(ids: [ID!]!, isPublished: Boolean!): PageBulkPublish!
8496
8586
 
8497
- """Creates a new policy."""
8587
+ """
8588
+ Creates a new policy. MPO staff with MANAGE_STOREFRONTS may create policies for any seller or marketplace-level (seller=null); seller users may create policies only for their own seller.
8589
+ """
8498
8590
  policyCreate(input: PolicyInput!): PolicyCreate!
8499
8591
 
8500
- """Updates an existing policy."""
8592
+ """
8593
+ Updates an existing policy. Seller users may update only their own policies; MPO staff may update any policy. Reassigning ownership (changing seller) requires MANAGE_STOREFRONTS.
8594
+ """
8501
8595
  policyUpdate(id: ID!, input: PolicyInput!): PolicyUpdate!
8502
8596
 
8503
- """Deletes a policy."""
8597
+ """
8598
+ Deletes a policy. Seller users may delete only their own policies; MPO staff may delete any policy.
8599
+ """
8504
8600
  policyDelete(id: ID!): PolicyDelete!
8505
8601
 
8506
8602
  """Deletes policies."""
@@ -9270,6 +9366,17 @@ type Mutation {
9270
9366
  """Creates a download URL for digital content."""
9271
9367
  digitalContentUrlCreate(input: DigitalContentUrlCreateInput!): DigitalContentUrlCreate!
9272
9368
 
9369
+ """
9370
+ Create a product bundle. Builds a Product flagged is_bundle=True + its single sellable ProductVariant + BundleItem rows for each component, all in one transaction.
9371
+ """
9372
+ bundleCreate(input: BundleCreateInput!): BundleCreate!
9373
+
9374
+ """Update an existing bundle (name, price, components, is_published)."""
9375
+ bundleUpdate(id: ID!, input: BundleUpdateInput!): BundleUpdate!
9376
+
9377
+ """Delete a bundle product. Cascades to its variant and BundleItems."""
9378
+ bundleDelete(id: ID!): BundleDelete!
9379
+
9273
9380
  """Register a new user account."""
9274
9381
  accountRegister(input: AccountRegisterInput!): AccountRegister!
9275
9382
 
@@ -13403,6 +13510,11 @@ type Policy implements Node & ObjectWithMetadata {
13403
13510
 
13404
13511
  """The category of this policy"""
13405
13512
  category: PolicyCategory!
13513
+
13514
+ """
13515
+ The seller that owns this policy, or null for marketplace-level policies.
13516
+ """
13517
+ seller: Seller
13406
13518
  }
13407
13519
 
13408
13520
  """Result of policy bulk delete mutation."""
@@ -13492,12 +13604,14 @@ enum PolicyErrorCode {
13492
13604
  }
13493
13605
 
13494
13606
  """
13495
- Policy(id, publication_date, is_published, created_at, updated_at, content, content_html, tenant, seo_title, seo_description, category, slug, title)
13607
+ Policy(id, publication_date, is_published, created_at, updated_at, content, content_html, tenant, seo_title, seo_description, category, slug, title, seller)
13496
13608
  """
13497
13609
  input PolicyFilterInput {
13498
13610
  search: String
13499
13611
  isPublished: Boolean
13500
13612
  category: String
13613
+ seller: String
13614
+ marketplaceOnly: Boolean
13501
13615
  AND: PolicyFilterInput
13502
13616
  OR: PolicyFilterInput
13503
13617
  NOT: PolicyFilterInput
@@ -13523,6 +13637,11 @@ input PolicyInput {
13523
13637
 
13524
13638
  """Search engine optimization fields."""
13525
13639
  seo: SeoInput = null
13640
+
13641
+ """
13642
+ Seller that owns this policy. If omitted, defaults to the calling seller user's own seller; MPO staff may omit it to create a marketplace-level policy.
13643
+ """
13644
+ seller: ID = null
13526
13645
  }
13527
13646
 
13528
13647
  """Fields available for sorting policies"""
@@ -13652,6 +13771,11 @@ type Product implements Node & ObjectWithMetadata {
13652
13771
  """Whether shipping is required"""
13653
13772
  isShippingRequired: Boolean!
13654
13773
 
13774
+ """
13775
+ Whether this product is a bundle. A bundle has exactly one sellable variant whose availability is derived from its BundleItem components (SPEC-020 Feature 2).
13776
+ """
13777
+ isBundle: Boolean!
13778
+
13655
13779
  """Whether sellers can add variants"""
13656
13780
  allowSellerVariants: Boolean!
13657
13781
 
@@ -14155,6 +14279,11 @@ input ProductDimensionsInput {
14155
14279
  length: PositiveDecimal = null
14156
14280
  width: PositiveDecimal = null
14157
14281
  height: PositiveDecimal = null
14282
+
14283
+ """
14284
+ Unit for length, width, and height. When omitted, the marketplace's configured default length unit is used.
14285
+ """
14286
+ unit: LengthUnitsStrEnum = null
14158
14287
  }
14159
14288
 
14160
14289
  """Represents errors from product operations."""
@@ -14239,7 +14368,7 @@ enum ProductFieldEnum {
14239
14368
  }
14240
14369
 
14241
14370
  """
14242
- Product(id, publication_date, is_published, private_metadata, metadata, description, description_html, deleted_at, deleted_by_user, deleted_by_app, deletion_batch_uuid, external_id, external_source, external_inventory_id, tenant, seller, seo_title, seo_description, product_type, name, slug, search_vector, category, currency, minimal_variant_price_amount, updated_at, created_at, charge_taxes, weight, available_for_purchase, visible_in_listings, default_variant, cumulative_price_amount, override_price, override_currency, status, sub_status, is_price_override_allowed, is_shipping_required, is_digital, warnings, product_source, allow_seller_variants, minimal_variant_price, cumulative_price)
14371
+ Product(id, publication_date, is_published, private_metadata, metadata, description, description_html, deleted_at, deleted_by_user, deleted_by_app, deletion_batch_uuid, external_id, external_source, external_inventory_id, tenant, seller, seo_title, seo_description, product_type, name, slug, search_vector, category, currency, minimal_variant_price_amount, updated_at, created_at, charge_taxes, weight, available_for_purchase, visible_in_listings, default_variant, cumulative_price_amount, override_price, override_currency, status, sub_status, is_price_override_allowed, is_shipping_required, is_digital, is_bundle, warnings, product_source, allow_seller_variants, minimal_variant_price, cumulative_price)
14243
14372
  """
14244
14373
  input ProductFilterInput {
14245
14374
  isPublished: Boolean
@@ -15075,6 +15204,21 @@ type ProductVariant implements Node & ObjectWithMetadata {
15075
15204
  """Quantity of variant available for sale"""
15076
15205
  quantityAvailable(countryCode: CountryCode = null): Int!
15077
15206
 
15207
+ """
15208
+ Whether this variant belongs to a bundle product. Equivalent to `product.isBundle` — exposed here so clients can branch on the variant without an additional product lookup.
15209
+ """
15210
+ isBundle: Boolean!
15211
+
15212
+ """
15213
+ If this variant is a bundle, the list of component variants and their quantities. Empty list for non-bundle variants.
15214
+ """
15215
+ bundleItems: [BundleItem!]!
15216
+
15217
+ """
15218
+ Derived availability for a bundle variant — min over components of floor(component_available / bundle_item.quantity). Returns the standard quantity_available for non-bundle variants so clients can use this field uniformly.
15219
+ """
15220
+ bundleAvailableQuantity(countryCode: CountryCode = null): Int!
15221
+
15078
15222
  """Total quantity ordered."""
15079
15223
  quantityOrdered: Int
15080
15224
 
@@ -16275,7 +16419,9 @@ type Query {
16275
16419
  """Look up a seller by ID, number (PK), or slug"""
16276
16420
  seller(id: ID = null, number: ID = null, taxId: String = null, slug: String = null): Seller
16277
16421
 
16278
- """List sellers (MPO only)"""
16422
+ """
16423
+ List sellers. Requires MANAGE_MARKETPLACE, except for the cross-sell discovery use case (filter.hasCrossSellProducts=true), which is open to any authenticated user so sellers can browse other sellers' cross-sell-enabled catalogs.
16424
+ """
16279
16425
  sellers(
16280
16426
  filter: SellerFilterInput
16281
16427
  sortBy: SellerSortingInput = null
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@nautical-commerce/graphql-schema",
3
- "version": "3.12.0",
3
+ "version": "3.12.2",
4
4
  "description": "Traide API GraphQL Schema",
5
5
  "main": "./nautical/schema.graphql",
6
6
  "scripts": {