Q
 

api reference

To use remote service please first obtain a remote access key at "my account" page

Init ExtraZoom remote editor

The easiest way to integrate flash publisher into your CMS system

Command name: http://extrazoom.com/api/initEditor
Action: Load and integrate the swf ExtraZoom editor with your CMS page. The javascript code attaches the editor to the textareas code holders
Attributes:

  • key - your remote access key
  • textareas - comma separated list of textareas' ids to contain or receive publishing code (they have to be prensent in the page body)

Usage: place script somewhere inside head tag of your html document

<head>
...
<script type="text/javascript" src="http://extrazoom.com/api/initEditor?key=your_remote_access_key&textareas=textarea_id,textarea_id"></script>
...
</head>

UploadImage

ExtraZoom image saver

Command name: http://extrazoom.com/api/uploadImage
Action: Save an image sent along with command
Attributes:

  • key - your remote access key
  • image_url - url of previously saved image for replacing
  • save_src - flag to save downloadable original file (values: '1' or '')
  • type - type of respond format (values: 'xml' or 'json', default: 'xml')
  • image - input file name

Example:

<form name="your_form" method="post" enctype="multipart/form-data" action="http://extrazoom.com/api/uploadImage?key=your_remote_access_key&save_src=1&type=xml">
<input type="file" name="image">
<input type="submit" name="go" value="Go">
</form>

Return: xml or json formatted string where success: flag(0|1), key:your remote access key, image_url:url of saved image if succeed, sys_message: respond text, error: error code (if not succeed)

<root>
<success>1</success>
<key>your_remote_access_key</key>
<id/>
<image_url>the_uploaded_image_url</image_url>
<sys_message>Finished</sys_message>
<error/>
</root>

{"success":1,"key":"your_remote_access_key","id":null,"image_url":"the_uploaded_image_url","sys_message":"Finished","error":""}

RemoveImage

Delete ExtraZoom image

Command name: http://extrazoom.com/api/removeImage
Action: Remove the image and all its data
Attributes:

  • key - your remote access key
  • image_url - url of removing image (url encoded string)
  • type - type of respond format (values: 'xml' or 'json', default: 'xml')

Example:

http://extrazoom2.com/api/removeImage?key=your_remote_access_key&image_url=the_image_url&type=xml

Return: xml or json formatted string where success: flag(0|1), key:your remote access key, image_url:url of saved image if succeed, sys_message: respond text, error: error code (if not succeed)

<root>
<success>1</success>
<key>your_remote_access_key</key>
<id/>
<image_url>the_removed_image_url</image_url>
<sys_message>Finished</sys_message>
<error/>
</root>

{"success":1,"key":"your_remote_access_key","id":null,"image_url":"the_removed_image_url","sys_message":"Finished","error":""}

Respond Error's Codes

 

  • #001: Missing access key. Register to get valid key or generate it in your account at site name if you are already registerd.
  • #002: Wrong access key. Register to get valid key or generate it in your account at site name if you are already registerd.
  • #003: No such API
  • #004: There is not such image in your record
  • #005: The image file is missing
  • #010: Upload id is missing
  • #011: The uploaded file is not the image one
  • #012: The file has unacceptable mime type
  • #015: The image size exceeds the limit of 8000×8000px
  • #016: The image is under minimum limit of 400×400px
  • #017: The file was not uploaded. File exceed the limit of max size of 32768Kbytes