Closed nschonni closed 4 years ago
Hmm. The URL looks right on the surface: https://support.crowdin.com/api/upload-glossary/
cc @crowdin-support any idea what might be wrong here?
Hi @nschonni and @zeke! Trying to reproduce on my machine via Postman. You may try uploading the glossary via JS client built on top of our API v2: https://github.com/crowdin/crowdin-api-client-js
Also, can you please let us know what is the extension of glossary file? Is it .tbx, .xlsx or .csv?
It's JSON in the repo, but is built up and pushed through https://github.com/nodejs/i18n/blob/master/script/upload-crowdin-glossary.js
Thanks! JSON is not converted to .tbx, .xlsx or .csv as I understand? Unfortunately, it cannot be accepted. There is "json" parameter described in docs but it's used only for purpose of receiving responses in JSON: https://support.crowdin.com/api/upload-glossary/
Would it be possible to switch to any file type mentioned above? My colleague has managed to upload .tbx but I'd recommend CSV - it's easier to edit :)
Hey @Andrulko 👋 Long time no see.
The underlying crowdin-glossary
node module is already converting the JS / JSON input into CSV here: https://github.com/crowdin-node/crowdin-glossary/blob/f9cd09f204fb9b028260ec2c616e631f8ba9fe54/index.js#L40-L45
We've used this module before to successfully upload glossary data, and the implementation hasn't changed in some time. Is it possible that this Crowdin v1 API has changed in some way?
Hello @zeke
Hope, you're doing well!
I'm not sure whether we changed something on our side, but let me re-check with developers and get back to you
Hi @zeke and @nschonni!
Coming back with additional news on the matter:
As tech guys informed, we don't change API v1 in any way, changes could be only on API v2, because we're working on it
Concerning your 404 Error:
We've just checked on our database and can see that you used wrong API key, from the last time API Key was changed, that's why you've got 404 messages
Kindly compare your current API key and last API log: https://crowdin.com/project/nodejs/settings#api
What I can recommend also (it's not necessary to do) : You may provide manager access to the NodeJS project for user who works with API and then you he/she will be able to use this request:
Instead of that one: https://api.crowdin.com/api/project/{project-identifier}/upload-glossary?key={project-key}
Take care,
Thanks for the guidance @denisqua ✨
I just:
CROWDIN_KEY
secret from this repoCROWDIN_KEY
secretLet's see if that resolves the issue.
@zeke does it working now?
I don't think it has run since this change was made. Here's the last run from 8 days ago: https://github.com/nodejs/i18n/actions/runs/65243014
Here's what triggers the workflow: https://github.com/nodejs/i18n/blob/4e18ed81a8d71ba0ee0f2aa5e8c788aec6068cba/.github/workflows/glossary.yml#L3-L12
Anyone should be able to test this by opening (and merging) a PR that adds or updates a glossary entry.
Works now https://github.com/nodejs/i18n/actions/runs/71474551 Thanks for investigation!
Nice 🙌
It's running now, but silently failing for a different reason :( https://github.com/nodejs/i18n/runs/540255470?check_suite_focus=true
Originally posted by @nschonni in https://github.com/nodejs/i18n/pull/254#issuecomment-605212737