This web service validates if the sale would be recorded succesfully. Because many parameters are required and validated by the platform for a sale to be recorded successfully (price, protection, availability of the book on the Platform), we recommend that you check with this web service if the sale would work with the actual data you have in your catalog.
The sale is not recorded on the platform. You must use the Sale of a Publication API to record a valid sale.
Declaration
Address : /api/organisations/[organisation_id]/publications/[isbn]/sales/new
Method : GET
Security : HTTP/BASIC (Use your username and password)
Parameters
organisation_id : (Mandatory)
Your merchant number. This number is provided to you upon registration.
isbn : (Mandatory)
The publication's ISBN.
format : (Mandatory)
The publication's format (pdf/epub/mobi).
cost : (Mandatory)
The price of the sale in cents (e.g., $19.99 => 1999).
protection : (Mandatory)
The type of protection on the sold publication (none/watermark/acs4/acs4_timelimited/drm_drm_timelimited).
drm_type : (Optional)
The type of DRM applied on the sold publication (acs/lcp/urms).
country : (Mandatory)
The country which will be considered to validate the price of the publication. ISO 3166-1 Alpha-3 (can, fra, ita) or Alpha-2 (CA, FR, IT) formats.
cost_without_taxes : (Optional / Mandatory on Eden Livres)
Price, without taxes, in the country of the buyer, in cents (ex. : 19,99$ => 1999)
price_type : (Optional)
The ONIX price type used for cost validation. List 58, possible values: 01, 02, 03, 04, 41 and 42.
currency : (Mandatory)
The currency of the amount provided in 'cost'; used for cost validation. 3-letter ISO-4217 code.
Responses
200 : valid
The simulation was executed successfully.
400 : cannot_sell
You cannot sell this publication.
400 : missing_format
You did not enter the format.
400 : invalid_format
The selected format is not available for this publication.
400 : invalid_sale_parameters
cost, country, currency or price_type parameter is invalid.
400 : missing_cost
You did not enter the price.
400 : missing_protection
You did not enter the protection type.
400 : invalid_protection
This protection is not available for this format of the publication.
400 : invalid_country
The country code is invalid.
401 : access_denied
You do not have access to the resource.
404 : not_found
Your organization or the ISBN could not be found.
503 : service_unavailable
A problem has occured while connecting to the server.
Notes
In the case of a code 400 error, a vector containing the types of errors will be sent to you.