Mircate
  1. PIM
Mircate
  • Introduction
  • Authentication
  • Errors
  • Change Logs
  • PIM
    • Get Products
      POST
    • Get Product Settings
      GET
    • Get Catalog Settings
      GET
    • Upsert Product
      POST
    • Upsert Category
      POST
    • Bulk Product Upsert
      POST
    • Check Batch Status
      POST
    • Delete Product
      POST
    • Attach Product Attribute Image
      POST
    • Attach Category Image
      POST
    • Get Image
      GET
    • Upsert Attributes
      POST
    • Delete Attribute
      POST
    • Upsert Attribute Options
      POST
    • Upsert Attribute Option
      POST
    • Delete Attribute Option
      POST
  • Promotion
    • Calculate
      POST
    • Start Transaction
      POST
    • Commit Transaction
      POST
    • Revert Transaction
      POST
    • Cancel Transaction
      POST
    • Get Active Promotions
      GET
  • Loyalty
    • Receive Event
      POST
    • Calculate
      POST
    • Start Transaction
      POST
    • Commit Transaction
      POST
    • Cancel Transaction
      POST
    • List Measurements
      POST
  • Wallet
    • Get Wallet
    • Create Wallet
    • Create Account
    • Get Account
    • Get Accounts
    • List Accounts
    • List Transactions
    • Add Account
    • Remove Account
    • Fix
    • Load
    • Spend
    • Refund
    • Cancel
  • Talking Product
    • Create Product
    • Update Product
    • Delete Product
    • Get Product
    • List Product
  • Merchant
    • Sales Channel
      • Reserve Stock
      • Cancel Stock
      • Commit Stock
      • Refund Stock
      • Get Current Stock
    • Product Supplier
      • Receive Stock
      • Receive Price
      • Get Stock/Price History
      • Check Batch Status
      • Remove My Products
      • Clean My Products
      • Export Stock/Price
      • List Exports
      • Get Exported Files
    • Global Products
      • Receive Products
      • Get Global Products
      • Remove Global Products
  • Common
    • Dataset
      • Create
      • Update
      • Delete
      • Value Upsert
      • Value Delete
      • List Sources
      • List Values
  • How to
    • Creating a Promotion Template
    • Promotion Transaction Flow
    • Understanding PIM Product Statuses
  1. PIM

Attach Product Attribute Image

Production
https://api.b2b.retter.io/5p1hp1d2t
Production
https://api.b2b.retter.io/5p1hp1d2t
POST
https://api.b2b.retter.io/5p1hp1d2t
/CALL/PIMAPI/attachProductAttributeImage/{B2B_PIM_ACCOUNT_ID}
PIM
Last modified:2025-02-19 14:35:31
This method is used to manage product feature images. Through the relevant API method, it enables adding feature images to a specific product. The suitability of the request is verified with the model and authorization is confirmed. A response is obtained, and in the case of a temporary image upload error, the error is processed.

Request

Authorization
Add parameter in header
x-api-key
Example:
x-api-key: ********************
Path Params
B2B_PIM_ACCOUNT_ID
string 
required
Body Params application/json
productId
string 
required
attributeCode
string 
required
file
object 
optional
image
string 
optional
extension
string 
optional
imageUrl
string 
optional
files
array [object {2}] 
optional
image
string 
optional
extension
string 
optional
imageUrls
array[string]
optional
shouldReplace
boolean 
optional
Default:
false
locale
string 
optional
If the attribute is localizable, the update applies only to the specified locale. If omitted, the update applies to all locales.
scope
string 
optional
If the attribute is scopable, the update applies only to the specified channel. If omitted, the update applies to all channels.
Example
{
    "productId": "ea",
    "attributeCode": "",
    "file": {
        "image": "base64encodedimagecontent",
        "extension": "jpeg"
    },
    "imageUrl": "https://picsum.photos/200/300",
    "files": [
        {
            "image": "base64encodedimagecontent",
            "extension": "jpeg"
        },
        {
            "image": "base64encodedimagecontent",
            "extension": "jpeg"
        },
        {
            "image": "base64encodedimagecontent",
            "extension": "jpeg"
        }
    ],
    "imageUrls": [
        "https://picsum.photos/300/300",
        "https://picsum.photos/400/400"
    ],
    "shouldReplace": false,
    "locale": "ecommerce",
    "scope": "mobile"
}

Request samples

Shell
JavaScript
Java
Swift
Go
PHP
Python
HTTP
C
C#
Objective-C
Ruby
OCaml
Dart
R
Request Request Example
Shell
JavaScript
Java
Swift
curl --location --request POST 'https://api.b2b.retter.io/5p1hp1d2t/CALL/PIMAPI/attachProductAttributeImage/' \
--header 'Content-Type: application/json' \
--header 'x-api-key;' \
--data-raw '{
    "productId": "ea",
    "attributeCode": "",
    "file": {
        "image": "base64encodedimagecontent",
        "extension": "jpeg"
    },
    "imageUrl": "https://picsum.photos/200/300",
    "files": [
        {
            "image": "base64encodedimagecontent",
            "extension": "jpeg"
        },
        {
            "image": "base64encodedimagecontent",
            "extension": "jpeg"
        },
        {
            "image": "base64encodedimagecontent",
            "extension": "jpeg"
        }
    ],
    "imageUrls": [
        "https://picsum.photos/300/300",
        "https://picsum.photos/400/400"
    ],
    "shouldReplace": false,
    "locale": "ecommerce",
    "scope": "mobile"
}'

Responses

🟢200OK
application/json
Successful response
Body
object {0}
Example
{}
🟠400Bad Request
🟠403Forbidden
🟠404Record Not Found
Modified at 2025-02-19 14:35:31
Previous
Delete Product
Next
Attach Category Image
Built with