Giter VIP home page Giter VIP logo

Comments (2)

KadoBOT avatar KadoBOT commented on June 24, 2024

Hi @grimhan,

Yes, this is a known issue. There is an extra RecurringDetail which is missing in our API schema, see this.

We need to wait until it is fixed so we can regenerate our models. Meanwhile, would you mind manually changing the generated models and create a pull request?

Thanks,

from adyen-go-api-library.

JustinLiang90 avatar JustinLiang90 commented on June 24, 2024

Hi Team, any updates on this? we still experience the same issue when using the latest library.

For anyone has the same experience, here is the temp solution:

// RecurringDetailsResult is the copy of the same name struct from Adyen recurring package.
// Only just for temporarily fixing the known issue.
type RecurringDetailsResult struct {
  CreationDate          *time.Time         `json:"creationDate,omitempty"`
  Details               *[]RecurringDetail `json:"details,omitempty"`
  LastKnownShopperEmail string             `json:"lastKnownShopperEmail,omitempty"`
  ShopperReference      string             `json:"shopperReference,omitempty"`
}

type RecurringDetail struct {
  RecurringDetail recurring.RecurringDetail `json:"RecurringDetail,omitempty"`
}

// Here is how to call the Adyen API
func GetRecurringPaymentDetail(
  ctx context.Context, 
  client *adyen.APIClient,
) (RecurringDetailsResult, *http.Response, error) {
  req := &recurring.RecurringDetailsRequest{
    MerchantAccount:  "some merchant account",
    Recurring:        &recurring.RecurringType{Contract: "RECURRING"},
    ShopperReference: "some shopper reference",
  }
  
  res := &RecurringDetailsResult{}
  url := client.Recurring.BasePath() + "/listRecurringDetails"
  httpRes, err := client.Recurring.Client.MakeHTTPPostRequest(req, res, url, ctx) 
  return *res, httpRes, err
}

from adyen-go-api-library.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.