Create a product listing-publication
Create a product listing that users can order via the Peecho Checkout. After creation, you can use the ID returned by the endpoint and go to https://test.www.peecho.com/print/{ID} to view the checkout page for that product or publication.
The product listing can be set up as a single product with a specific price, or as multiple products from the same category with prices determined by the profit markup defined in your account settings.
application/json- body
apiKey?stringAPI key of your account
order?The merchant reference number
customSpine?stringHere you can provide an URL to the spine (OR use the following fields to give us texts and fonts and we build it for you)
spineColorHex?stringspineText?stringspineTextTop?stringspineTextBottom?stringspineTextSize?numberspineTextColor?stringspineFontFamily?string"Arial""Brandon""DarkCourier""Georgia""GochiHand""Helvetica""Tahoma""TimesNewRoman""Verdana"currency?stringcurrency code for price display e.g "EUR" or "USD"
locale?string"en""es""nl""de""fi""sv""it""fr""pl"filterSize?stringfilterColour?stringfilterCategory?stringfixedOfferingId?stringfixedOfferingPrice?stringredirect?enableSecureCheckout?booleanSend a 'true' value if you want to enable the secure checkout enabling only authorised users to access it. This will make the endpoint return a secure_publication_id and a token. Access the checkout using this endpoint: https://test.www.peecho.com/checkout/print/en/{secure_publication_id}?token={token}.
secureCheckoutExpirationDate?stringSend an expiration date in the CET timezone if you want the secure checkout to expire after a while, in this format 'dd-MM-yyyy HH:mm:ss'.
OK
application/json- response
Default response — the publication id.
id?numbercurl -X POST 'https://test.www.peecho.com/rest/v3/publication/create' \ -H 'Content-Type: application/json' \ -d '{ "apiKey": "APABCD1234XXXXI", "currency": "EUR", "locale": "nl", "order": { "reference": "DK123LLP", "product": { "title": "Test Publication endpoint", "source": { "file": { "src": "https://calin-thumbnailer.s3-eu-west-1.amazonaws.com/api-test.pdf", "pages": 28, "dimensions": { "height": 210, "width": 297 } } }, "thumbnail": { "src": "https://calin-thumbnailer.s3-eu-west-1.amazonaws.com/download.jfif" } } }}'{ "id": 123456}