question

afab-recycling avatar image
0 Likes"
afab-recycling asked

500 error with /inventory_item/

Trying to create an inventory item. But I get the following error.

"errorId":2003
"domain":"ACCESS"
"category":"APPLICATION"
"message":"Internal error"
"longMessage":"There was a problem with an eBay internal system or process. Contact eBay developer support for assistance"
"parameters":[
  {
    "name":"code",
    "value":"415",
  },
  {
    "name":"message",
    "value":"com.sun.jersey.api.MessageException: A message body reader for Java class com.ebay.raptor.slrinvapi.app.entities.InventoryItem, and Java type class com.ebay.raptor.slrinvapi.app.entities.InventoryItem, and MIME media type application/octet-stream was not found."
  }

I don't think the issue is with my request payload but just in case here it is (some bits censored)

/*url: https://api.ebay.com/sell/inventory/v1/inventory_item/240 */

/*Payload*/
{
  "availability": {
    "shipToLocationAvailability": {
      "availabilityDistributions": [
        {"merchantLocationKey": "****", "quantity": 1}
      ],
    "quantity": 1
    }
  },
  "condition": "USED_EXCELLENT", 
  "packageWeightAndSize": {
    "dimensions": {
      "height": 7,
       "length": 4,
       "width": 4,
       "unit": "INCH"
    },
    "packageType": "LETTER",
    "weight": {
      "value": 3.0,
      "unit": "OUNCE"
    }
  },
  "product": {
    "aspects": {"Color": ["Gold"], "Brand": ["Unbranded"]},
    "description": "A bead necklace made of gold colored plastic beads.",
    "imageUrls": [
      "https://i.ebayimg.com/00/s/***",
      "https://i.ebayimg.com/00/s/***",
      "https://i.ebayimg.com/00/s/***"
    ],
    "title": "Gold-Tone Plastic Bead Necklace"
  }
}

Any clue what is going on???

inventorycreateorreplaceinventoryiteminventory_itemsellerror 2003500 server errorerror code 415
10 |600 characters needed characters left characters exceeded

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

1 Answer

· Write an Answer
afab-recycling avatar image
0 Likes"
afab-recycling answered

Did not include a Content-Type header in my request. Added one with application/json and now it works.

10 |600 characters needed characters left characters exceeded

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.