GraphQL mutation - "Something went wrong, please try again"

Hi,

I’m trying to perform the discountRedeemCodeBulkAdd mutation in a rails application.

I am creating multiple discounts and adding 1000 codes to each in batches of 100. After the majority of the mutations have run I am receiving an error.

I thought this would be a rate limit issue but the error response I received however was as follows.

  {"data"=>
    {"discountRedeemCodeBulkAdd"=>
      {"bulkCreation"=>nil,
       "userErrors"=>[{"code"=>nil, "field"=>nil, "message"=>"Something went wrong, please try again."}]}},
   "extensions"=>
    {"cost"=>
      {"requestedQueryCost"=>10,
       "actualQueryCost"=>10,
       "throttleStatus"=>{"maximumAvailable"=>2000.0, "currentlyAvailable"=>1888, "restoreRate"=>100.0}}}},
 @code=200,

The request ID is : “f14338bc-a51d-4d49-9ac7-fed303a603d3”

It seems to be resolved with a 1 second sleep, but I would like to handle this properly if it is indeed a rate issue, however this does not seem possible with the information provided.

Could somebody shine some light on what is causing this error?

Hi J-Marriott,

There’s no additional messages appearing on our side related to this error, so it does not look like it’s related to rate limits.

Hi Liam,

Would you be able to tell me why the request failed on Shopify’s end, as it appears that the request has sent successfully given the 200 response?

What conditions would cause the message below to be returned?

Something went wrong, please try again. 
1 Like