reconciliation-api / testbench

Web application to try out reconciliation services interactively
https://reconciliation-api.github.io/testbench/
MIT License
12 stars 6 forks source link

add "varies by" (language, jurisdiction) to testbench #19

Open VladimirAlexiev opened 4 years ago

VladimirAlexiev commented 4 years ago

(related to reconciliation-api/specs#52 and reconciliation-api/specs#55)

https://reconciliation-api.github.io/testbench/ shows lang-specific URLs for the first two services.

Wikidata
  API endpoint: https://wikidata.reconci.link/en/api
    protocol: OpenRefine reconciliation service API
    described at URL: https://wikidata.reconci.link/
    source code repository: https://github.com/wetneb/openrefine-wikibase
    language of work or name: English

How to indicate endpoint URL variation by a fixed param? I imagine it as an extra column Varies By in the table.

How to express this in Wikidata? URL templates are called formatters in WD. I looked at available props, and maybe https://www.wikidata.org/wiki/Property:P8183 is what we need. The data needs to be restructured as follows:

Wikidata
  online service (P2361): Wikidata OpenRefine reconciliation service
Wikidata OpenRefine reconciliation service
  protocol: OpenRefine reconciliation service API
  # API endpoint: no language-independent endpoint
  general property-based URL formatter (P8183): https://wikidata.reconci.link/{P407}/api # language of work
  described at URL: https://wikidata.reconci.link/
  source code repository: https://github.com/wetneb/openrefine-wikibase

OpenCorporates
  online service (P2361): OpenCorporates OpenRefine reconciliation service
OpenCorporates OpenRefine reconciliation service
  protocol: OpenRefine reconciliation service API
  API endpoint: https://opencorporates.com/reconcile # ALL jurisdictions
  general property-based URL formatter (P8183): https://opencorporates.com/reconcile/{P1001} # applies to jurisdiction
  described at URL: https://api.opencorporates.com/documentation/Open-Refine-Reconciliation-API
wetneb commented 4 years ago

If reconciliation-api/specs#55 makes it way to the specs, then I'd leave the modeling on Wikidata as it is. If the accepted parameters are exposed by the service manifests directly, then we should not need a redundant modeling on Wikidata's side. The testbench could potentially be adapted to display these variants after fetching the manifests (and let users fill particular values for them when testing the endpoint interactively).

Moving this issue to the testbench repository (let's see if links to issues are preserved). Edit: it seems to have worked great!

tfmorris commented 4 years ago

The "gazillion" URLs represent a usability problem, so I think effort would be better spent on fixing it, rather than accommodating it.