Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions NEWS.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,10 @@

### Features
* Migrate Package Endpoints to HoldingsIQ v2 API ([MODKBEKBJ-804](https://folio-org.atlassian.net/browse/MODKBEKBJ-804))
* Migrate Title and Resource Endpoints to HoldingsIQ v2 API ([MODKBEKBJ-830](https://folio-org.atlassian.net/browse/MODKBEKBJ-830))
* Add filter[zdbid] and filter[access] to titles and package resources search ([MODKBEKBJ-834](https://folio-org.atlassian.net/browse/MODKBEKBJ-834))
* Add visibility per category, packageType, isPrimaryPackage and isOrderedThroughEbsco to resources ([MODKBEKBJ-831](https://folio-org.atlassian.net/browse/MODKBEKBJ-831))
* Support updating resource visibility per category (PF, FTF, MARC) with `visibility`, `visibilityData` remains as a fallback applied to all categories ([MODKBEKBJ-831](https://folio-org.atlassian.net/browse/MODKBEKBJ-831))
* Add additional fields to POST /eholdings/packages endpoint ([MODKBEKBJ-823](https://folio-org.atlassian.net/browse/MODKBEKBJ-823))
* Update visibility hidden reason handling ([MODKBEKBJ-823](https://folio-org.atlassian.net/browse/MODKBEKBJ-823))
* Remove HTML validation for package's custom display name field ([MODKBEKBJ-855](https://folio-org.atlassian.net/browse/MODKBEKBJ-855))
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,10 @@
"embargoValue": 7
},
"isPackageCustom": false,
"packageType": "Variable",
"isPrimaryPackage": false,
"isSelected": true,
"isOrderedThroughEbsco": false,
"isTokenNeeded": true,
"locationId": 17545807,
"managedEmbargoPeriod": {
Expand All @@ -71,6 +74,23 @@
"isHidden": true,
"reason": ""
},
"visibility": [
{
"category": "PF",
"hidden": true,
"reason": ""
},
{
"category": "FTF",
"hidden": true,
"reason": ""
},
{
"category": "MARC",
"hidden": true,
"reason": ""
}
],
"managedCoverages": [
{
"beginCoverage": "2010-01-01",
Expand Down
15 changes: 15 additions & 0 deletions ramls/examples/titles/titles_titleId_get_200_response.json
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,21 @@
"subject": "Social Services",
"type": "TLI"
}
],
"titleRelationships": [
{
"id": 42,
"type": "CONTINUED_BY",
"date": "2020-01-01T00:00:00Z",
"source": {
"titleId": 100130,
"name": "A call to action: Changing the culture of drinking at U.S. colleges"
},
"target": {
"titleId": 4444,
"name": "Continued Title"
}
}
]
},
"id": "100130",
Expand Down
12 changes: 6 additions & 6 deletions ramls/packages.raml
Original file line number Diff line number Diff line change
Expand Up @@ -10,14 +10,14 @@ documentation:
content: Implements the eholdings interface using EBSCO KB as backend.

traits:
queriable: !include traits/queriable.raml
packageQueriable: !include traits/packageQueriable.raml
queryable: !include traits/packagesQueryable.raml
sortable: !include traits/sortable.raml
pageable: !include traits/pageable.raml
packageFilterable: !include traits/packageFilterable.raml
packagesFilterable: !include traits/packagesFilterable.raml
taggable: !include traits/taggable.raml
accessible: !include traits/accessible.raml
packageResourcesFilterable: !include traits/packageResourcesFilterable.raml
resourcesQueryable: !include traits/resourcesQueryable.raml
resourcesFilterable: !include traits/resourcesFilterable.raml

types:
packageCollection: !include types/packages/packageCollection.json
Expand All @@ -35,7 +35,7 @@ types:
displayName: Packages
get:
description: Retrieve a collection of packages based on the search query.
is: [packageQueriable, packageFilterable, taggable, accessible,
is: [queryable, packagesFilterable, taggable, accessible,
sortable: {defaultValue: 'relevance', possibleValues: 'name, relevance'},
pageable: {maxCountValue: 100, defaultCountValue: 25}]
queryParameters:
Expand Down Expand Up @@ -237,7 +237,7 @@ types:
/resources:
get:
description: Include all resources belonging to a specific package
is: [taggable, accessible, packageResourcesFilterable,
is: [taggable, accessible, resourcesQueryable, resourcesFilterable,
sortable: {defaultValue: 'relevance', possibleValues: 'name, relevance'},
pageable: {maxCountValue: 100, defaultCountValue: 25}]
responses:
Expand Down
16 changes: 11 additions & 5 deletions ramls/providers.raml
Original file line number Diff line number Diff line change
Expand Up @@ -19,11 +19,10 @@ types:
jsonapiError: !include types/jsonapiError.json

traits:
queriable: !include traits/queriable.raml
sortable: !include traits/sortable.raml
pageable: !include traits/pageable.raml
packageFilterable: !include traits/packageFilterable.raml
packageQueriable: !include traits/packageQueriable.raml
packagesFilterable: !include traits/packagesFilterable.raml
packagesQueryable: !include traits/packagesQueryable.raml
taggable: !include traits/taggable.raml
accessible: !include traits/accessible.raml
includable: !include traits/includePackages.raml
Expand All @@ -33,9 +32,16 @@ traits:
description: Collection of available providers in eholdings.
get:
description: Get a list of providers based on the search query.
is: [queriable, taggable,
is: [taggable,
sortable: {defaultValue: 'relevance', possibleValues: 'name, relevance'},
pageable: {maxCountValue: 100, defaultCountValue: 25}]
queryParameters:
q:
displayName: Search query
type: string
description: String used to search to retrieve a collection
example: ABC-CLIO
required: false
responses:
200:
description: OK
Expand Down Expand Up @@ -129,7 +135,7 @@ traits:
/packages:
get:
description: Search within a list of packages associated with a given provider.
is: [packageQueriable, taggable, accessible, packageFilterable,
is: [packagesQueryable, taggable, accessible, packagesFilterable,
sortable: {defaultValue: 'relevance', possibleValues: 'name, relevance'},
pageable: {maxCountValue: 100, defaultCountValue: 25}]
queryParameters:
Expand Down
3 changes: 2 additions & 1 deletion ramls/resources.raml
Original file line number Diff line number Diff line change
Expand Up @@ -85,11 +85,12 @@ types:
displayName: Nested provider, package or title
type: string
description: |
Include provider, package or title in response
Comma-separated list of what to include in response
Possible values are
- provider
- package
- title
- relationships (title relationships in the resource attributes)
example: provider
required: false
responses:
Expand Down
3 changes: 2 additions & 1 deletion ramls/titles.raml
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ version: v1
mediaType: "application/vnd.api+json"

traits:
queryable: !include traits/titlesQueryable.raml
sortable: !include traits/sortable.raml
pageable: !include traits/pageable.raml
filterable: !include traits/titlesFilterable.raml
Expand All @@ -24,7 +25,7 @@ types:
description: Collection of available titles in eholdings.
get:
description: Get a set of titles matching the given search criteria.
is: [taggable, accessible, filterable, includable,
is: [queryable, taggable, accessible, filterable, includable,
sortable: {defaultValue: 'relevance', possibleValues: 'name, relevance'},
pageable: {maxCountValue: 100, defaultCountValue: 25}]
responses:
Expand Down
4 changes: 3 additions & 1 deletion ramls/traits/includeResources.raml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,9 @@ queryParameters:
displayName: Related Resources
type: string
description: |
Include related resource objects, each representing a partnering of this title with a package.
Comma-separated list of what to include:
`resources` - related resource objects, each representing a partnering of this title with a package;
`relationships` - title relationships (single title only).
Any bogus value, like `include=deciduousTrees`, will be silently ignored.
example: resources
required: false
7 changes: 0 additions & 7 deletions ramls/traits/queriable.raml

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,14 @@ queryParameters:
Filter to narrow down results based on content type.
Possible values are all, audiobook, book, bookseries, database, journal, newsletter, newspaper, proceedings, report, streamingaudio, streamingvideo,thesisdissertation, website, unspecified.
required: false
filter[access]:
displayName: Package access
type: string
description: |
Limits the results based on Package Free Access.
Possible values: public, controlled
example: public
required: false
filter[name]:
displayName: Query by Title Name
type: string
Expand All @@ -35,4 +43,4 @@ queryParameters:
type: string
description: String to search publishers to get a collection of titles
example: academic
required: false
required: false
18 changes: 18 additions & 0 deletions ramls/traits/resourcesQueryable.raml
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
queryParameters:
q:
displayName: Search query
type: string
description: String used to search to retrieve a collection
example: ABC-CLIO
required: false
q[field]:
displayName: Search field
type: string
description: |
Field to search.
name - Searches on Title Names.
publisher - Searches on Title Publishers.
subject - Searches on Title Subjects.
isxn - Searches on Title ISxNs.
zdbid - Searches on Title ZBD IDs.
default: name
8 changes: 8 additions & 0 deletions ramls/traits/titlesFilterable.raml
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,14 @@ queryParameters:
description: String to search publishers to get a collection of titles
example: academic
required: false
filter[access]:
displayName: Package access
type: string
description: |
Limits the results based on Package Free Access.
Possible values: public, controlled
example: public
required: false
filter[packageIds]:
displayName: Query by package Ids
type: string[]
Expand Down
23 changes: 23 additions & 0 deletions ramls/traits/titlesQueryable.raml
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
queryParameters:
q:
displayName: Search query
type: string
description: String used to search to retrieve a collection. Not needed when filter[tags] or filter[access-type] is used.
example: ABC-CLIO
q[field]:
displayName: Search field
type: string
description: |
Field to search.
name - Searches on Title Names.
publisher - Searches on Title Publishers.
subject - Searches on Title Subjects.
isxn - Searches on Title ISxNs.
zdbid - Searches on Title ZBD IDs.
default: name
q[type]:
displayName: Search type
type: string
description: |
Type of search to be performed.
Possible values: exactphrase, advanced, any, contains, exactmatch, beginswith, proximity
2 changes: 1 addition & 1 deletion ramls/types/packages/packageDataAttributes.json
Original file line number Diff line number Diff line change
Expand Up @@ -147,7 +147,7 @@
"visibility": {
"description": "Visibility details",
"items": {
"$ref": "packageVisibility.json",
"$ref": "../visibility.json",
"type": "object"
},
"type": "array"
Expand Down
2 changes: 1 addition & 1 deletion ramls/types/packages/packagePutDataAttributes.json
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@
"visibility": {
"description": "Visibility details",
"items": {
"$ref": "packageVisibility.json",
"$ref": "../visibility.json",
"type": "object"
},
"type": "array"
Expand Down
42 changes: 42 additions & 0 deletions ramls/types/resources/resourceDataAttributes.json
Original file line number Diff line number Diff line change
Expand Up @@ -99,11 +99,29 @@
"description": "Defines if package is custom",
"example": false
},
"packageType": {
"type": "string",
"readonly": true,
"description": "Package type",
"example": "Complete"
},
"isPrimaryPackage": {
"type": "boolean",
"readonly": true,
"description": "Defines if the package is the primary package of the provider",
"example": false
},
"isSelected": {
"type": "boolean",
"description": "Defines if this item is selected. Note that this attribute can be updated both for CUSTOM AND MANAGED RESOURCES.",
"example": false
},
"isOrderedThroughEbsco": {
"type": "boolean",
"readonly": true,
"description": "Defines if the resource is ordered through EBSCO",
"example": false
},
"titleHasSelectedResources": {
"type": "boolean",
"description": "Indicates if the title that contains this resource has selected resources",
Expand All @@ -115,6 +133,12 @@
"description": "Defines if token is needed",
"example": false
},
"customCoverageOwnership": {
"type": "string",
"readonly": true,
"description": "Custom coverage ownership of the resource",
"example": "customer"
},
"locationId": {
"type": "integer",
"readonly": true,
Expand Down Expand Up @@ -161,6 +185,15 @@
"description": "Visibility data. Note that this attribute can be updated both for CUSTOM AND MANAGED RESOURCES.",
"$ref": "../visibilityData.json"
},
"visibility": {
"type": "array",
"readonly": true,
"description": "Visibility per category (PF, FTF, MARC). visibilityData is hidden when at least one category is hidden",
"items": {
"type": "object",
"$ref": "../visibility.json"
}
},
"managedCoverages": {
"type": "array",
"readonly": true,
Expand Down Expand Up @@ -214,6 +247,15 @@
"type": "string",
"description": "User defined field 5",
"maxLength": 100
},
"titleRelationships": {
"type": "array",
"description": "Title relationships. Returned only when requested with include=relationships",
"items": {
"type": "object",
"$ref": "../titles/titleRelationship.json"
},
"readonly": true
}
}
}
10 changes: 9 additions & 1 deletion ramls/types/resources/resourcePutDataAttributes.json
Original file line number Diff line number Diff line change
Expand Up @@ -88,9 +88,17 @@
},
"visibilityData": {
"type": "object",
"description": "Visibility data. Note that this attribute can be updated both for CUSTOM AND MANAGED RESOURCES.",
"description": "Visibility data applied to all categories (PF, FTF, MARC). Ignored when visibility is set. Note that this attribute can be updated both for CUSTOM AND MANAGED RESOURCES.",
"$ref": "../visibilityData.json"
},
"visibility": {
"type": "array",
"description": "Visibility per category (PF, FTF, MARC); only the sent categories are changed. Takes precedence over visibilityData. Note that this attribute can be updated both for CUSTOM AND MANAGED RESOURCES.",
"items": {
"type": "object",
"$ref": "../visibility.json"
}
},
"managedCoverages": {
"type": "array",
"readonly": true,
Expand Down
Loading
Loading