error, because data in camelCase
Jekiwijaya opened this issue · 4 comments
Hello, I tried to use this, and I getting error
{
"error": {
"message": "Request failed with status code 400",
"data": "{\"grantType\":\"client_credentials\",\"clientId\":\"xxx\",\"clientSecret\":\"xxx\"}"
}
}
As I see, everything in this code is in camcelCase
https://github.com/iilei/traduora-cli/blob/master/src/modules/getAuthToken.js#L6-L8
but in swagger, everything is snake_case
https://docs.traduora.com/docs/api/v1/swagger/#/Authentication/post_api_v1_auth_token
How you can get this work?
Thank you
have you tried with version 0.10.0?
As long as the version is < 1 it incompatible changes in the API may happen.
I might find the time to release a v0.12.0 compatible version so you do not need to downgrade your traduora web service
Please try traduora-cli@0.12.0 @Jekiwijaya
I test, and make a pull request for small changes in response.
Thank you for your response 🙇 This is really useful, previously I use poeditor for continuous translation management, and when I moved using traduora, this CLI is really helpful.
Hey @Jekiwijaya please upgrade traduora to 0.12.0 and use the traduora-cli@0.12.0 or wait for the next release of traduora and the cli.
Once my pr version verification mechanism gets merged I can add a step in the cli that ensures versions are compatible.
Please also keep in mind, both traduora and the cli projects are not yet adhering to true semver, as long as the first digit is zero breaking changes may happen