Inventory
This web service retrieves information about all e-/audio books available in DDS based on your users access rights and permissions. It is essential that you as a retailer check your inventory regularly (minimum every 24 hours) and update your store based on the information found in the inventory. The inventory only provides DDS specific data on each book and must be used in combination with the data from the Metadata Export Service The response is delivered in XML as an ATOM feed.
Get inventory (v2)
The new interface for inventory is updated to support a larger volume of books with introducing a paging mechanism where you are sure that you are always getting books that have changes. (similar to the mechanism used in Metadata Export Service. For details on how to user next and after parameters see: Export Service#Parameters
The performance of this endpoint is dramatically improved compared to v1 and you will be able to load this data much faster. However, note that you will see a much larger number of books with access=false if you do not have a contract to sell international titles. Still, with the significant improvement in load time this is a more efficient way of loading Inventory data for Norwegian titles as well.
Note that if you do lookup on isbn, all versions of the book will be returned, not just the latest one.
New Authentication & URLs introduced Q2 2024
URL |
The token acquired from the Authentication Service. Example: Header:
| ||
Method |
| ||
Request | Authorization | Required | The token acquired from the Authentication Service . Audience: Example: |
Query | after | Required if next not given | |
next | Required if after not given | ||
pagesize | optional | (default and max value is 10000) | |
Response | Content-Type | application/atom+xml;charset=UTF-8 | |
Next | next token for next page | ||
Link | link to next page | ||
Response | ATOM Inventory XML format (same format as before, however only latest version of each book is returned and some fields are removed) | ||
Returns |
| OK | |
| On error |
Curl example
Initial load using after
(timestamp) - if you are not using your persisted next
from last call/session
curl -i \
-H "Authorization: Bearer <token>" \
"https://api.bokbasen.io/dds/inventory/v2?after=20140501120000"
HTTP/1.1 200 OK
Date: Fri, 07 Aug 2015 11:19:45 GMT
Content-Type: application/atom+xml;charset=UTF-8
(ATOM Inventory XML)
Curl example legacy example
Initial load using after
(timestamp) - if you are not using your persisted next
from last call/session
curl -i \
-H "Authorization: Boknett TGT-19933-EcDNpJfVcJNrpcMeGvGKcfUHvV1W2MR50zb066X6vTZVTypXBQ-login.boknett.no" \
-H "Date: Fri, 07 Aug 2015 11:18:39 GMT" \
"https://api.dds.boknett.no/v2/inventory/?after=20140501120000"
HTTP/1.1 200 OK
Date: Fri, 07 Aug 2015 11:19:45 GMT
Content-Type: application/atom+xml;charset=UTF-8
(ATOM Inventory XML)
ATOM Inventory XML format for v2
For v2 some fields are removed, contact us if we have removed fields that are important for your process.
Example XML:
<?xml version="1.0" encoding="UTF-8"?>
<feed xmlns="http://www.w3.org/2005/Atom" xmlns:inv="http://bokbasen.no/module/inventory/1.0">
<title>Inventory Items</title>
<link rel="self" type="application/atom+xml" href="http://api.dds.boknett.no/inventory/" title="Inventory feed" />
<updated>2015-08-07T11:19:45Z</updated>
<entry>
<id>urn:uuid:99496f82-84c5-4de7-9899-31603e26a355</id>
<updated>2015-08-06T11:52:09Z</updated>
<inv:isbn>9788242160966</inv:isbn>
<inv:publisher>900224</inv:publisher>
<inv:format>MP3</inv:format>
<inv:drm>SDRM</inv:drm>
<inv:version>1</inv:version>
<inv:deleted />
<inv:published>true</inv:published>
<inv:access>false</inv:access>
<inv:excerpt>false</inv:excerpt>
</entry>
</feed>
Inventory XML element documentation
Element | Explanation |
---|---|
| Title of book |
| Name of author |
| The id of the digital resource representing the book. (Referred to as uuid or reId) Note that this ID can change at any time if the publisher of the book publishes a new version of the digital file. |
| Last time resource was updated |
| ISBN of book |
| Id of publisher |
| Format of the file (always MP3 for audio books even if they are distributed in different formats) |
| What kind of DRM protection the book have, possible values are: SDRM, TDRM, NODRM, or UNKNOWN |
| Version number for the digital resource. Starts with 1 and increments if new version of the digital book is published. |
| Date book was first published |
| Date book was deleted (empty value if not deleted) |
| If the books in published, you cannot initiate downloads on a book that is not published. |
| Role based, do you as an integrator have access to this book? Must be true in order for you to sell the title. |
| If excerpts are available through DDS. (Will always be false for audio books as these are distributed through the metadata API.) |
Get inventory (v1) Deprecated