gocardless-dotnet icon indicating copy to clipboard operation
gocardless-dotnet copied to clipboard

Missing properties in EventListResponse

Open fpellet opened this issue 3 years ago • 1 comments

Hello,

It is possible to include objects when retrieving the events list. Except that the property is not set to EventListResponse and therefore it is not deserialized.

By example: EventListResponse.Linked.Payments of Payment list type.

Is it possible to add this? Where is the code generator defined so that I can make a PR directly?

fpellet avatar Aug 13 '22 14:08 fpellet

Same issue here.

Calling the API directly we can do something like this: https://api-sandbox.gocardless.com/events?parent_event=<event_id>&resource_type=payments&include=payment

It returns payment events and payments:

image

The equivalent call using the NuGet package is

            var eventListRequest = new EventListRequest()
            {
                ParentEvent = <event_id>,
                ResourceType = EventListRequest.EventResourceType.Payments,
                Include = EventListRequest.EventInclude.Payment
            };
        
            EventListResponse eventListResponse = await _client.Events.ListAsync(eventListRequest);

This returns the payment events but it does not return the payment objects.

Can this be fixed?

DanNoble-Spire avatar Nov 25 '22 13:11 DanNoble-Spire