👍

Endpoint

Params

  • Accept: application/xml OR application/json
  • Content-Type: image/jpeg
  • Authorization: OAuth2 [Base64 encoded token]

Request Param Details

PARAMETERSREQUIREDTYPENOTES
filenameYstringThe name of the file that is going to be uploaded. Char limit = 69
display_orderYintegerDenotes the display order of the style images as shown on the web site and iPad applications
replace_existingNBooleanIf True, any previously assigned style images will be deleted and replaced with the newly Posted image.
color_codeXstringIf provided, the image will be associated with the style’s color. Required if optional “swatch” provided.
urlXstringThe URL encoded path to the image hosted publically (required if not posting RAW image)
swatchNbooleanIf “true”, the image will be associated as a color swatch. Note: color_code also required.

Request Examples

POST | https://api.jooraccess.com/v2/style-number/00123/ST1234566/image/?filename=abc123.jpg&display_order=1
Would create an image associated with the primary style.

POST | https://api.jooraccess.com/v2/style-number/00123/ST1234566/image/?filename=abc123-1.jpg&color_code=001&display_order=1
Would create an image associated with the style color (limit to 1 per style color).

POST | https://api.jooraccess.com/v2/style-number/00123/ST1234566/image/?filename=abc123-1S.jpg&color_code=001&swatch=true&display_order=1
Would create an image “swatch” associated with the style color (limit 1 per style color).

POST | https://api.jooraccess.com/v2/style-number/00123/ST1234566/image/?filename=joor_logo.png&display_order=1&url=https://jooraccess.com/icons/joor_logo.png
Would create an image associated to the primary style from a URL.

POST | https://api.jooraccess.com/v2/style-number/00123/ST1234566/image/?filename=joor_logo.png&display_order=1&url=https://jooraccess.com/icons/joor_logo.png&replace_existing=true
Would create an image associated with the primary style from a URL and replace any previously assigned images.

Response Example

<?xml version="1.0" encoding="UTF-8"?>
<style_image_created>
    <response>
        <code>000</code>
        <error_message></error_message>
        <log_id>e52bb250-37e9-11e2-81c1-0800200c9a66</log_id>
        <log_uri>https://api.jooraccess.com/logs/e52bb250-37e9-11e2-81c1-0800200c9a66</log_uri>
    </response>
    <image_created>
        <style_number>00123</style_number>
        <image_id>123456</image_id>
    </image_created>
</style_image_created>
{
  "style_image_created": {
    "response": {
      "code": "000",
      "log_id": "e52bb250-37e9-11e2-81c1-0800200c9a66",
      "log_uri": "https://api.jooraccess.com/logs/e52bb250-37e9-11e2-81c1-0800200c9a66"
    },
    "image_created": {
      "style_number": "00123",
      "image_id": "123456"
    }
  }
}