DAP (Conversions)
Current | Proposed | Description | Notes | ||
---|---|---|---|---|---|
GET | /outputs | GET | /api/conversions/outputs | List all output formats that can be reached | |
GET | /inputs | GET | /api/conversions/inputs | List all input formats that can be accepted | |
GET | /inputs/{input format} | GET | /api/conversions/inputs/{input format} | List all output formats that can reach the specified input format | |
GET | /convert | - | - | ||
GET | /convert/{output format} | GET | /api/conversions/outputs/{output format} | List all input formats that can reach the specified output format | |
GET | /convert/{output format}/{file url} | GET | /api/conversions/convert/{output format}/{file URL} | Convert the specified file to the requested output format | Move towards returning an ID like Clowder? |
POST | /convert/{output format} | POST | /api/conversions/convert/{output format} | Convert the uploaded file to the requested output format | Move towards returning an ID like Clowder? |
GET | /software | GET | /api/conversions/software | List all available conversion software | |
GET | /servers | GET | /api/conversions/servers | List all currently available Software Servers |
DTS (Extractions)
Current | Proposed | Description | Notes | ||
---|---|---|---|---|---|
GET | /api/extractions/supported_input_types | GET | /api/extractions/inputs | Lists the input file format supported by currently running extractors | |
POST | /api/extractions/upload_file | POST | /api/extractions/file | Uploads a file for extraction of metadata and returns file id | Means of specifying a space (to trigger a subset of extractors)? Allow URLs to be parsed from the URL aswell, e.g. ?url=http.... |
POST | /api/extractions/upload_url | POST | /api/extractions/url | Uploads a file for extraction using the file's URL | |
GET | /api/extractions/{id}/status | GET | /api/extractions/status?file_id={id} | Checks for the status of all extractors processing the file with id | |
GET | /api/files/{id}/tags | GET | /api/files/{id}/metadata /api/files/{id}/metadata.jsonld
| Gets tags of a file | Merge into one and use new JSON-LD output. Tags are still stored separate. |
GET | /api/files/{id}/technicalmetadata | Get technical metadata of the resource described by the file | |||
GET | /api/files/{id}/versusmetadata | Get Versus metadata of the resource described by the file | |||
GET | /api/extractions/server_ips | GET | /api/extractions/servers | Lists servers IPs running the extractors | |
GET | /api/extractions/extractors_names | GET | /api/extractions/extractors | Lists the currently running extractors | |
GET | /api/extractions/extractors_details | GET | /api/extractions/extractors/details | Lists the currently running extractors details | |
POST | /api/extractions | Run a specific extractor. Example body: { "extractor" : "ncsa.dbpedia", "file_id" : "55c4d42dd4c6289bb88e6894", "parameters" : { "treshold" : "1", "foo" : "bar" } } | Would like to add a version of this endpoint that takes an uploaded file or URL, perhaps like this?: /api/extractions/ncsa.dbpedia/file, /api/extractions/ncsa.dbpedia/url |
DTS (Developers)
Current | Proposed | Description Notes | |||
---|---|---|---|---|---|
POST | /api/extractors | Register new extractor information | |||
GET | /api/extractors/{id} | Get extractor {id} information | Change {id} to extractor name? | ||
GET | /api/extractors | Get information for all extractors | Add pagination?
|
1 Comment
Luigi Marini
According to many sources on the interwebs (including the one below–-note the other source it links to at the bottom as well) putting the api version in the URI is a bad idea because the URI are supposed to not change over time. One of the accepted ways to do versioning is to add a header to the request with the version requested. If the server has moved to a different version it returns a 3xx. If the header is not specified it defaults to the latest. How to specify the header varies (standalone "accept-version" or wrapped into the media type. Either way, we don't have to add the version to our urls, but we need to pick up a strategy handle it in the body of the request.