You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm trying to use xendit-go with simple code like below
data := invoice.CreateParams{
ExternalID: sop.ID,
Amount: sop.TotalAmount,
PayerEmail: sop.AccountID,
Description: fmt.Sprintf("Invoice #%s", sop.ID),
InvoiceDuration: int(expiredAt.Sub(time.Now()).Seconds()),
}
resp, e := invoice.Create(&data)
if e != nil {
return e
}
and only getting response API_VALIDATION_ERROR with There was an error with the format submitted to the server. without any clue.
but when using curl or postman it show more detail
{
"error_code": "API_VALIDATION_ERROR",
"message": "There was an error with the format submitted to the server.",
"errors": [
{
"field": [
"invoice_duration"
],
"location": "body",
"messages": [
"\"invoice_duration\" must be greater than 0"
],
"types": [
"number.greater"
]
}
]
}
It will good if we also got error details in response. it will saving more time for debugging what's wrong with it
The text was updated successfully, but these errors were encountered:
Hi @raditzlawliet. Thanks for your feedback.
Yes we have error standardisation in plan for our API, afterwards, our errors will come with more details definitely.
Stay tuned!
I'm trying to use xendit-go with simple code like below
and only getting response
API_VALIDATION_ERROR
withThere was an error with the format submitted to the server.
without any clue.but when using curl or postman it show more detail
It will good if we also got error details in response. it will saving more time for debugging what's wrong with it
The text was updated successfully, but these errors were encountered: