mailjet / mailjet-apiv3-go

[API v3] Official Mailjet API v3 Go wrapper
https://dev.mailjet.com
MIT License
86 stars 31 forks source link

Sender resource always gets empty DNS #61

Closed tolik505 closed 3 years ago

tolik505 commented 4 years ago

I'm trying to fetch a sender

        var data []resources.Sender
    mr := &mailjet.Request{
        Resource: "sender",
        ID:       int64(18642),
    }
    err := mjClient.Get(mr, &data)

And I get empty data[0].DNS despite the DNS is visible when I'm using Postman, but the field is called DNSID there. The problem might be in unmarshaling of json response since DNS field in a struct doesn't match DNSID field in json.

tsidei commented 3 years ago

this is fixed in #66 . You can use the DNSID field now.