User Settings encapsulates the account setup that determines automatic image and video processing, callback settings, addons enabled, etc.
Settings API provides the ability to retrieve the settings and update them.
Update user settings by sending a PATCH
HTTP request with partial settings to update. The JSON payload follows the same structure as GET
request response. Only keys below are valid.
storage
, auth
, webhook
, database
, image
, video
, addons
, watermark
Request payload format for each key above is in the following sections.
Example User Settings JSON
{
"status": "OK",
"data": {
"watermark": {
"watermarkFile": "/api/v1/user/watermark/42",
"watermarkPlacement": "top-left",
"watermarkScale": 0.1
},
"storage": {
"originals_root": "MY_BUCKET-orig",
"originals_root_folder": "my/files",
"derivatives_root": "MY_BUCKET-deriv",
"derivatives_root_folder": "my/files",
"transcodes_root": "MY_BUCKET-trans",
"transcodes_root_folder": "my/files",
"originals_root_ok": true,
"derivatives_root_ok": true,
"transcodes_root_ok": true,
"originals_root_geo": "eu-west-1",
"derivatives_root_geo": "eu-west-1",
"transcodes_root_geo": "eu-west-1"
},
"auth": {
"upload_key": "UPLOAD_KEY",
"access_id": "ACCESS_ID",
"api_key": "API_KEY",
"dropbox_app_key": "",
"dropbox_app_secret": "",
"authorized_domains": "mysite.org,mysite.com"
},
"webhook": {
"web_urls": "https://mysite.com/receive_filespin_callback",
"callback_events": {
"file-saved": false,
"file-processed": true,
"file-data-updated": false,
"file-deleted": true,
"file-undeleted": true,
"addon-processed": true
}
},
"image": {
"conversions": [
{
"key": "500x500WEB",
"value": {
"format": "jpg",
"watermark": false,
"enabled": true,
"public": false,
"height": 500,
"width": 500,
"optimize": true,
"dpi": 72
}
},
{
"key": "deepzoom",
"value": {
"format": "jpg",
"public": true,
"watermark": false,
"enabled": true,
"height": null,
"width": null,
"optimize": true,
"dpi": 72
}
}
],
"on_demand_image_private": false
},
"video": {
"video_transcode_test_mode": false,
"transcodes": {
"360p-video": {
"enabled": false,
"aspect": "pad",
"upscale": true,
"public": false,
"padding": "ff0000",
"width": 640,
"height": 360,
"watermark": false
}
},
"preview": {
"video_preview_name": "preview",
"video_preview_public": true,
"video_preview_start": 0,
"video_preview_length": 5,
"video_preview_preset": "480p-wm-video",
"video_preview_enabled": true,
"video_preview_aspect": "pad",
"video_preview_padding": "ff0000",
"video_preview_upscale": true
},
"thumbnails": {
"video_default": {
"width": 640,
"height": 480
},
"storyboard": {
"enabled": true,
"mode": "number",
"mode_value": 5,
"width": 480,
"height": 360,
"public": true,
"aspect": "pad",
"padding": "ff0000",
"upscale": true
}
}
},
"database": {
"db_url": "mysql://",
"db_export_events": {
"file-saved": true,
"file-processed": true,
"file-data-updated": true,
"file-deleted": true,
"file-undeleted": true,
"addon-processed": false
}
},
"cdn": {
"image_cdn": "mycdn.filespin.io",
"video_cdn": "mycdn.filespin.io"
},
"addons": {
"STORYBOARD": {
"title": "Video Storyboard",
"description": "Video Storyboard",
"added": true,
"enabled": true
}
}
}
}