Knowledge Base: categories.submit_image

categories.submit_image

HTTP Method: POST
Parameters: api_key, token, slug
Optional Paramters: none

Submits an image to an Ember category, still requires moderation before it appears on the site.
NOTE: Only sub-categories can receive submissions. The top level categories are merely for grouping.

Required Parameters

api_key:    API token for your client.
token:      The image token. Can be retrieved via [images.view](http://support.realmacsoftware.com/faqs/ember/api-images-view) [string]
slug:       The collection slug. Can be retrieved from [categories.index](http://support.realmacsoftware.com/faqs/ember/api-categories-index) [int]

Usage

Simply send a HTTP POST containing the above parameters in the body.

https://api.emberapp.com/categories/submit_image

Response

On success: HTTP 200 response.
On failure: HTTP 400 response plus an array of errors.

Example Successful XML Response

<?xml version="1.0"?>
<response>
    <status code="0">OK</status>
    <api>api.categories.submit_image</api>
</response>

Example Unsuccessful XML Response

<?xml version="1.0"?>
<response>
    <status code="1">FAIL</status>
    <api>api.categories.submit_image</api>
    <errors>
        <image_id>Image has already been submitted</image_id>
    </errors>
</response>