Selling a publication for lending
Declaring the sale of a publication for lending purposes is very similar to the procedure for selling products to the general public, described in Integrating ebook selling to a website. You can therefore refer to this documentation, taking into account the following few parameters, which differ in their use.
Name | Mandatory | Description |
|---|---|---|
| Yes | Identifier of the library offer received in the ONIX stream (not the ISBN/EAN of the consumer product). |
| No | Unlike the mainstream market Sales API, the protection setting is not required to sell a library product. The Adobe time-limited protection will be automatically applied to each loan. |
| No | This parameter is obsolete; it is no longer required for the sale of library products. |
| Yes | Indicates in which format the loan link information will be returned. Possible values: xml, json. |
Dans le cas de la vente d'un produit bibliothèque, un lien, qui permet de déclarer un prêt sur cet exemplaire, vous est retourné, soit en XML ou en JSON (voir le paramètre output ci-dessus). Ce lien doit être conservé dans votre système (libraire), et doit être transmis au système de prêt qu'utilise la bibliothèque qui a fait l'achat du livre (référez-vous aux spécifications du système de prêt pour cette étape). Il s'agit d'un lien pérenne.
La réponse prend la forme suivante:
Format | Réponse |
|---|---|
|
|
|
|
The link [loan_url] takes the following form:
https://domaine/api/loans/UGV60GNogpXRcS3UtHAkZcHPOlDTIlnaJ3Z1uFYuf0DQfmgAEnzSUdY3rQY1vRxI/activate
The same HTTP return codes as for the mainstream market Sales API apply, plus the following:
Code | Content | Description |
|---|---|---|
400 |
| The publication is not available for loan. |