# ShipStation - Magento Ship-Notify Issues 6/22/2020
## Versions reproduced:
### Plugin:
Auctane-api-2.1.24
### Magento store:
v2.3.3 & v2.3.4 (note, did not experience issue on prior store v2.3.1)
### Postman:
Reproducible with Postman using any 2.3.3+ Magento store with plugin version 2.1.24.
## ISSUE 1:
### High level:
“Shipment notification to Magento appears to fail in ShipStation, despite successfully updating the marketplace.”
### Assumption:
Magento plugin is returning a 500 response even though the Ship-notify successfully updates Magento order state.
### User experience:
In ShipStation this error will return the “red shopping cart” symbol in the shipments section. If a user clicks it, they will see the error message display regarding ship-notify. To the user they think the shipment failed, so they will retry or contact support.
### ERROR MESSAGE (if applicable):
"The remote server returned an error: (500) Internal Server Error."
Initial notification feed from marketplace notification for order example 000629397
```
HTTP/1.1 500 Internal Server Error
Connection: keep-alive
Content-Length: 0
Cache-Control: no-store, no-cache, must-revalidate
Content-Type: text/html; charset=UTF-8
```
## ISSUE 2:
High level: “When retrying the Ship-Notify for the same order, the plugin returns a 200 success, but contains an error message, usually “
Assumption: Magento plugin is returning 200 successfully, but also a fault code which is valid due to the fact only one ship-notify may exist per order.
User experience: After the failure displays in ShipStation the user will attempt to retry or contact support to attempt to retry. After the retry, it appears that the notification attempt succeeded, but in reality it actually failed because it was notified the first time.
ERROR MESSAGE (if applicable):
```
[?xml version='1.0' encoding='UTF-8'?][fault] [faultcode]400/faultcode[faultstring]Shipment can not be created for Order : 000629397/faultstring/fault
```
Subsequent response from the order example 000629397
```
HTTP/1.1 200 OK
Connection: keep-alive
[redacted]
[?xml version='1.0' encoding='UTF-8'?][fault] [faultcode]400/faultcode
[faultstring]Shipment can not be created for Order : 000629397/faultstring
/fault
```
## ISSUE 3
> (optional, lower priority as we cannot currently reproduce direclty, but is has been reproduced by the community). The issue and open-source fixes have been documented in a few places. We have not verified these officially:
https://gist.github.com/Hailong/a0d13065529e03b3493e9cb46a5e115d
https://marketplace.magento.com/auctane-api.html
### High level:
“In some instances the ship-notify does not process at all for Magento with both http/https or even potentially due to redirect URLs configured by the merchant.“
### Assumption:
Merchant is redirecting a or the particular URL associated to their Magento store domain configuration. The user configures ShipStation to use that URL, but when the attempt is made to POST at that URL, it’s redirected and the plugin never completes the action to create the shipment in Magento.
The merchant could also be experiencing some intermediary interference, ie CloudFlare.
### User experience:
I attempt to ship-notify through ShipStation to my Magento store and ShipStation shows a green shopping cart (meaning successful response) but the order in Magento contains no shipment at all.
## STEPS TO REPRO - Postman (ISSUE 1 & 2):
1. Create a magento order with product(s) requiring fulfillment in Magento store version 2.3.3+ with the auctane-api2.1.24 plugin installed
2. (POSTMAN) Attempt to “ship-notify” by making the intended POST call to the Magento store.
a. You should receive response similar to ISSUE 1
b. Attempt the same call again, receive response described in ISSUE 2
## STEPS TO REPRO - via ShipStation (ISSUE 1 & 2):
Create a magento order with product(s) requiring fulfillment in Magento store version 2.3.3+ with the auctane-api2.1.24 plugin installed, ensure Magento is connected in ShipStation
1. Import order requiring fulfillment into a ShipStation account.
2. Ship the order by creating a label or marking as Shipped.
3. Navigate to Shipments tab, you should see a failed marketplace notification icon. (red cart, Issue 1)
4. Click on failed marketplace notification icon by hovering over the red shopping cart.
5. Click "Retry Failed Steps" to attempt to send the request again.
6. You should see no errors returned and the red shoppoing cart should show green, meaning a successful response
7. OBSERVE! You may see that Retried Failed Steps for order, received 200 response from Magento, though the boy of the response included a 400 fault code with fault string:
```
Shipment can not be created for Order : 000629397 (likely because initial notification was successful)
```
## TROUBLESHOOTING COMPLETED:
-Verified that despite error message and null response, shipment information is updated in Magento.
-Retried failed steps from failed marketplace notification, error clears, no new tracking feed is present in Admin Panel.
-Confirmed payment is captured after shipping (Invoice After shipping = yes).
-Confirmed via Postman
-You should be able to reproduce this in any Magento store 2.3.3+