API method collection.update

Updates the settings of an existing collection.

Note: Requests must be made to https://api.flipsnack.com/v1. Name Type Description apiKey (required) string The API key provided for your user. If it is not specified, the request will return the error code "30 - Missing mandatory parameter". If the key is incorrect the request returns the error code "41 - Invalid credentials". signature (required) string The signature must be calculated by you and added to the request. See How to sign a request for more information. If the parameter is missing the request will return the error code "30 - Missing mandatory parameter". If the signature is incorrect the request will return the error code "44 - Invalid signature". action (required) string The API method that should be called. In this case the value should be collection.update. If it is not specified, the request will return the error code "30 - Missing mandatory parameter". collectionHash (required) string The hash of the collection you wish to update. If you do not specify a collection hash, then the request will return the error code "30 - Missing mandatory parameter". format string The format of the response from the server. Possible values are json, jsonp and xml. If you set format to jsonp, you must also specify the callback parameter.

Default: json. callback string The name of the callback function used for the jsonp response. This parameter is required if format is set to jsonp. Otherwise it is ignored. title string The title of the collection. This title will appear on the collection's direct link and in the My Collections page. By default, if a title is not given, Flipsnack will try to extract the title from the uploaded document. description string The description of the collection. By default, during the conversion process, Flipsnack extracts the first few words from the document. You can overwrite that description with yours, using this parameter. collectionWidth number The embed width of the widget (measured in pixels).

Default: 650. collectionHeight number The embed height of the widget (measured in pixels).

Default: 385. collectionStatus string The type of collection. Possible values are public, editable and unlisted.

Public collections are listed on your public profile and in search results. They are publicly available to other users.

Editable collections are not published. They must be published manually from the Flipsnack editor or have their status updated using the collection.update method.

Unlisted collections are published but not listed on your profile page and in search results. Other users may view them only if they receive a direct link or an embedded widget from you.

Note: Once a collection receives the public status, it cannot be changed to unlisted, even if the current status is set to editable. But unlisted collections can be changed to public collections.

Default: public. enableThumbView boolean If set to true, displays the thumbnail viewer in the Adobe Flash widget. The thumbnail viewer is displayed only when the Flash widget is in fullscreen.

Default: true. enableToc boolean If set to true and if the pdf has a table of contents the widget will display it.

Default: false. showControls boolean If set to true, then the navigation controls will be displayed in normal mode

Default: false. enableDownload boolean If set to true, displays the download button in the flash widget menu. The menu is displayed only when the widget is in fullscreen.

Default: true. enablePrint boolean If set to true, displays the print button in the widget menu. The menu is displayed when the widget is in fullscreen.

Default: true. enableFullScreen boolean If set to true, allows the Flash widget to enter fullscreen mode: a "Click to read" button is displayed.

Default: true. enableSearch boolean If set to true, displays the search button in the flash widget menu. The menu is displayed only when the widget is in fullscreen.

If there is no text to search within the current collection item, the search button is displayed, but disabled.

Default: true. tooltipsLanguage string Selects the language for the tooltips displayed in the flash widget. Possible languages are: Basque, Bosanski, Català, Czech, Dansk, Deutsch, English, Español, כשר, Française, ελληνικά, Hrvatski, Indonesian, Italiano, Magyar, Nederlands, Nederlands, Norsk, Polski, Português, Português do Brasil, Română, Pусский, Cрпски, Slovene, Suomi, Slovak, Swedish, Turkish.

Default: English. background string The background color of the widget. Possible values are color and transparent. If set to transparent, the widget is displayed with no background. Background color value can be set using the color parameter, explained below.

Default: color. color string The background color of the widget, specified as a hexadecimal value. If the background is set to transparent, the widget will ignore the color parameter.

Default: 444444. backgroundScaleType string The scale mode of images used as background for the widget. Possible values are scaleCrop, center and tile. Background images can be set using the collection.setBackgroundImage method.

Default: scaleCrop. autoFlip boolean If set to true, allows the widget to automatically turn the pages of the flipbook. The pages turn after a time specified by the autoFlipDelay parameter.

Default false. autoFlipDelay number Specifies the time in seconds for pages to turn automatically. If autoFlip is false, this parameter is ignored.

Default: 6. rightToLeftOrientation boolean If set to true, allows the flipbook to be viewed from right to left: the first page is starts from the end, as viewed in normal mode. This option is useful for documents written in right to left languages.

Default: false. singlePageView boolean If set to true, allows the flipbook to be viewed a single page at a time.

