New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Endpoints for translation #8

Closed
Mte90 opened this Issue Nov 3, 2018 · 7 comments

Comments

Projects
None yet
2 participants
@Mte90
Copy link

Mte90 commented Nov 3, 2018

As ClassicPress/ClassicPress#183 we need to add the translation endpoint.
The original code of wordpress for that is at https://meta.svn.wordpress.org/sites/trunk/api.wordpress.org/public_html/translations/

I am looking on that

@Mte90

This comment has been minimized.

Copy link
Author

Mte90 commented Nov 3, 2018

I am studying the wp core but they use wp as framework also to do query to the db and generate the locales list and put that in cache.
also they point to the various zip packages for the locale and version.
So I don't know where this endpoints are placed but we can do rest request to our GP instance and generate what we need as static json.
I am looking also other porjects like https://github.com/Automattic/wc-lang-packs-server to see how to do at the best.

@Mte90

This comment has been minimized.

Copy link
Author

Mte90 commented Nov 3, 2018

Another option if the endpoint are not accessing to the db is put the code for them on the translate.cp instance with a plugin that will generate this endpoint.

@Mte90

This comment has been minimized.

Copy link
Author

Mte90 commented Nov 3, 2018

Maybe the best solution is to do a wpcli plugin that generate the json for the endpoint translations and that during that process generate the various zip package for all the locales.
In that way we can avoid to do develop plugins for GP for the various endpoints and reuse the code of WP.org.

@nylen

This comment has been minimized.

Copy link
Member

nylen commented Nov 4, 2018

Our update API and GlotPress are on separate servers so we won't be able to get this directly from the db.

I think a WP-CLI script to generate the needed files is a good idea. We can run it every night and make the files publicly available.

@Mte90

This comment has been minimized.

Copy link
Author

Mte90 commented Nov 20, 2018

ClassicPress/ClassicPress-Network#19, this generate a json file but we need to define few things before to release and test it.

@Mte90

This comment has been minimized.

Copy link
Author

Mte90 commented Dec 17, 2018

We are working to get a better endpoint with the domain.

@nylen

This comment has been minimized.

@nylen nylen closed this Dec 18, 2018

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment