3.0.3 • Published 3 years ago

@kite-tech/photobook-sdk v3.0.3

Weekly downloads
1
License
ISC
Repository
-
Last release
3 years ago

Prodigi Photobook Maker SDK

Prodigi offers white label print on demand portals so that you can sell to your users under your brand.

This SDK is compatible with the Prodigi Photobook Maker. Get your own branded instance at Prodigi Apps Dashboard.

With the Photobook Maker SDK, you can integrate your Photobook maker app into your own website, launching it with pre-configured data, such as images, at run-time.

Table of Contents

Demo and examples

For a list of common use-cases and a demo sandbox, visit: https://sdk.prodigi.com/photobook-maker

Installation

Install using NPM:

npm install @kite-tech/photobook-sdk

Usage

Import the package:

import { KitePhotobook } from '@kite-tech/photobook-sdk';

Launch your Photobook Maker app using the launchPhotobook function and pass in your desired configuration:

const photobookMakerConfig = {
    baseUrl: 'https://photobook.prodigi.com/prodigi',
    images: []
};

KitePhotobook.launchPhotobook(photobookMakerConfig);

API

PropertyTypeRequiredDescription
baseUrlstringYESThe complete URL of your Photobook Maker
addNewImagesToBookbooleanNOIf true, any images passed in are automatically added to the Photobook. Default is false
bookSpineTextstringNOOptional text to print on the spine of the Photobook
clearBookbooleanNOClear the Photobook and image library on launch. Default is false
config{ startInNewTab: boolean}NOIf true, the app opens in a new tab/window. Default is false
checkoutFieldsCheckoutFieldsObjectNOPopulate the user's details on the checkout
imagesImagesArrayYESPass in images to use in the Photobook
variantTemplateIdstringNOLaunch into a specific Photobook variant. Template IDs can be found inside the Prodigi apps dashboard.

CheckoutFieldsObject

PropertyTypeRequiredDescription
shippingAddress { recipient_first_name: string, recipient_last_name: string, address_line_1: string, address_line_2: string, city: string, county_state: string, postcode: string, country: string, }NOPopulates the user's shipping address at the checkout. All values are optional
customerEmailstringNOSets the user's email address when they reach the checkout
termsOfServicebooleanNOSets whether to automatically agree to terms of service on checkout

ImagesArray

An array of objects having the following properties:

PropertyTypeRequiredDescription
dimensions{ width: number, height: number}NOThe dimensions of the image URL specified. If not set, the dimensions for all images are calculated before launch. If you cannot specify image dimensions and have a large number of images, it is recommended to display a loading spinner until the app is launched.
thumbnailUrlstringYESLower resolution image URL, used for rendering previews in the browser
urlstringYESFull resolution image URL, used for printing
3.0.3

3 years ago

3.0.2

3 years ago

3.0.1

3 years ago

3.0.0

4 years ago

2.11.0-alpha.2

4 years ago

2.11.0-alpha.1

6 years ago

2.10.0-alpha.1

6 years ago

2.9.0-alpha.2

6 years ago

2.9.0-alpha.1

6 years ago

2.8.0-alpha.1

6 years ago

2.7.0-alpha.3

6 years ago

2.7.0-alpha.2

6 years ago

2.7.0-alpha.1

6 years ago

2.7.0-alpha.0

6 years ago

2.6.0

6 years ago

2.6.0-alpha.0

6 years ago

2.5.1-alpha.0

6 years ago

2.5.0-alpha.1

6 years ago

2.4.0-alpha.1

6 years ago

2.3.0-alpha.1

6 years ago

2.2.2

6 years ago

2.2.1

6 years ago

2.2.0-alpha.3

6 years ago

2.2.0-alpha.2

6 years ago

2.2.0-alpha.1

6 years ago

2.1.3

6 years ago

2.1.2

6 years ago

2.1.1

6 years ago

2.1.0

6 years ago

2.0.1

6 years ago

2.0.0

6 years ago

1.2.0

6 years ago

1.1.22

6 years ago

1.1.21

6 years ago

1.1.20

6 years ago

1.1.19

6 years ago

1.1.18

6 years ago

1.1.17

6 years ago

1.1.16

6 years ago

1.1.15

6 years ago

1.1.14

6 years ago

1.1.13

6 years ago

1.1.12

6 years ago

1.1.11

6 years ago

1.1.10

6 years ago

1.1.9

6 years ago

1.1.7

6 years ago

1.1.6

6 years ago

1.1.5

6 years ago

1.1.4

6 years ago

1.1.3

6 years ago

1.1.2

6 years ago

1.1.1

6 years ago

1.1.0

6 years ago

1.0.3

7 years ago