Default: false. logoUrl string The URL of the logo image. A logo image can be set only by uploading it with the collection.setLogo method. Name Type Description collectionWidth number The embed width of the widget (measured in pixels). collectionHeight number The embed height of the widget (measured in pixels). collectionStatus string The type of collection. Possible values are public, editable and unlisted.

Public collections are listed on your public profile and in search results. They are publicly available to other users.

Editable collections are not published. They must be published manually from the Flipsnack editor or updated using the collection.update method.

Unlisted collections are published but not listed on your profile page and in search results. Other users may view them only if they receive a direct link or an embedded widget from you. enableDownload boolean If set to true, displays the download button in the flash widget menu. The menu is displayed only when the widget is in fullscreen. enableFullScreen boolean If set to true, allows the Flash widget to enter fullscreen mode: a "Click to read" button is displayed. enableSearch boolean If set to true, displays the search button in the flash widget menu. If there is no text to search within the current collection item, the search button is displayed as disabled. tooltipsLanguage string Selects the language for the tooltips displayed in the flash widget. Possible languages are: Basque, Bosanski, Català, Czech, Dansk, Deutsch, English, Español, כשר, Française, ελληνικά, Hrvatski, Indonesian, Italiano, Magyar, Nederlands, Nederlands, Norsk, Polski, Português, Português do Brasil, Română, Pусский, Cрпски, Slovene, Suomi, Slovak, Swedish, Turkish. transparentBackground boolean If set to true, the widget is displayed with no background. When embedding Flash widgets, make sure that the wmode parameter of the embed tag is set to 'transparent'. backgroundColor string The background color of the widget, specified as a hexadecimal value. If the transparentBackground is set to true, the widget will ignore the backgroundColor parameter. backgroundScaleType string The scale mode of images used as background for the widget. Possible values are scaleCrop, center and tile. Background images can be set using the collection.setBackgroundImage method. autoFlip boolean If set to true, allows the widget to automatically turn the pages of the flipbook. The pages turn after a time specified by the autoFlipDelay parameter. autoFlipDelay number Specifies the time in seconds for pages to turn automatically. If autoFlip is false, this parameter is ignored. rightToLeftOrientation boolean If set to true, allows the flipbook to be viewed from right to left: the first page is starts from the end as viewed in normal mode. This option is useful for documents written in right to left languages. singlePageView boolean If set to true, allows the flipbook to be viewed a single page at a time. logoUrl string The URL of the logo image. A logo image can be set only by uploading it with the collection.setLogo method. shareFacebook boolean If set to true, the Flash widget displays a Facebook sharing option in the widget menu, in fullscreen mode. shareTwitter boolean If set to true, the Flash widget displays a Twitter sharing option in the widget menu, in fullscreen mode. shareGooglePlus boolean If set to true, the Flash widget displays a Google+ sharing option in the widget menu, in fullscreen mode. sharePinterest boolean If set to true, the Flash widget displays a Pinterest sharing option in the widget menu, in fullscreen mode. shareEmail boolean If set to true, the Flash widget displays an email sharing option in the widget menu, in fullscreen mode. shareLinkText string The link opened from the link sharing option, within the widget. By default, this link is the direct link of the collection.

.

XML

20
OK
d3m0h45h
Lorem ipsum dolor
published
https://files.flipsnack.net/collections/items/7c5e600d4459fe4e04d23ae5ei188777/covers/page_1/medium
https://www.flipsnack.com/user/lorem-ipsum.html
2015-06-09 01:43:05
2015-06-09 01:43:07
2
7c5e600d4459fe4e04d23ae5ei188777
2
Lorem ipsum
Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua.
pdf
COMPLETE
800
600
true

JSON

{
"code": 20,
"status": "OK",
"data": {
"collectionHash": "d3m0h45h",
"collectionTitle": "Lorem ipsum dolor",
"collectionStatus": "published",
"coverImage": "https://files.flipsnack.net/collections/items/7c5e600d4459fe4e04d23ae5ei188777/covers/page_1/medium",
"directLink": "https://www.flipsnack.com/user/lorem-ipsum.html",
"createdDate": "2015-06-09 01:43:05",
"publishDate": "2015-06-09 01:43:07",
"collectionPageCount": 2,
"collectionItems": [
{
"flipbookHash": "7c5e600d4459fe4e04d23ae5ei188777",
"flipbookPageCount": "2",
"flipbookTitle": "Lorem ipsum",
"flipbookDescription": "Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua.",
"extension": "pdf",
"convertStatus": "COMPLETE"
}
],
"settings": {
"collectionWidth": "800",
"collectionHeight": "600",
"enableFullScreen": "true"
}
}
}

JSONP

callbackFunctionName({data});
// callbackFunctionName is the function name specified by the callback parameter, in the request
// the {data} is the actual JSON response