Fluent Commerce Logo
Docs
Sign In

GraphQL Enhancements: Wildcard Product Search, Customer-Based Order Queries, and Attributes on Invoice Item

Release

Author:

Yulia Andreyanova

Changed on:

27 May 2025

Target release date:2025-05-21
Release status:Released

Description

This release improves discoverability and data integration with enhanced search in product and order queries and richer detail support in invoice data. Wildcard-enabled, case-insensitive search now applies to product name and reference fields. A new customer filter in the Orders query adds flexible lookup by customer name, email, phone, and other identifiers. Additionally, invoice item attributes provide structured metadata for external systems and reporting.

Key Benefits

  • Faster Product Discovery: Wildcard, case-insensitive search on Product Name and Reference.
  • Smarter Order Lookup: Customer filter on the
    `orders`
    query supports search by multiple customer fields.
  • Richer Invoice Data: New invoice item attributes enable granular detail for ERP, loyalty, and reporting integration.

Changelog

1. Enhanced Product Search via Wildcard Support

  • The
    `products`
    query now enables case-insensitive substring search on both Product Name (
    `name`
    ) and Product Reference (
    `ref`
    ). The queries require no changes; wildcard search is enabled by default.

🔍Example:

`name: ["%shoe%"]`
returns both Shoe, Running Shoe, and Kids Shoe.

2. Customer Filter Added to Orders Query

  • A new
    `customer`
    filter has been added to the
    `orders`
    query, supporting a flexible
    `SearchCustomerInput`
    input type:
    • Fields include
      `ref`
      ,
      `firstName`
      ,
      `lastName`
      ,
      `primaryEmail`
      ,
      `primaryPhone`
      , and
      `username`
      .
  • Supports wildcard case-insensitive pattern matching (e.g.,
    `["Ann%"]`
    ) within each field.
  • Logical behavior: Each field in the input can contain multiple values. The system returns results that match any of the provided values within the same field (logical
    `OR`
    within each field). Across different fields, filters should be combined using logical
    `AND`
    .
  • Fully backward compatible with the existing
    `customerLink`
    argument.

🔍Example: How Filtering with Logical

`OR`
and
`AND`
Works

The filter below targets customers with:

  • A first name matching any of these:
    `"John"`
    ,
    `"Emma"`
    ,
    `"Alice"`
  • A last name that includes the pattern
    `"Doe"`
  • Or a username exactly equal to
    `"j.smith"`
1{
2  "customer": [
3    {
4      "firstName": ["John", "Emma", "Alice"],
5      "lastName": "%Doe%"
6    },
7    {
8      "username": "j.smith"
9    }
10  ]
11}

Language: plain_text

Name: The filter input example

Description:

[Warning: empty required content area]

This configuration returns:

  • Customers with a first name of John, Emma, or Alice and a last name containing "Doe" (e.g., "Doer", "Doeman").
  • Any customer with the username "j.smith", regardless of their name.

Each field supports multiple values using

`OR`
logic. Conditions are combined using
`AND`
across fields in the same block. At the top level, separate blocks (arrays) are combined using
`OR`
.

3. New attributes Field for the invoiceItem Entity

  • The
    `invoiceItem`
    entity has been extended with a new
    `attributes`
    field to capture line-level metadata.
  • This supports scenarios where external systems (e.g., ERP, loyalty platforms, reporting tools) require different identifiers or transaction breakdowns:
    • Include UPC and SKU details in the invoice payload for ERP and reconciliation systems.
    • Support split payment types (e.g., loyalty points + currency) as part of loyalty programs.
    • Store vendor-specific SKUs when cross-referencing third-party catalogs.

🔍Examples:

1"attributes": {
2  "name": "invoice details",
3  "type": "JSON",
4  "value": {
5    "SKU": "ABCD-001",
6    "paymentType": "points+cash"
7  }
8}

Language: plain_text

Name: Structured format

Description:

Combine SKU and payment type in a single JSON attribute

1"attributes": {
2  "name": "SKU",
3  "type": "String",
4  "value": "ABCD-001"
5}
6
7
8"attributes": {
9  "name": "paymentType",
10  "type": "String",
11  "value": "points+cash"
12}

Language: plain_text

Name: Simple format

Description:

Store SKU and payment type as separate string attributes

Released capability depth:Enhancement, New capability
Release bundle / Capability type:Platform, Fluent OMS