-
Notifications
You must be signed in to change notification settings - Fork 536
Feature Request: API to support Download Terms of Use and Guestbook #12110
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
stevenwinship
wants to merge
47
commits into
develop
Choose a base branch
from
12001-api-support-termofuse-guestbook
base: develop
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
+2,246
−515
Open
Changes from all commits
Commits
Show all changes
47 commits
Select commit
Hold shift + click to select a range
eb64cde
initial guestbook apis
stevenwinship 1c93ba6
Merge branch 'develop' into 12001-api-support-termofuse-guestbook
stevenwinship 789ed94
Merge branch 'develop' into 12001-api-support-termofuse-guestbook
stevenwinship 7113b48
Merge branch 'develop' into 12001-api-support-termofuse-guestbook
stevenwinship 38d67d4
adding guestbook response
stevenwinship 1a1fead
validating response
stevenwinship 6d16aae
validating response
stevenwinship 411befd
Potential fix for code scanning alert no. 354: Information exposure t…
stevenwinship 4833dd8
Potential fix for code scanning alert no. 355: Information exposure t…
stevenwinship bbea198
Potential fix for code scanning alert no. 356: Information exposure t…
stevenwinship 2e9dd37
Merge branch 'develop' into 12001-api-support-termofuse-guestbook
stevenwinship 1a73f06
code cleanup
stevenwinship b52b856
add -Ddataverse.files.guestbook-at-request=true for testing
stevenwinship 6bbda52
fix test
stevenwinship 969536a
Merge branch 'develop' into 12001-api-support-termofuse-guestbook
stevenwinship 2b9c718
Merge branch 'develop' into 12001-api-support-termofuse-guestbook
stevenwinship b73b21e
Merge branch 'develop' into 12001-api-support-termofuse-guestbook
stevenwinship a630c9c
adding post for download datafile with guestbook response
stevenwinship 9d68d33
fix
stevenwinship 79c3eaa
add release note
stevenwinship b089324
new api and updated docs
stevenwinship 7ab9c0a
updated docs
stevenwinship b6ec2ea
Merge branch 'develop' into 12001-api-support-termofuse-guestbook
stevenwinship 13396f1
Merge branch 'develop' into 12001-api-support-termofuse-guestbook
stevenwinship 6604ce5
Merge branch 'develop' into 12001-api-support-termofuse-guestbook
stevenwinship edf0a6e
refactor and add gb response checks to all download apis
stevenwinship e7bf66c
fix accessIT test
stevenwinship f47d9f6
Merge branch 'develop' into 12001-api-support-termofuse-guestbook
stevenwinship 7c71e99
fix to zipper manifest to add NOT Authorized files
stevenwinship 3466d4e
update docs
stevenwinship e3da730
Merge branch 'develop' into 12001-api-support-termofuse-guestbook
stevenwinship f9f2a21
Merge branch 'develop' into 12001-api-support-termofuse-guestbook
stevenwinship 2dd0034
Merge branch 'develop' into 12001-api-support-termofuse-guestbook
stevenwinship 649d7c5
Merge branch 'develop' into 12001-api-support-termofuse-guestbook
stevenwinship 51facb9
Merge branch 'develop' into 12001-api-support-termofuse-guestbook
stevenwinship 04e23a5
Merge branch 'develop' into 12001-api-support-termofuse-guestbook
stevenwinship ad22235
adding signed param to GET endpoints
stevenwinship 2c5985d
Merge branch 'develop' into 12001-api-support-termofuse-guestbook
stevenwinship cedd4c2
add overwrite to name, email, institution, and position in guestbook …
stevenwinship 917b3fa
Merge branch 'develop' into 12001-api-support-termofuse-guestbook
stevenwinship dc9f8bc
fix doc
stevenwinship d6aa29a
fix doc
stevenwinship 72fce96
add email validation
stevenwinship cf2937b
add email validation
stevenwinship 2c6d86d
Merge branch 'develop' into 12001-api-support-termofuse-guestbook
stevenwinship a9985d3
Merge branch 'develop' into 12001-api-support-termofuse-guestbook
stevenwinship a0ffae9
Merge branch 'develop' into 12001-api-support-termofuse-guestbook
stevenwinship File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
29 changes: 29 additions & 0 deletions
29
doc/release-notes/12001-api-support-termofuse-guestbook.md
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,29 @@ | ||
| ## Feature Request: API to support Download Terms of Use and Guestbook | ||
|
|
||
| ## New Endpoints to download a file or files that required a Guestbook Response: POST | ||
| A post to these endpoints with the body containing a JSON Guestbook Response will save the response and | ||
| `?signed=true`: return a signed URL to download the file(s) or | ||
| `?signed=false` or missing: Write the Guestbook Responses and download the file(s) | ||
|
|
||
| `/api/access/datafile/{fileId:.+}` | ||
| `/api/access/datafiles/{fileIds}` | ||
| `/api/access/dataset/{id}` | ||
| `/api/access/dataset/{id}/versions/{versionId}` | ||
|
|
||
| The matching GET APIs will also take the `?signed=true` parameter to also return the signed url instead of downloading immediately. Note: Signed urls are only for Authenticated Users. Guest users will receive an error if requesting with signed=true | ||
|
|
||
| A post to these endpoints with the body containing a JSON Guestbook Response will save the response before continuing the download. | ||
| No signed URL option exists. | ||
| `/api/access/datafiles` | ||
| `/api/access/datafile/bundle/{fileId}` POST returns BundleDownloadInstance after processing Guestbook Responses from body. | ||
|
|
||
| ## New CRUD Endpoints for Guestbook: | ||
| Create a Guestbook: POST `/api/guestbooks/{dataverseIdentifier}` | ||
| Get a Guestbook: GET `/api/guestbooks/{id}` | ||
| Get a list of Guestbooks linked to a Dataverse Collection: GET `/api/guestbooks/{dataverseIdentifier}/list` | ||
| Enable/Disable a Guestbook: PUT `/api/guestbooks/{dataverseIdentifier}/{id}/enabled` Body: `true` or `false` | ||
| Note: There is no Update or Delete at this time. You can disable a Guestbook and create a new one. | ||
|
|
||
| ## For Guestbook At Request: | ||
| When JVM setting -Ddataverse.files.guestbook-at-request=true is used a request for access may require a Guestbook Response. | ||
| PUT `/api/access/datafile/{id}/requestAccess` will now take a JSON Guestbook Response in the body. | ||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,17 @@ | ||
| {"guestbookResponse": { | ||
| "answers": [ | ||
| { | ||
| "id": @QID1, | ||
| "value": "Good" | ||
| }, | ||
| { | ||
| "id": @QID2, | ||
| "value": ["Multi","Line"] | ||
| }, | ||
| { | ||
| "id": @QID3, | ||
| "value": "Yellow" | ||
| } | ||
| ] | ||
| } | ||
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,49 @@ | ||
| { | ||
| "name": "my test guestbook", | ||
| "enabled": true, | ||
| "emailRequired": true, | ||
| "nameRequired": true, | ||
| "institutionRequired": false, | ||
| "positionRequired": false, | ||
| "customQuestions": [ | ||
| { | ||
| "question": "how's your day", | ||
| "required": true, | ||
| "displayOrder": 0, | ||
| "type": "text", | ||
| "hidden": false | ||
| }, | ||
| { | ||
| "question": "Describe yourself", | ||
| "required": false, | ||
| "displayOrder": 1, | ||
| "type": "textarea", | ||
| "hidden": false | ||
| }, | ||
| { | ||
| "question": "What color car do you drive", | ||
| "required": true, | ||
| "displayOrder": 2, | ||
| "type": "options", | ||
| "hidden": false, | ||
| "optionValues": [ | ||
| { | ||
| "value": "Red", | ||
| "displayOrder": 0 | ||
| }, | ||
| { | ||
| "value": "White", | ||
| "displayOrder": 1 | ||
| }, | ||
| { | ||
| "value": "Yellow", | ||
| "displayOrder": 2 | ||
| }, | ||
| { | ||
| "value": "Purple", | ||
| "displayOrder": 3 | ||
| } | ||
| ] | ||
| } | ||
| ] | ||
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.