REST
/api/xml
Used for uploading Shoppa XML's to the integration service bus queue
PUT
https://api.mediablob.com/api/xml
Available Shoppa XML's can be found at XML structure
Headers
Name | Type | Description |
---|---|---|
Authorization* | String | Basic authentication using the integration user credentials. |
customerId* | String | ShoppaID or ExternalID for the customer node. |
customerIdType* | String | "ShoppaID" or "ExternalID". Should be correspondant to the id used as customerId. |
Request Body
Name | Type | Description |
---|---|---|
Text | String | |
File | Object |
SessionId example:
Used for uploading a custom XML to the integration service
PUT
https://api.mediablob.com/api/xml/custom
Custom XML's will be passed through one or several XSLT schemas before being uploaded to the service bus queue. XSLTs are uploaded by Shoppa. To upload or change an XSLT, contact your Shoppa representative for help.
Headers
Name | Type | Description |
---|---|---|
Authorization* | String | Basic authentication using the integration user credentials. |
customerId* | String | ShoppaID or ExternalID for the customer node. |
customerIdType* | String | "ShoppaID" or "ExternalID". Should be correspondant to the id used as customerId. |
Request Body
Name | Type | Description |
---|---|---|
Text | String | |
File | Object |
SessionId example:
Operation to list all uploaded XML's for the defined date
GET
https://api.mediablob.com/api/xml/{date}
Headers
Name | Type | Description |
---|---|---|
Authorization* | String | Basic authentication using the integration user credentials. |
customerId* | String | ShoppaID or ExternalID for the customer node. |
customerIdType* | String | "ShoppaID" or "ExternalID". Should be correspondant to the id used as customerId. |
Id: SessionId for the message. File: Link to the upoaded file. Result: Route to retrieve the result file. See /api/statusfor more information. Errors:
Operation to check if the XML processing is done
GET
https://api.mediablob.com/api/status/{sessionId}/done
{sessionId} corresponds to the hashcode returned by a 202 Accepted response in /api/xml
Operation to get a detailed information about the XML process
GET
https://api.mediablob.com/api/status/{sessionId}/result
{sessionId} corresponds to the hashcode returned by a 202 Accepted response in /api/xml
/api/images
Upload images
POST
https://api.mediablob.com/api/images
Upload one or more images to Mediablob as multipart form data objects. If this image already exists, the
In C# you need to add the images to a MultipartFormDataContent
object, which you add to an HttpClient
call. The response contains the Mediablob id for each image, which you can use to reference the images in further integrations.
If your image has a clipping path you can add these parameters to the call to tell our rest endpoint which clipping path you want to use. The invert parameter is there to make it possible to invert the clipping path.
Query Parameters
Name | Type | Description |
---|---|---|
invert | String | True if the inside of the clipping path shall be removed instead of kept. Defaults to False. |
clippingpath | String | The name of the clipping path to be used. Defaults to not use clipping paths. |
Headers
Name | Type | Description |
---|---|---|
Authorization* | String | Basic authentication using the integration user credentials. |
customerId* | String | ShoppaID or ExternalID for the customer node. |
customerIdType* | String | "ShoppaID" or "ExternalID". Should be correspondant to the id used as customerId. |
Request Body
Name | Type | Description |
---|---|---|
file | Object | Binary image data. Repeat for each image to be uploaded. The parameter name is not used. |
Check if an image exists
HEAD
https://api.mediablob.com/api/images/{Mediablob-hashcode}
Verify that an image exists in Mediablob by using the Mediablob-hashcode that was returned when the image was originally uploaded.
Headers
Name | Type | Description |
---|---|---|
Authorization* | String | Basic authentication using the integration user credentials. |
customerId* | String | ShoppaID or ExternalID for the customer node. |
customerIdType* | String | "ShoppaID" or "ExternalID". Should be correspondant to the id used as customerId. |
Find the Mediablob hashcode for an uploaded image
GET
https://api.mediablob.com/api/images
Find the Mediablob-hashcode for an image that has been previously uploaded. You need to provide one of md5
or uri
query parameter, but not both in the request.
The Mediablob-hashcode is returned in the response if it is successful, which you can use to reference the image in further integrations.
Query Parameters
Name | Type | Description |
---|---|---|
md5 | String | The md5 hash of the original image. |
uri | String | An external uri from which the image was originally fetched. Images can be fetched from external uri's during product xml uploads. |
Headers
Name | Type | Description |
---|---|---|
Authorization* | String | Basic authentication using the integration user credentials. |
customerId* | String | ShoppaID or ExternalID for the customer node. |
customerIdType* | String | "ShoppaID" or "ExternalID". Should be correspondant to the id used as customerId. |
Last updated