Skip to content

Commit

Permalink
Merge pull request #906 from clement911/2023-07
Browse files Browse the repository at this point in the history
Upgrade to 2023-07 version
  • Loading branch information
clement911 authored Jul 28, 2023
2 parents cc050e1 + 035bf00 commit 271e6a3
Show file tree
Hide file tree
Showing 5 changed files with 60 additions and 1 deletion.
6 changes: 6 additions & 0 deletions ShopifySharp/Entities/LineItem.cs
Original file line number Diff line number Diff line change
Expand Up @@ -209,5 +209,11 @@ public class LineItem : ShopifyObject
/// </summary>
[JsonProperty("fulfillment_line_item_id")]
public long? FulfillmentLineItemId { get; set; }

/// <summary>
/// A list of attributed staffs for this line item
/// </summary>
[JsonProperty("attributed_staffs")]
public IEnumerable<LineItemAttributedStaff> AttributedStaffs { get; set; }
}
}
22 changes: 22 additions & 0 deletions ShopifySharp/Entities/LineItemAttributedStaff.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
using Newtonsoft.Json;

namespace ShopifySharp
{
/// <summary>
/// An object representing the staff member attributed to the line item
/// </summary>
public class LineItemAttributedStaff
{
/// <summary>
/// The GraphQL id of the staff member
/// </summary>
[JsonProperty("id")]
public string Id { get; set; }

/// <summary>
/// The quantity of the line item attributed to the staff member.
/// </summary>
[JsonProperty("quantity")]
public long? Quantity { get; set; }
}
}
25 changes: 25 additions & 0 deletions ShopifySharp/Entities/Order.cs
Original file line number Diff line number Diff line change
Expand Up @@ -234,6 +234,7 @@ public class Order : ShopifyObject
/// The type of payment processing method. Known values are 'checkout', 'direct', 'manual', 'offsite', 'express', 'free' and 'none'.
/// </summary>
[JsonProperty("processing_method")]
[Obsolete("Deprecated in version 2023-04. https://shopify.dev/docs/api/release-notes/2023-04#payment-properties-on-the-order-resource-have-been-removed")]
public string ProcessingMethod { get; set; }

/// <summary>
Expand Down Expand Up @@ -481,5 +482,29 @@ public class Order : ShopifyObject
/// </summary>
[JsonProperty("payment_terms")]
public PaymentTerms PaymentTerms { get; set; }

/// <summary>
/// The current total additional fees on the order in shop and presentment currencies. The amount values associated with this field reflect order edits, returns, and refunds.
/// </summary>
[JsonProperty("current_total_additional_fees_set")]
public PriceSet CurrentTotalAdditionalFeesSet { get; set; }

/// <summary>
/// The original total additional fees on the order in shop and presentment currencies.
/// </summary>
[JsonProperty("original_total_additional_fees_set")]
public PriceSet OriginalTotalAdditionalFeesSet { get; set; }

/// <summary>
/// The purchase order number associated to this order
/// </summary>
[JsonProperty("po_number")]
public PaymentTerms PoNumber { get; set; }

/// <summary>
/// Whether this order was exempt from taxes.
/// </summary>
[JsonProperty("tax_exempt")]
public bool? TaxExempt { get; set; }
}
}
6 changes: 6 additions & 0 deletions ShopifySharp/Entities/Transaction.cs
Original file line number Diff line number Diff line change
Expand Up @@ -160,5 +160,11 @@ public class Transaction : ShopifyObject
/// </summary>
[JsonProperty("payment_id")]
public string PaymentId { get; set; }

/// <summary>
/// Specifies the available amount with currency to capture on the gateway in shop and presentment currencies. Only available when an amount is capturable or manually mark as paid.
/// </summary>
[JsonProperty("total_unsettled_set")]
public PriceSet TotalUnsettledSet { get; set; }
}
}
2 changes: 1 addition & 1 deletion ShopifySharp/Services/ShopifyService.cs
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ namespace ShopifySharp
{
public abstract class ShopifyService : IShopifyService
{
public virtual string APIVersion => "2023-01";
public virtual string APIVersion => "2023-07";

private static IRequestExecutionPolicy _GlobalExecutionPolicy = new DefaultRequestExecutionPolicy();

Expand Down

0 comments on commit 271e6a3

Please sign in to comment.