hubzero / hubzero-cms

Platform for Scientific Collaboration
https://hubzero.org
GNU General Public License v2.0
47 stars 57 forks source link

[PURR][#2545]Add publication to author's ORCID record #1725

Closed kuang5 closed 1 month ago

kuang5 commented 1 month ago

Add published dataset to author's ORCID record PURR ticket #255: https://purr.purdue.edu/support/ticket/2545

Publications are scholar works that can be added to the author's ORCID record, when the authors have granted the ORCID management permission to hub instance, such as PURR. The code changes implement the functions below, utilizing ORCID API: https://info.orcid.org/documentation/api-tutorials/api-tutorial-add-and-update-data-on-an-orcid-record/.

Please find GIF files in PURR ticket #2545 that demonstrates the functions below:

  1. Hub users grant ORCID managment permission. An button for granting permission is added in ORCID section in user profile. Hub user clicks on the button and follow the prompt to complete the process. It is successful as long as seeing "You have granted ORCID management permission" in the account profile. Please see demo "1. Grant_ORCID_Management_Permission_By_PURR_User.gif".

  2. Add publication to ORCID record. A publication is going to be added to the author's ORCID record when the publication is approved and the author has granted ORCID management to PURR. Please see "2. Publish_dataset_to_add_it_to_ORCID_record.gif".

  3. Collaborators grant ORCID management permission. Some authors are not PURR users, so such type of authors are not able to grant ORCID management permission in the PURR account. When the dataset is published, an email including the granting permission link will be sent to collaborator's email address. The collaborator granted permission through the link in the received email. Please see "3. Collaborator_received_email_and_granted_permission.gif".

  4. Update the publication in ORCID record. The publication in ORCID record is going to be updated whenever the publication is updated through admin interface on PURR. The "4. Updating_the_publication_in_ORCID_Record.gif" shows the operations that the publication's information on my ORCID is updated after author, title, synopsis are all updated on PURR through admin interface. In the gif, you can also see that the publication is added to collaborator's ORCID record after the update operation because the author granted permission before I update the dataset.

  5. Delete the publication from ORCID record. The "5. Delete_publication_from_ORCID_record.gif" shows that the publication is deleted from the author's ORCID record when I unpublish the dataset on PURR.

The code changes include:

  1. Register the permission URL with ORCID support, so that the ORCID server can redirect back to hub such as PURR after user authorizes ORCID management permission to the hub.
  2. Save the ORCID ID and access token which are sent back from ORCID server in PURR users profile.
  3. Call the ORCID API to add the publication to the author's ORCID record when publication is approved and the author has granted ORCID management permission.
  4. Send email which includes a link for granting ORCID management permission to the collaborator's email address.
  5. Save the collaborator's name, ORCID ID, access token, and authrization data in #__publication_collaborator table.
  6. Call the ORCID API to update the publication in author's ORCID record.
  7. Call the ORCID API to delete the publication from author's ORCID record when dataset is unpublished on hub/PURR.

The functions were tested on dev PURR and they work as expected.

No hotfix needed.