### Overview

In order to set one or several orders as unshipped, you can consume the endpoint presented in this article. In order to consume it, you must:

- Be authenticated user

For information on how you can authenticate, see: [Authentication](https://developer.sellercloud.com/dev-article/authentication/)

As soon as you do authentication and receive a valid token, it needs to be passed to the service call.

### Endpoint

Example for such endpoint for **TT** server is:

https://tt.api.sellercloud.com/rest/api/Orders/SetUnshipped

For your server endpoint will be:

https://{your_server_id}.api.sellercloud.com/rest/api/Orders/SetUnshipped

### Request

Information about expected request parameters can be found on swagger UI [https://tt/api.sellercloud.com/rest/swagger](https://tt/api.sellercloud.com/rest/swagger).

- Method Type: **HttpPut**
- Authorization: Use **Bearer Token** (where ‘Token’ is the token received from token authentication)
- Header info: **Content-Type: application/json**
- Request Body:

```
{
  "Orders": [\
    0\\
  ],
  "PIN": "string"
}
```

|     |     |     |     |
| --- | --- | --- | --- |
| **Parameter** | **Data Type** | **Description** | **Is Required** |
| Orders | List | List with order ids to unship.<br>**NOTE:** If a single order is provided for unshipping it will be immediately unshipped. If more than one order is provided for unshipping a queued job for unshipping the list of orders will be created and its ID will be returned in the response. | true |
| PIN | string | Security PIN to edit shipped orders.<br>Required only if client setting ‘Require Security PIN to edit Shipped Orders.’ is enabled.<br>Do not provide or set to “null” if not needed. | false |

### Response

- If user is authenticated and unshipping is successful, then response will be **Status Code 200 => OK** and queued job ID in the response body in case of more than one order is provided for unshipping.
- If user is not authenticated, then response will be **Status Code 401 => Not Valid Token**
- In case of error, response will be **Status Code 500 => Internal Server Error**
