From Shopify GraphQL docs: https://shopify.dev/docs/api/admin-graphql/latest/scalars/UnsignedInt64
An unsigned 64-bit integer. Represents whole numeric values between 0 and 2^64 - 1 encoded as a string of base-10 digits.
Currently here it is mapped to an ulong:
|
/// <summary> |
|
/// The size of the file to upload, in bytes. This is required when the request's resource property is set to |
|
/// [VIDEO](https://shopify.dev/api/admin-graphql/latest/enums/StagedUploadTargetGenerateUploadResource#value-video) |
|
/// or [MODEL_3D](https://shopify.dev/api/admin-graphql/latest/enums/StagedUploadTargetGenerateUploadResource#value-model3d). |
|
/// </summary> |
|
[JsonPropertyName("fileSize")] |
|
public ulong? fileSize { get; set; } = null; |
But from the Shopify docs it is also used elsewhere.
From the docs it should be a string instead: https://shopify.dev/docs/api/admin-graphql/latest/input-objects/StagedUploadInput#fields-fileSize
Or it gives the same error as in #1188 (I don't know why it went un-noticed):
Variable $input of type [StagedUploadInput!]! was provided invalid value for 0.fileSize (UnsignedInt64 '193549' must be encoded as a string)
A workaround is to use an anonymous type with fileSize property set to string instead of using StagedUploadInput directly.
From Shopify GraphQL docs: https://shopify.dev/docs/api/admin-graphql/latest/scalars/UnsignedInt64
Currently here it is mapped to an ulong:
ShopifySharp/ShopifySharp/Entities/GraphQL/Generated/Types/StagedUploadInput.generated.cs
Lines 22 to 28 in 608d6f7
But from the Shopify docs it is also used elsewhere.
From the docs it should be a string instead: https://shopify.dev/docs/api/admin-graphql/latest/input-objects/StagedUploadInput#fields-fileSize
Or it gives the same error as in #1188 (I don't know why it went un-noticed):
A workaround is to use an anonymous type with
fileSizeproperty set tostringinstead of usingStagedUploadInputdirectly.