Skip to content

ModifyReceivedDocumentAsync doesn't work #109

@lorenzosacco

Description

@lorenzosacco

Describe the bug
When calling the API ModifyReceivedDocumentAsync I always get the same error:

It.FattureInCloud.Sdk.Client.ApiException: 'Error calling ModifyReceivedDocument: {"error":{"message":"Invalid request.","validation_result":{"data.items_list.0.stock":["The data.items list.0.stock field must be true or false."]}}}'

I checked the data.items[0].stock field: it's a decimal? set to 0, it's not possible to set it to true or false

Env info

  • C# version: .NET Framework 4.8
  • C# SDK version: it.FattureInCloud.Sdk 2.1.1

To Reproduce
ReceivedDocumentsApi api = new ReceivedDocumentsApi(configuration);
GetReceivedDocumentResponse response = await api.GetReceivedDocumentAsync(companyID, documentID);
ReceivedDocument document = response.Data;

ModifyReceivedDocumentRequest modifyRequest = new ModifyReceivedDocumentRequest(document);
ModifyReceivedDocumentResponse reponse = await api.ModifyReceivedDocumentAsync(companyID, documentID, modifyRequest);

Expected behavior
It should work. I tried it at the API Reference web page and it's working. I believe it's a SDK bug.

Thanks for your help.
Lorenzo

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions