한국   대만   중국   일본 
? T352294 Implement "interface version" of REST API
Page Menu Home Phabricator

Implement "interface version" of REST API
Closed, Resolved Public 5 Estimated Story Points

Description

For users of the Wikibase REST API to be aware of what functionality is available across the different iterations, we will implement an interface version of the API.

Acceptance criteria:

  • Available at "/rest.php/wikibase/v[0]/openapi.json" is the OpenAPI document which incl. { "info" : { "version" : "0.1" } }

Notes:

  • Once considered stable (1.0.0) the interface will be versioned following semantic versioning.
  • This version of the schema document will be used to reflect non-breaking and breaking changes accordingly [TBD what this means]

Task breakdown :

  • adjust our npm build:spec script to copy the openapi.json to the new location
  • CI test that checks the built OpenAPI document against the source files
  • create route handler that reads the built openapi.json file and returns it with the response

Event Timeline

Change 999691 had a related patch set uploaded (by Silvan Heintze; author: Silvan Heintze):

[mediawiki/extensions/Wikibase@master] [DNM] REST: First attempt on T352294

https://gerrit.wikimedia.org/r/999691

Change 1002454 had a related patch set uploaded (by Silvan Heintze; author: Silvan Heintze):

[mediawiki/extensions/Wikibase@master] REST: Add route to serve OpenAPI doc

https://gerrit.wikimedia.org/r/1002454

Change 999691 abandoned by Silvan Heintze:

[mediawiki/extensions/Wikibase@master] [DNM] REST: First attempt on T352294

Reason:

done in I715b866b37f2c7c8a8a4c7875716d60e85d50452

https://gerrit.wikimedia.org/r/999691

Change 1002454 merged by jenkins-bot:

[mediawiki/extensions/Wikibase@master] REST: Add route to serve OpenAPI doc

https://gerrit.wikimedia.org/r/1002454