> For the complete documentation index, see [llms.txt](https://help.daasity.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://help.daasity.com/core-concepts/data-integrations/setup-guides/digital-integrations/shipstation/integration-specifications.md).

# Integration Specifications

## Integration Overview

ShipStation is a web-based shipping platform that helps businesses manage their small parcel shipping and e-commerce fulfillment.

This document provides context on what kind of data is being gathered through this extractor, which endpoints that data is coming from, and how the extracted tables relate to each other.

## Integration Availability

This integration is available for:

* Enterprise
* Growth

{% hint style="info" %}
**NOTE:** A code block exists to include shipping costs into Daasity data model (UOS) from ShipStation
{% endhint %}

## API Endpoints

The Daasity integration with ShipStation extracts data from a number of endpoints from the [ShipStation API](https://www.shipstation.com/docs/api/).

The following endpoints are currently included in the Integration and currently refreshed on a daily basis:

* [List Carriers](https://www.shipstation.com/docs/api/carriers/list/)
* [List Packages](https://www.shipstation.com/docs/api/carriers/list-packages/)
* [List Services](https://www.shipstation.com/docs/api/carriers/list-services/)
* [List Orders](https://www.shipstation.com/docs/api/orders/list/)
* [List Products](https://www.shipstation.com/docs/api/products/list/)
* [List Shipments](https://www.shipstation.com/docs/api/shipments/list/)
* [List Users](https://www.shipstation.com/docs/api/users/list/)
* [List Warehouses](https://www.shipstation.com/docs/api/warehouses/list/)

## Entity Relationship Diagram (ERD)

[Click here to view the ERD for the Daasity Shipstation integration](https://lucid.app/documents/embedded/8956d366-1b91-4748-b4f8-3e76efd76a48) illustrating the different tables and keys to join across tables.

## ShipStation Schema

The Daasity ShipStation extractor creates these tables using the endpoints and replication methods listed.  The data is mapped from the source API endpoint to the table based on the mapping logic outlined in each table.

* [Carriers](#carriers)
* [Carrier Packages](#carrier-packages)
* [Carrier Services](#carrier-services)
* [Orders](#orders)
* [Order Items](#order-items)
* [Shipments](#shipments)
* [Shipment Line Items](#shipment-line-items)
* [SKUs](#skus)
* [SKU Attributes](#sku-attributes)
* [Users](#users)
* [Warehouses](#warehouses)

### **Carriers**

* Endpoint: [List Carriers](https://www.shipstation.com/docs/api/carriers/list/)
* Update method: UPSERT
* Table name: \[`shipstation.carriers`]

| API Field                               | Database Column           |
| --------------------------------------- | ------------------------- |
| MD5(shippingProviderId + accountNumber) | id                        |
| name                                    | name                      |
| code                                    | code                      |
| accountNumber                           | account\_number           |
| requiresFundedAccount                   | requires\_funded\_account |
| balance                                 | balance                   |
| shippingProviderId                      | shipping\_provider\_id    |
| nickname                                | nickname                  |
| primary                                 | is\_primary               |

### **Carrier Packages**

* Endpoint: [List Packages](https://www.shipstation.com/docs/api/carriers/list-packages/)
* Update method: UPSERT
* Table name: \[`shipstation.carrier_packages`]

| API Field               | Database Column |
| ----------------------- | --------------- |
| MD5(carrierCode + code) | id              |
| carrierCode             | carrier\_code   |
| code                    | code            |
| name                    | name            |
| domestic                | domestic        |
| international           | international   |

### **Carrier Services**

* Endpoint: [List Services](https://www.shipstation.com/docs/api/carriers/list-services/)&#x20;
* Update method: UPSERT
* Table name: \[`shipstation.carrier_services`]

| API Field               | Database Column |
| ----------------------- | --------------- |
| MD5(carrierCode + code) | id              |
| carrierCode             | carrier\_code   |
| code                    | code            |
| name                    | name            |
| domestic                | domestic        |
| international           | international   |

### **Orders**

* Endpoint: [List Orders](https://www.shipstation.com/docs/api/orders/list/)&#x20;
* Update method: UPSERT
* Table name: \[`shipstation.orders`]

| API Field                      | Database Column        |
| ------------------------------ | ---------------------- |
| orderId                        | id                     |
| orderId                        | order\_id              |
| orderNumber                    | order\_number          |
| orderKey                       | order\_key             |
| orderDate                      | order\_date            |
| createDate                     | create\_date           |
| modifyDate                     | modify\_date           |
| paymentDate                    | payment\_date          |
| shipByDate                     | ship\_by\_date         |
| orderStatus                    | order\_status          |
| customerId                     | customer\_id           |
| customerUsername               | customer\_username     |
| customerEmail                  | customer\_email        |
| shipTo::name                   | ship\_to\_name         |
| shipTo::company                | ship\_to\_company      |
| shipTo::street1                | ship\_to\_street1      |
| shipTo::street2                | ship\_to\_street2      |
| shipTo::city                   | ship\_to\_city         |
| shipTo::state                  | ship\_to\_state        |
| shipTo::postalCode             | ship\_to\_postal\_code |
| shipTo::country                | ship\_to\_country      |
| shipTo::phone                  | ship\_to\_phone        |
| orderTotal                     | order\_total           |
| amountPaid                     | amount\_paid           |
| taxAmount                      | tax\_amount            |
| shippingAmount                 | shipping\_amount       |
| paymentMethod                  | payment\_method        |
| carrierCode                    | carrier\_code          |
| serviceCode                    | service\_code          |
| packageCode                    | package\_code          |
| shipDate                       | ship\_date             |
| holdUntilDate                  | hold\_until\_date      |
| advanced\_options::warehouseId | warehouse\_id          |

### **Order Items**

* Endpoint: [List Orders](https://www.shipstation.com/docs/api/orders/list/)
* Update method: UPSERT
* Table name: \[`shipstation.order_items`]

| API Field                              | Database Column  |
| -------------------------------------- | ---------------- |
| MD5(productId + orderId + orderItemId) | key              |
| orderID                                | order\_id        |
| orderItemID                            | order\_item\_id  |
| lineItemKey                            | line\_item\_key  |
| sku                                    | sku              |
| name                                   | name             |
| quantity                               | quantity         |
| unitPrice                              | unit\_price      |
| taxAmount                              | tax\_amount      |
| shippingAmount                         | shipping\_amount |
| productID                              | product\_id      |
| fulfillmentSku                         | fulfillment\_sku |
| upc                                    | upc              |
| modifyDate                             | modify\_date     |
| createDate                             | create\_date     |

### **Shipments**

* Endpoint: [List Shipments](https://www.shipstation.com/docs/api/shipments/list/)
* Update method: UPSERT
* Table name: \[`shipstation.shipments`]

| API Field          | Database Column        |
| ------------------ | ---------------------- |
| shipmentId         | id                     |
| shipmentId         | shipment\_id           |
| orderId            | order\_id              |
| orderKey           | order\_key             |
| customerEmail      | customer\_email        |
| orderNumber        | order\_number          |
| createDate         | create\_date           |
| shipDate           | ship\_date             |
| shipmentCost       | shipment\_cost         |
| insuranceCost      | insurance\_cost        |
| trackingNumber     | tracking\_number       |
| isReturnLabel      | is\_return\_label      |
| batchNumber        | batch\_number          |
| carrierCode        | carrier\_code          |
| serviceCode        | service\_code          |
| packageCode        | package\_code          |
| confirmation       | confirmation           |
| warehouseId        | warehouse\_id          |
| voided             | voided                 |
| voidDate           | void\_date             |
| shipTo::name       | ship\_to\_name         |
| shipTo::company    | ship\_to\_company      |
| shipTo::street1    | ship\_to\_street1      |
| shipTo::street2    | ship\_to\_steet2       |
| shipTo::city       | ship\_to\_city         |
| shipTo::state      | ship\_to\_state        |
| shipTo::postalCode | ship\_to\_postal\_code |
| shipTo::country    | ship\_to\_country      |
| userId             | user\_id               |

### **Shipment Line Items**

* Endpoint: [List Shipments](https://www.shipstation.com/docs/api/shipments/list/)
* Update method: UPSERT
* Table name: \[`shipstation.shipment_line_items`]

| API Field                                 | Database Column     |
| ----------------------------------------- | ------------------- |
| MD5(productId + shipmentId + orderItemId) | key                 |
| shipmentId                                | shipment\_id        |
| orderItemId                               | order\_item\_id     |
| LineItemKey                               | line\_item\_key     |
| sku                                       | sku                 |
| name                                      | name                |
| quantity                                  | quantity            |
| unitPrice                                 | unit\_price         |
| taxAmount                                 | tax\_amount         |
| shippingAmount                            | shipping\_amount    |
| warehouseLocation                         | warehouse\_location |
| productId                                 | product\_id         |
| fulfillmentSku                            | fulfillment\_sku    |
| upc                                       | upc                 |

### **SKUs**

* Endpoint: [List Products](https://www.shipstation.com/docs/api/products/list/)&#x20;
* Update method: UPSERT
* Table name: \[`shipstation.skus`]

| API Field         | Database Column     |
| ----------------- | ------------------- |
| productId         | id                  |
| productId         | product\_id         |
| sku               | sku                 |
| name              | name                |
| price             | price               |
| defaultCost       | default\_cost       |
| length            | length              |
| width             | width               |
| height            | height              |
| weightOz          | weight\_oz          |
| fulfillmentSku    | fulfillment\_sku    |
| createDate        | created\_at         |
| modifyDate        | modified\_at        |
| active            | active              |
| productType       | product\_type       |
| warehouseLocation | warehouse\_location |

### **SKU Attributes**

* Endpoint: [List Products](https://www.shipstation.com/docs/api/products/list/)&#x20;
* Update method: UPSERT
* Table name: \[`shipstation.sku_attributes`]

| API Field                | Database Column |
| ------------------------ | --------------- |
| MD5(productId + tag\_id) | key             |
| productId                | product\_id     |
| tag\_id                  | tag\_id         |
| name                     | name            |

### **Users**

* Endpoint: [List Users](https://www.shipstation.com/docs/api/users/list/)&#x20;
* Update method: UPSERT
* Table name: \[`shipstation.user`]

| API Field | Database Column |
| --------- | --------------- |
| userId    | id              |
| userName  | user\_name      |
| name      | name            |
| active    | active          |

### **Warehouses**

* Endpoint: [List Warehouses](https://www.shipstation.com/docs/api/warehouses/list/)
* Update method: UPSERT
* Table name: \[`shipstation.warehouses`]

| API Field     | Database Column |
| ------------- | --------------- |
| warehouseId   | id              |
| warehouseId   | warehouse\_id   |
| warehouseName | name            |
