# README # ### What is this repository for? ### PIDMR resolver parser service Gets a PID, makes a request to PIDMR service, and given the response parses it to a json object if there is a parser available for the given endpoint. * Version 1.0.0 # Node.js Service ## Requirements - [Node.js](https://nodejs.org/) (v16+ recommended) - [npm](https://www.npmjs.com/) --- ## Installation Install dependencies: npm install Start the server: npm start #GET /:pid Gets the PID, makes a request to PIDMR service, and given the response parses it to a json object if there is a parser available for the given endpoint. pid Should be url encoded. Example Request: curl http://localhost:4001/10.5524%2F100005 Response: 200 OK: A json Object {"id":"10.5524/100005","type":"dataset","title":"Genomic data from the Emperor penguin (Aptenodytes forsteri)","result":{"accessRights":"OPEN","embargoEndDate":"","authors":["Li, J","Zhang, G","Lambert, D","Wang, J"],"editors":[],"source":"datacite","publisher":"GigaScience","journal":null,"DOI":"10.5524/100005","url":"https://doi.org/10.5524/100005","date":2011}} #GET /supported-endpoints Retrieve a list of all available endpoints that can be parsed. Example Request: curl http://localhost:4001/supported-endpoints Response: 200 OK: An array of supported endpoints. ["api.crossref.org","api.datacite.org","zenodo.org"] ### How to run locally? ### * "npm i" to install dependencies. * "npm start" to start the service