inblockio / mediawiki-extensions-Aqua

This MediaWiki extension includes the Aqua implementation. Turning MediaWiki into a powerful versioned notary service with API's for import and export of Data in JSON format.
GNU General Public License v3.0
7 stars 6 forks source link

Add API endpoint to get recent changes #403

Closed it-spiderman closed 3 months ago

it-spiderman commented 3 months ago

Normal API is updated deferred and also doesnt work well for Imported pages

https://github.com/inblockio/mediawiki-extensions-Aqua/issues/401

Issue: normal recent changes endpoint does return imported pages, buut, those revisions will have timestamp or the original revision, ie. not the timestamp of import, but of original creation. We cannot change this, as timestamp is included in hash. Also, it is update on deferred updates, so page will take some time to appear on RC after change.

Use the new API that is specifically done for your use-case. Its updated immediately and will show time of the import as the "last change" timestamp (without affecting original revision timestamp)

See updated API docu for more info: /data_accounting/recent_changes

it-spiderman commented 3 months ago

CI failures will be fixed with https://github.com/inblockio/mediawiki-extensions-Aqua/pull/402

FantasticoFox commented 3 months ago

Can you please provide an example how to use the timestamp? Format is descripted in the API but not clear how the parameter is provided as an input for the endpoint.

I assume it works with ?since= &count =

FantasticoFox commented 3 months ago

We require that deleted revisions are shown by the API. We require the funcitonality so we can see deletion events to update Guardian state. This can be provided by this API.

This could also be done by extending the query arguments with another Argument

When not providing any query arguments, it should not show deletion events when showing all pages (latests) without any query input.

it-spiderman commented 3 months ago

Usage is described in the API docu. To use timestamp, specify since=20240101000000 (YmdHis), same format as timestamp that is returned in the items of the API response

FantasticoFox commented 3 months ago

I'll close and merge this one and move our comment into the old specification issue https://github.com/inblockio/mediawiki-extensions-Aqua/issues/383