diff --git a/content/posts/2018-10.md b/content/posts/2018-10.md index e38f9f663..460fbf6a8 100644 --- a/content/posts/2018-10.md +++ b/content/posts/2018-10.md @@ -518,5 +518,28 @@ UPDATE 76608 - Improve the usage rights (dc.rights) on CGSpace again by adding the long names in the submission form, as well as adding versio 3.0 and Creative Commons Zero (CC0) public domain license ([#399](https://github.com/ilri/DSpace/pull/399)) - Add "usage rights" to the XMLUI item display ([#400](https://github.com/ilri/DSpace/pull/400)) +- I emailed the MARLO guys to ask if they can send us a dump of rights data and Handles from their system so we can tag our older items on CGSpace +- Testing REST login and logout via httpie because Felix from Earlham says he's having issues: + +``` +$ http --print b POST 'https://dspacetest.cgiar.org/rest/login' email='testdeposit@cgiar.org' password=deposit +acef8a4a-41f3-4392-b870-e873790f696b + +$ http POST 'https://dspacetest.cgiar.org/rest/logout' rest-dspace-token:acef8a4a-41f3-4392-b870-e873790f696b +``` + +- Also works via curl (login, check status, logout, check status): + +``` +$ curl -H "Content-Type: application/json" --data '{"email":"testdeposit@cgiar.org", "password":"deposit"}' https://dspacetest.cgiar.org/rest/login +e09fb5e1-72b0-4811-a2e5-5c1cd78293cc +$ curl -X GET -H "Content-Type: application/json" -H "Accept: application/json" -H "rest-dspace-token: e09fb5e1-72b0-4811-a2e5-5c1cd78293cc" https://dspacetest.cgiar.org/rest/status +{"okay":true,"authenticated":true,"email":"testdeposit@cgiar.org","fullname":"Test deposit","token":"e09fb5e1-72b0-4811-a2e5-5c1cd78293cc"} +$ curl -X POST -H "Content-Type: application/json" -H "rest-dspace-token: e09fb5e1-72b0-4811-a2e5-5c1cd78293cc" https://dspacetest.cgiar.org/rest/logout +$ curl -X GET -H "Content-Type: application/json" -H "Accept: application/json" -H "rest-dspace-token: e09fb5e1-72b0-4811-a2e5-5c1cd78293cc" https://dspacetest.cgiar.org/rest/status +{"okay":true,"authenticated":false,"email":null,"fullname":null,"token":null}% +``` + +- Improve the documentatin of my [dspace-statistics-api](https://github.com/alanorth/dspace-statistics-api) diff --git a/docs/2018-10/index.html b/docs/2018-10/index.html index 7a8a52fae..3a1af5b3f 100644 --- a/docs/2018-10/index.html +++ b/docs/2018-10/index.html @@ -9,7 +9,7 @@ - + @@ -24,9 +24,9 @@ "@type": "BlogPosting", "headline": "October, 2018", "url": "https://alanorth.github.io/cgspace-notes/2018-10/", - "wordCount": "3794", + "wordCount": "3922", "datePublished": "2018-10-01T22:31:54+03:00", - "dateModified": "2018-10-22T18:02:19+03:00", + "dateModified": "2018-10-23T11:29:17+03:00", "author": { "@type": "Person", "name": "Alan Orth" @@ -682,6 +682,31 @@ UPDATE 76608
$ http --print b POST 'https://dspacetest.cgiar.org/rest/login' email='testdeposit@cgiar.org' password=deposit
+acef8a4a-41f3-4392-b870-e873790f696b
+
+$ http POST 'https://dspacetest.cgiar.org/rest/logout' rest-dspace-token:acef8a4a-41f3-4392-b870-e873790f696b
+
+
+$ curl -H "Content-Type: application/json" --data '{"email":"testdeposit@cgiar.org", "password":"deposit"}' https://dspacetest.cgiar.org/rest/login
+e09fb5e1-72b0-4811-a2e5-5c1cd78293cc
+$ curl -X GET -H "Content-Type: application/json" -H "Accept: application/json" -H "rest-dspace-token: e09fb5e1-72b0-4811-a2e5-5c1cd78293cc" https://dspacetest.cgiar.org/rest/status
+{"okay":true,"authenticated":true,"email":"testdeposit@cgiar.org","fullname":"Test deposit","token":"e09fb5e1-72b0-4811-a2e5-5c1cd78293cc"}
+$ curl -X POST -H "Content-Type: application/json" -H "rest-dspace-token: e09fb5e1-72b0-4811-a2e5-5c1cd78293cc" https://dspacetest.cgiar.org/rest/logout
+$ curl -X GET -H "Content-Type: application/json" -H "Accept: application/json" -H "rest-dspace-token: e09fb5e1-72b0-4811-a2e5-5c1cd78293cc" https://dspacetest.cgiar.org/rest/status
+{"okay":true,"authenticated":false,"email":null,"fullname":null,"token":null}%
+
+
+