Can't Upload IAP Item Review Screenshots via the API

I'm uploading IAP Item review screenshots via the App Store Connect API. I create the request, then receive the upload operations. I perform the upload, making sure to populate the headers, and put the data in a buffer in the body of the PUT request.

https://developer.apple.com/documentation/appstoreconnectapi/create_an_in-app_purchase_review_screenshot

When that upload API call returns, it gives me back an empty buffer. Nothing I do seems to alter the buffer, including intentionally sending incorrect data as a test. Is this intended behavior? What does the empty buffer mean?

https://developer.apple.com/documentation/appstoreconnectapi/commit_a_review_screenshot_for_an_in-app_purchase

Then, without knowing whether my upload has succeeded, I try to commit the upload. That call always returns an unexpected internal server error. I suspect this is because the upload didn't actually succeed, and that the screenshot is still empty, but I have no way of knowing why. There's no documentation page for the actual upload API call, as far as I know. Here's the error.

{
      status: '500',
      code: 'UNEXPECTED_ERROR',
      title: 'An unexpected error occurred.',
      detail: 'An unexpected error occurred on the server side. If this issuue continues, contact us at https://developer.apple.com/contact/.'
    }

How do you upload IAP screenshots?

hi, @JoeBush3d did you find any solution to this issue ??

me too

me too

Encountered the same issue, turns out what fixed it for us was specifying the file extension along the file name in the fileName field.

{
   "attributes": {
      "fileSize": 26559,
      "fileName": "Frame 1.png" // .png matters
    },
}

Can't Upload IAP Item Review Screenshots via the API
 
 
Q