Allow auth_service to be array of hashes, allow override of top level context#120
Open
masaball wants to merge 2 commits into
Open
Allow auth_service to be array of hashes, allow override of top level context#120masaball wants to merge 2 commits into
masaball wants to merge 2 commits into
Conversation
Avalon is working on updating their IIIF auth servicve to 2.0 which requires adding a value to the top level context. This commit adds the ability to override the default context by defining a `context` method on the manifest presenter and passing an array of values. Additionally, this commit changes the behavior of the `auth_service` so that implementers can pass in an array of hashes. This is to facilitate any implementations that may want to have Auth 1 and Auth 2 services defined, or adding additional auth services if and when the IIIF community defines additional versions.
7042bda to
f916227
Compare
cjcolvar
reviewed
Jun 15, 2026
cjcolvar
left a comment
Member
There was a problem hiding this comment.
What do you think about instead of allowing auth_service to be an array of hashes adding an auth2_service method on the record (so there could be both an auth_service and auth2_service)? Then it would be easy to automatically add the additional context at the top level (and not have to open up the top-level context to anything the record sends).
| ] | ||
| end | ||
|
|
||
| it '' do |
Member
There was a problem hiding this comment.
Suggested change
| it '' do | |
| it 'creates an array of services' do |
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Avalon is working on updating their IIIF auth service to 2.0 which requires adding a value to the top level context. This commit adds the ability to override the default context in V3 manifests by defining a
contextmethod on the manifest presenter and passing an array of values.Additionally, this commit changes the behavior of the
auth_serviceso that implementers can pass in an array of hashes. This is to facilitate any implementations that may want to have Auth 1 and Auth 2 services defined, or adding additional auth services if and when the IIIF community defines additional versions.