Skip to content

Commit 178db74

Browse files
committed
Set API version to 2024-01 on order-routing-location-rule template
1 parent 4532522 commit 178db74

File tree

6 files changed

+192
-245
lines changed

6 files changed

+192
-245
lines changed

order-routing/javascript/location-rules/default/schema.graphql

Lines changed: 83 additions & 67 deletions
Original file line numberDiff line numberDiff line change
@@ -170,7 +170,7 @@ type CartDeliveryOption {
170170
"""
171171
The unique identifier of the delivery option.
172172
"""
173-
handle: String!
173+
handle: Handle!
174174

175175
"""
176176
The title of the delivery option.
@@ -2495,6 +2495,11 @@ type Customer implements HasMetafields {
24952495
"""
24962496
email: String
24972497

2498+
"""
2499+
The customer's first name.
2500+
"""
2501+
firstName: String
2502+
24982503
"""
24992504
Whether the customer has any of the given tags.
25002505
"""
@@ -2520,6 +2525,11 @@ type Customer implements HasMetafields {
25202525
"""
25212526
id: ID!
25222527

2528+
"""
2529+
The customer's last name.
2530+
"""
2531+
lastName: String
2532+
25232533
"""
25242534
Returns a metafield by namespace and key that belongs to the resource.
25252535
"""
@@ -2636,6 +2646,26 @@ enum DeliveryMethod {
26362646
SHIPPING
26372647
}
26382648

2649+
"""
2650+
A customization representing how delivery options are generated.
2651+
"""
2652+
type DeliveryOptionGenerator implements HasMetafields {
2653+
"""
2654+
Returns a metafield by namespace and key that belongs to the resource.
2655+
"""
2656+
metafield(
2657+
"""
2658+
The key for the metafield.
2659+
"""
2660+
key: String!
2661+
2662+
"""
2663+
The container the metafield belongs to. If omitted, the app-reserved namespace will be used.
2664+
"""
2665+
namespace: String
2666+
): Metafield
2667+
}
2668+
26392669
"""
26402670
A group of one or more items to be fulfilled together.
26412671
"""
@@ -2659,39 +2689,30 @@ type FulfillmentGroup {
26592689
A list of inventory location handles for the fulfillment group.
26602690
"""
26612691
inventoryLocationHandles: [Handle!]!
2662-
}
2663-
2664-
"""
2665-
A list of ranked locations for this fulfillment group.
2666-
"""
2667-
input FulfillmentGroupRankedLocations {
2668-
"""
2669-
The identifier for the fulfillment group.
2670-
"""
2671-
fulfillmentGroupHandle: Handle!
26722692

26732693
"""
2674-
The ranked locations for this fulfillment group.
2694+
The merchandise in the fulfillment group.
26752695
"""
2676-
rankings: [RankedLocation!]!
2696+
lines: [CartLine!]!
26772697
}
26782698

26792699
"""
2680-
The result of the function. In API versions 2023-10 and beyond, this type is deprecated in favor of `FunctionRunResult`.
2700+
The result of a local pickup delivery option generator function. In API versions
2701+
2023-10 and beyond, this type is deprecated in favor of `FunctionRunResult`.
26812702
"""
26822703
input FunctionResult {
26832704
"""
2684-
The ranked locations for each fulfillment group.
2705+
The ordered list of operations to apply for local pickup delivery option generation.
26852706
"""
26862707
operations: [Operation!]!
26872708
}
26882709

26892710
"""
2690-
The result of the function.
2711+
The result of a local pickup delivery option generator function.
26912712
"""
26922713
input FunctionRunResult {
26932714
"""
2694-
The ranked locations for each fulfillment group.
2715+
The ordered list of operations to apply for local pickup delivery option generation.
26952716
"""
26962717
operations: [Operation!]!
26972718
}
@@ -2708,7 +2729,7 @@ type GateConfiguration implements HasMetafields {
27082729
"""
27092730
A non-unique string used to group gate configurations.
27102731
"""
2711-
handle: String
2732+
handle: Handle
27122733

27132734
"""
27142735
The ID of the gate configuration.
@@ -2769,7 +2790,7 @@ interface HasGates {
27692790
"""
27702791
The handle of the gate configurations to search for.
27712792
"""
2772-
handle: String
2793+
handle: Handle
27732794
): [GateSubject!]!
27742795
}
27752796

@@ -2816,32 +2837,29 @@ Example value: `"gid://shopify/Product/10079785100"`
28162837
"""
28172838
scalar ID
28182839

2819-
"""
2820-
The input object for the function.
2821-
"""
28222840
type Input {
28232841
"""
28242842
The cart.
28252843
"""
28262844
cart: Cart!
28272845

28282846
"""
2829-
List of fulfillment groups in the context of this cart.
2847+
The delivery option generator that owns the current function.
28302848
"""
2831-
fulfillmentGroups: [FulfillmentGroup!]!
2849+
deliveryOptionGenerator: DeliveryOptionGenerator!
28322850

28332851
"""
2834-
The localization of the Function execution context.
2852+
A list of fulfillment groups.
28352853
"""
2836-
localization: Localization!
2854+
fulfillmentGroups: [FulfillmentGroup!]!
28372855

28382856
"""
2839-
The order routing location rule containing the function.
2857+
The localization of the Function execution context.
28402858
"""
2841-
locationRule: OrderRoutingLocationRule!
2859+
localization: Localization!
28422860

28432861
"""
2844-
The locations where the inventory items on this cart are stocked.
2862+
The locations that can fulfill the items in the cart or that offer local pickup.
28452863
"""
28462864
locations: [Location!]!
28472865

@@ -3576,6 +3594,26 @@ enum LanguageCode {
35763594
ZU
35773595
}
35783596

3597+
"""
3598+
A local pickup delivery option.
3599+
"""
3600+
input LocalPickupDeliveryOption {
3601+
"""
3602+
The cost of the delivery option in the currency of the cart. Defaults to zero.
3603+
"""
3604+
cost: Decimal
3605+
3606+
"""
3607+
The pickup location.
3608+
"""
3609+
pickupLocation: PickupLocation!
3610+
3611+
"""
3612+
The title of the delivery option.
3613+
"""
3614+
title: String
3615+
}
3616+
35793617
"""
35803618
Represents limited information about the current time relative to the parent object.
35813619
"""
@@ -3868,7 +3906,7 @@ type Market implements HasMetafields {
38683906
"""
38693907
A human-readable unique string for the market automatically generated from its title.
38703908
"""
3871-
handle: String!
3909+
handle: Handle!
38723910

38733911
"""
38743912
A globally-unique identifier.
@@ -3977,7 +4015,7 @@ type MutationRoot {
39774015
): Void! @deprecated(reason: "Use the target-specific field instead.")
39784016

39794017
"""
3980-
Handles the Function result for the purchase.order-routing-location-rule.run target.
4018+
Handles the Function result for the purchase.local-pickup-delivery-option-generator.run target.
39814019
"""
39824020
run(
39834021
"""
@@ -3988,33 +4026,26 @@ type MutationRoot {
39884026
}
39894027

39904028
"""
3991-
An operation to apply to the fulfillment group inventory locations.
4029+
An operation to generate local pickup delivery options.
39924030
"""
39934031
input Operation {
39944032
"""
3995-
Request to rank a fulfillment group's inventory locations.
4033+
The local pickup delivery option to add.
39964034
"""
3997-
rank: FulfillmentGroupRankedLocations!
4035+
add: LocalPickupDeliveryOption!
39984036
}
39994037

4000-
"""
4001-
A customization which ranks inventory locations for fulfillment purposes.
4002-
"""
4003-
type OrderRoutingLocationRule implements HasMetafields {
4038+
input PickupLocation {
40044039
"""
4005-
Returns a metafield by namespace and key that belongs to the resource.
4040+
The location handle of the pickup in-store location.
40064041
"""
4007-
metafield(
4008-
"""
4009-
The key for the metafield.
4010-
"""
4011-
key: String!
4042+
locationHandle: Handle!
40124043

4013-
"""
4014-
The container the metafield belongs to. If omitted, the app-reserved namespace will be used.
4015-
"""
4016-
namespace: String
4017-
): Metafield
4044+
"""
4045+
The pickup instruction to show to customers at checkout.
4046+
Defaults to location's local pickup expected pickup time setting.
4047+
"""
4048+
pickupInstruction: String
40184049
}
40194050

40204051
"""
@@ -4028,13 +4059,13 @@ type Product implements HasGates & HasMetafields {
40284059
"""
40294060
The handle of the gate configurations to search for.
40304061
"""
4031-
handle: String
4062+
handle: Handle
40324063
): [GateSubject!]!
40334064

40344065
"""
40354066
A unique human-friendly string of the product's title.
40364067
"""
4037-
handle: String!
4068+
handle: Handle!
40384069

40394070
"""
40404071
Whether the product has any of the given tags.
@@ -4192,21 +4223,6 @@ type PurchasingCompany {
41924223
location: CompanyLocation!
41934224
}
41944225

4195-
"""
4196-
A location with a rank associated with it.
4197-
"""
4198-
input RankedLocation {
4199-
"""
4200-
The location handle.
4201-
"""
4202-
locationHandle: Handle!
4203-
4204-
"""
4205-
The location's rank.
4206-
"""
4207-
rank: Int!
4208-
}
4209-
42104226
"""
42114227
Represents how products and variants can be sold and purchased.
42124228
"""
@@ -4335,4 +4351,4 @@ enum WeightUnit {
43354351
1 pound equals 16 ounces.
43364352
"""
43374353
POUNDS
4338-
}
4354+
}

order-routing/javascript/location-rules/default/shopify.extension.toml.liquid

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
api_version = "unstable"
1+
api_version = "2024-01"
22

33
[[extensions]]
44
handle = "{{handle}}"

0 commit comments

Comments
 (0)