Skip to content

Commit a86813a

Browse files
committed
2 parents c2673be + 2c84d42 commit a86813a

File tree

3 files changed

+7
-3
lines changed

3 files changed

+7
-3
lines changed

Source/FikaAmazonAPI/AmazonSpApiSDK/Models/FulfillmentInbound/PartneredLtlDataInput.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ public partial class PartneredLtlDataInput : IEquatable<PartneredLtlDataInput>,
3838
/// <param name="PalletList">PalletList.</param>
3939
/// <param name="TotalWeight">The total weight of the shipment..</param>
4040
/// <param name="SellerDeclaredValue">The declaration of the total value of the inventory in the shipment..</param>
41-
public PartneredLtlDataInput(Contact Contact = default(Contact), UnsignedIntType BoxCount = default(UnsignedIntType), SellerFreightClass? SellerFreightClass = default(SellerFreightClass?), string FreightReadyDate = default(string), PalletList PalletList = default(PalletList), Weight TotalWeight = default(Weight), Amount SellerDeclaredValue = default(Amount))
41+
public PartneredLtlDataInput(Contact Contact = default(Contact), int BoxCount = default(int), SellerFreightClass? SellerFreightClass = default(SellerFreightClass?), string FreightReadyDate = default(string), PalletList PalletList = default(PalletList), Weight TotalWeight = default(Weight), Amount SellerDeclaredValue = default(Amount))
4242
{
4343
this.Contact = Contact;
4444
this.BoxCount = BoxCount;
@@ -61,7 +61,7 @@ public partial class PartneredLtlDataInput : IEquatable<PartneredLtlDataInput>,
6161
/// </summary>
6262
/// <value>The number of boxes in the shipment.</value>
6363
[DataMember(Name = "BoxCount", EmitDefaultValue = false)]
64-
public UnsignedIntType BoxCount { get; set; }
64+
public int BoxCount { get; set; }
6565

6666

6767
/// <summary>

Source/FikaAmazonAPI/FikaAmazonAPI.csproj

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,7 @@
4040
<PackageReference Include="Microsoft.CSharp" Version="4.7.0" />
4141
<PackageReference Include="Newtonsoft.Json" Version="13.0.1" />
4242
<PackageReference Include="RestSharp" Version="108.0.2" />
43+
<PackageReference Include="RestSharp.Serializers.NewtonsoftJson" Version="108.0.2" />
4344
<PackageReference Include="System.Collections" Version="4.3.0" />
4445
<PackageReference Include="System.ComponentModel.Annotations" Version="5.0.0" />
4546
<PackageReference Include="System.Reflection" Version="4.3.0" />

Source/FikaAmazonAPI/Services/RequestService.cs

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,8 @@
1313
using System.Linq;
1414
using System.Net;
1515
using System.Threading.Tasks;
16+
using Newtonsoft.Json.Serialization;
17+
using RestSharp.Serializers.NewtonsoftJson;
1618
using static FikaAmazonAPI.AmazonSpApiSDK.Models.Token.CacheTokenData;
1719
using static FikaAmazonAPI.Utils.Constants;
1820

@@ -55,6 +57,7 @@ public RequestService(AmazonCredential amazonCredential)
5557
private void CreateRequest(string url, RestSharp.Method method)
5658
{
5759
RequestClient = new RestClient(ApiBaseUrl);
60+
RequestClient.UseNewtonsoftJson();
5861
Request = new RestRequest(url, method);
5962
}
6063
protected async Task CreateUnAuthorizedRequestAsync(string url, RestSharp.Method method, List<KeyValuePair<string, string>> queryParameters = null, object postJsonObj = null)
@@ -105,8 +108,8 @@ protected void CreateAuthorizedPagedRequest(AmazonFilter filter, string url, Res
105108
RestHeader();
106109
AddAccessToken();
107110
AddShippingBusinessId();
111+
108112
Request = await TokenGeneration.SignWithSTSKeysAndSecurityTokenAsync(Request, RequestClient.Options.BaseUrl.Host, AmazonCredential);
109-
110113
var response = await RequestClient.ExecuteAsync<T>(Request);
111114
SaveLastRequestHeader(response.Headers);
112115
SleepForRateLimit(response.Headers, rateLimitType);

0 commit comments

Comments
 (0)