Skip to content

feat(specs): add CT Query predicate property #4654

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 3 commits into from
Mar 25, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 8 additions & 0 deletions specs/ingestion/common/schemas/source.yml
Original file line number Diff line number Diff line change
Expand Up @@ -135,6 +135,10 @@ SourceCommercetools:
default: true
description: |
Whether a fallback value is stored in the Algolia record if there's no inventory information about the product.
productQueryPredicate:
type: string
description: |
Predicate to filter out specific products when indexing. For more information, see [Query Predicate](https://docs.commercetools.com/api/predicates/query).
customFields:
$ref: '#/CommercetoolsCustomFields'
required:
Expand Down Expand Up @@ -405,6 +409,10 @@ SourceUpdateCommercetools:
type: boolean
description: |
Whether a fallback value is stored in the Algolia record if there's no inventory information about the product.
productQueryPredicate:
type: string
description: |
Predicate to filter out specific products when indexing. For more information, see [Query Predicate](https://docs.commercetools.com/api/predicates/query).
customFields:
$ref: '#/CommercetoolsCustomFields'

Expand Down
6 changes: 4 additions & 2 deletions tests/CTS/requests/ingestion/createSource.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,8 @@
"de"
],
"url": "http://commercetools.com",
"projectKey": "keyID"
"projectKey": "keyID",
"productQueryPredicate": "masterVariant(attributes(name=\"Brand\" and value=\"Algolia\"))"
},
"authenticationID": "6c02aeb1-775e-418e-870b-1faccd4b2c0f"
},
Expand All @@ -30,7 +31,8 @@
"de"
],
"url": "http://commercetools.com",
"projectKey": "keyID"
"projectKey": "keyID",
"productQueryPredicate": "masterVariant(attributes(name=\"Brand\" and value=\"Algolia\"))"
},
"authenticationID": "6c02aeb1-775e-418e-870b-1faccd4b2c0f"
}
Expand Down