Skip to content
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

feat(specs): update shopify source and task inputs #2987

Merged
merged 6 commits into from
Apr 15, 2024
Merged
Show file tree
Hide file tree
Changes from 5 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
71 changes: 71 additions & 0 deletions specs/ingestion/common/schemas/source.yml
Original file line number Diff line number Diff line change
Expand Up @@ -414,6 +414,7 @@ SourceInput:
- $ref: '#/SourceBigQuery'
- $ref: '#/SourceGA4BigQueryExport'
- $ref: '#/SourceDocker'
- $ref: '#/SourceShopify'

SourceUpdateCommercetools:
type: object
Expand Down Expand Up @@ -449,7 +450,77 @@ SourceUpdateInput:
- $ref: '#/SourceBigQuery'
- $ref: '#/SourceGA4BigQueryExport'
- $ref: '#/SourceUpdateDocker'
- $ref: '#/SourceUpdateShopify'

DockerSourceStream:
type: object
description: Stream definition (see the Singer specification for details).

SourceUpdateShopify:
title: Shopify
type: object
additionalProperties: false
properties:
collectionIDIndexing:
type: boolean
Fluf22 marked this conversation as resolved.
Show resolved Hide resolved
default: false
description: |
Whether to index collection IDs.
If your store has `has_collection_search_page` set to true,
collection IDs will be indexed even if `collectionIDIndexing` is false.
increaseProductCollectionLimit:
type: boolean
Fluf22 marked this conversation as resolved.
Show resolved Hide resolved
default: false
description: |
Whether to increase the number of indexed collections per product.
If true, Algolia indexes 200 collections per product.
If false, 100 collections per product are indexed.
defaultPriceRatioAsOne:
type: boolean
Fluf22 marked this conversation as resolved.
Show resolved Hide resolved
default: true
description: |
Whether to set the default price ratio to 1 if no sale price is present.
The price ratio is determined by the ratio: `sale_price` / `regular_price`.
If no sale price is present, the price ratio would be 0.
If `defaultPriceRatioAsOne` is true, the price ratio is indexed as 1 instead.
excludeOOSVariantsForPriceAtTRS:
type: boolean
Fluf22 marked this conversation as resolved.
Show resolved Hide resolved
default: true
description: |
Whether to exclude out-of-stock variants when determining the `max_variant_price` and `min_variant_price` attributes.
includeVariantsInventory:
type: boolean
Fluf22 marked this conversation as resolved.
Show resolved Hide resolved
default: true
description: |
Whether to include an inventory with every variant for every product record.
hasCollectionSearchPage:
type: boolean
Fluf22 marked this conversation as resolved.
Show resolved Hide resolved
Fluf22 marked this conversation as resolved.
Show resolved Hide resolved
default: false
description: |
Whether to include collection IDs and handles in the product records.
productNamedTags:
type: boolean
Fluf22 marked this conversation as resolved.
Show resolved Hide resolved
Fluf22 marked this conversation as resolved.
Show resolved Hide resolved
default: false
description: |
Whether to convert tags on products to named tags.
To learn more, see [Named tags](https://www.algolia.com/doc/integration/shopify/sending-and-managing-data/named-tags).
SourceShopify:
allOf:
- $ref: '#/SourceUpdateShopify'
- $ref: '#/sourceShopifyBase'

sourceShopifyBase:
type: object
additionalProperties: false
properties:
shopURL:
type: string
description: URL of the Shopify store.
required:
- shopURL
x-discriminator-fields:
- shopURL
52 changes: 52 additions & 0 deletions specs/ingestion/common/schemas/task.yml
Original file line number Diff line number Diff line change
Expand Up @@ -145,6 +145,7 @@ TaskInput:
- $ref: '#/OnDemandDateUtilsInput'
- $ref: '#/ScheduleDateUtilsInput'
- $ref: '#/StreamingUtilsInput'
- $ref: '#/ShopifyInput'

TriggerInput:
type: object
Expand Down Expand Up @@ -410,3 +411,54 @@ failureThreshold:
minimum: 0
maximum: 100
description: Maximum accepted percentage of failures for a task run to finish successfully.

ShopifyInput:
title: Shopify input
type: object
additionalProperties: false
description: Represents the required elements of the task input when using a `shopify` source.
properties:
metafields:
type: array
items:
$ref: '#/ShopifyMetafield'
market:
$ref: '#/ShopifyMarket'
Fluf22 marked this conversation as resolved.
Show resolved Hide resolved
Fluf22 marked this conversation as resolved.
Show resolved Hide resolved

ShopifyMetafield:
type: object
additionalProperties: false
description: Represents a metafield in Shopify.
properties:
namespace:
type: string
key:
type: string
value:
type: string
required:
- namespace
- key
- value

ShopifyMarket:
type: object
additionalProperties: false
description: Represents a market in Shopify.
properties:
countries:
type: array
items:
type: string
currencies:
type: array
items:
type: string
locales:
type: array
items:
type: string
required:
- countries
- currencies
- locales
Loading