Skip to content
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

mwoffliner api calls #2018

Open
tim-moody opened this issue Apr 17, 2024 · 4 comments
Open

mwoffliner api calls #2018

tim-moody opened this issue Apr 17, 2024 · 4 comments
Assignees
Labels
Milestone

Comments

@tim-moody
Copy link
Contributor

https://github.com/openzim/mwoffliner/wiki/API-end%E2%80%90points lists 5 endpoints, 3 for mediawiki including VisualEditor and ActionParse currently implemented, and RestApi, which I believe is new to the current dev version.

VisualEditor and ActionParse are really both the same api, just with different parameters, and are both normally used when the target is mediawiki in my experience.

https://github.com/openzim/mwoffliner/wiki/Frequently-Asked-Questions mentions the runtime parameter --forceRender as a means of choosing an api. This parameter is also described in https://github.com/openzim/mwoffliner/blob/main/src/parameterList.ts, which gives 3 values allowed: VisualEditor, WikimediaDesktop, and WikimediaMobile. (This file supplies the help for mwoffliner I believe.)

So my question is, can I use --forceRender to cause the RestApi to be used and if so what value should I use? The obvious answer would be RestApi (or restapi as the others are all lowercase), but I didn't find this in the code and when I tried it I still got the action api.

@kelson42 kelson42 self-assigned this Apr 17, 2024
@kelson42
Copy link
Collaborator

@tim-moody Have you tried the --help option?

@tim-moody
Copy link
Contributor Author

--help prints the contents of https://github.com/openzim/mwoffliner/blob/main/src/parameterList.ts cited above.

@kelson42
Copy link
Collaborator

Yes, and you have the list of accepted value of --forcerender

@kelson42 kelson42 changed the title mwoffline api calls mwoffliner api calls Apr 18, 2024
@tim-moody
Copy link
Contributor Author

True, and restapi is not among them, which I took to be an error. So if the --help is accurate and there is no value of --forcerender to cause mwoffliner use restapi, under what circumstances does mwoffliner use the restapi and is there any way to force it to do so?

@kelson42 kelson42 added this to the 1.14.0 milestone May 7, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants