> 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/order-desk/integration-specifications.md).

# Integration Specifications

## Integration Overview

Order Desk automates and streamlines order management workflow with integrations to hundreds of e-commerce services.

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

## API Endpoints

The Daasity Order Desk extractor is built based on this [Order Desk API documentation](https://apidocs.orderdesk.com/).  The following endpoint is used by Daasity to replicate data from Order Desk:

* [Orders](https://apidocs.orderdesk.com/#orders)

## Entity Relationship Diagram (ERD)

[Click here to view the ERD for the Daasity Order Desk integration](https://lucid.app/documents/embedded/b1f736af-0310-4752-a0b4-2865b32b7da7) illustrating the different tables and keys to join across tables.

#### Order Desk Schema

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

* [Orders](#orders)
* [Order Checkout Data](#order-checkout-data)
* [Order Metadata](#order-metadata)
* [Order Discount List](#order-discount-list)
* [Order Notes](#order-notes)
* [Order Items](#order-items)
* [Order Items Variation List](#order-items-variation-list)
* [Order Shipments](#order-shipments)

### **Orders**

* Endpoint: [Orders](https://apidocs.orderdesk.com/#orders)
* Update Method: UPSERT
* Table Name: \[`order_desk.orders`]

| JSON Element                             | Database Column               |
| ---------------------------------------- | ----------------------------- |
| id                                       | id                            |
| email                                    | email                         |
| shipping\_method                         | shipping\_method              |
| quantity\_total                          | quantity\_total               |
| weight\_total                            | weight\_total                 |
| product\_total                           | product\_total                |
| shipping\_total                          | shipping\_total               |
| handling\_total                          | handling\_total               |
| tax\_total                               | tax\_total                    |
| discount\_total                          | discount\_total               |
| order\_total                             | order\_total                  |
| cc\_number\_masked                       | cc\_number\_masked            |
| cc\_exp                                  | cc\_exp                       |
| processor\_response                      | processor\_response           |
| payment\_type, limit: 64                 | payment\_type                 |
| payment\_status, limit: 18               | payment\_status               |
| processor\_balance                       | processor\_balance            |
| refund\_total                            | refund\_total                 |
| customer\_id                             | customer\_id                  |
| email\_count                             | email\_count                  |
| ip\_address                              | ip\_address                   |
| source\_name, limit: 64                  | source\_name                  |
| fulfillment\_name                        | fulfillment\_name             |
| fulfillment\_id                          | fulfillment\_id               |
| folder\_id                               | folder\_id                    |
| date\_added                              | date\_added                   |
| date\_updated                            | date\_updated                 |
| shipping::first\_name, limit: 64         | shipping\_first\_name         |
| shipping::last\_name, limit: 64          | shipping\_last\_name          |
| shipping::company, limit: 64             | shipping\_company             |
| shipping::address1                       | shipping\_address1            |
| shipping::address2                       | shipping\_address2            |
| shipping::address3                       | shipping\_address3            |
| shipping::address4                       | shipping\_address4            |
| shipping::city, limit: 64                | shipping\_city                |
| shipping::state, limit: 2                | shipping\_state               |
| shipping::postal\_code, limit: 64        | shipping\_postal\_code        |
| shipping::country, limit: 64             | shipping\_country             |
| shipping::phone, limit: 64               | shipping\_phone               |
| customer::first\_name, limit: 64         | customer\_first\_name         |
| customer::last\_name, limit: 64          | customer\_last\_name          |
| customer::company, limit: 64             | customer\_company             |
| customer::address1                       | customer\_address1            |
| customer::address2                       | customer\_address2            |
| customer::city                           | customer\_city                |
| customer::state, limit: 2                | customer\_state               |
| customer::postal\_code, limit: 64        | customer\_postal\_code        |
| customer::country, limit: 64             | customer\_country             |
| customer::phone, limit: 64               | customer\_phone               |
| return\_address::title, limit: 64        | return\_address\_title        |
| return\_address::name, limit: 64         | return\_address\_name         |
| return\_address::company, limit: 64      | return\_address\_company      |
| return\_address::address1                | return\_address\_address1     |
| return\_address::address2                | return\_address\_address2     |
| return\_address::city                    | return\_address\_city         |
| return\_address::state, limit: 2         | return\_address\_state        |
| return\_address::postal\_code, limit: 64 | return\_address\_postal\_code |
| return\_address::country, limit: 64      | return\_address\_country      |
| source\_id, limit: 64                    | \_\_source\_id                |
| Daasity: shop\_id                        | \_\_shop\_id                  |
| seller\_id                               | seller\_id                    |
| marketplace\_id                          | marketplace\_id               |
| Daasity: account\_id                     | \_account\_id                 |
| Daasity: MD5(id + source\_id)            | \_\_sync\_key                 |
| Daasity: timestamp when loaded into DB   | \_\_synced\_at                |

### **Order Checkout Data**

* Endpoint: [Orders](https://apidocs.orderdesk.com/#orders)
* Update Method: UPSERT
* Table Name: \[`order_desk.order_checkout_data`]

| JSON Element                             | Database Column                      |
| ---------------------------------------- | ------------------------------------ |
| MD5(id + checkout\_data::first)          | order\_checkout\_data\_id            |
| id                                       | order\_id                            |
| custom\_data::first, limit: 4095         | order\_checkout\_data\_custom\_key   |
| custom\_data::last, limit: 4095          | order\_checkout\_data\_custom\_value |
| source\_id, limit: 64                    | \_\_source\_id                       |
| Daasity: shop\_id                        | \_\_shop\_id                         |
| seller\_id                               | seller\_id                           |
| marketplace\_id                          | marketplace\_id                      |
| Daasity: account\_id                     | \_account\_id                        |
| Daasity: MD5(id + checkout\_data::first) | \_\_sync\_key                        |
| Daasity: timestamp when loaded into DB   | \_\_synced\_at                       |

### **Order Metadata**

* Endpoint: [Orders](https://apidocs.orderdesk.com/#orders)
* Update Method: UPSERT
* Table Name: \[`order_desk.order_metadata`]

| JSON Element                             | Database Column                |
| ---------------------------------------- | ------------------------------ |
| MD5(id + custom\_data.first)             | order\_metadata\_id            |
| id                                       | order\_id                      |
| custom\_data::first, limit: 4095         | order\_metadata\_custom\_key   |
| custom\_data::last, limit: 4095          | order\_metadata\_custom\_value |
| source\_id, limit: 64                    | \_\_source\_id                 |
| Daasity: shop\_id                        | \_\_shop\_id                   |
| seller\_id                               | seller\_id                     |
| marketplace\_id                          | marketplace\_id                |
| Daasity: account\_id                     | \_account\_id                  |
| Daasity: MD5(id + checkout\_data::first) | \_\_sync\_key                  |
| Daasity: timestamp when loaded into DB   | \_\_synced\_at                 |

### **Order Discount List**

* Endpoint: [Orders](https://apidocs.orderdesk.com/#orders)
* Update Method: UPSERT
* Table Name: \[`order_desk.order_discount_list`]

| JSON Element                                         | Database Column     |
| ---------------------------------------------------- | ------------------- |
| MD5(id + discount::name + discount::amount)          | order\_discount\_id |
| id                                                   | order\_id           |
| discount::name, limit: 64                            | name                |
| discount::code, limit: 64                            | code                |
| discount::amount                                     | amount              |
| source\_id, limit: 64                                | \_\_source\_id      |
| Daasity: shop\_id                                    | \_\_shop\_id        |
| seller\_id                                           | seller\_id          |
| marketplace\_id                                      | marketplace\_id     |
| Daasity: account\_id                                 | \_account\_id       |
| Daasity: MD5(id + discount::name + discount::amount) | \_\_sync\_key       |
| Daasity: timestamp when loaded into DB               | \_\_synced\_at      |

### **Order Notes**

* Endpoint: [Orders](https://apidocs.orderdesk.com/#orders)
* Update Method: UPSERT
* Table Name: \[`order_desk.order_notes`]

| JSON Element                                                            | Database Column |
| ----------------------------------------------------------------------- | --------------- |
| MD5(id + note::date\_added + note::user\_name + note::content)          | order\_note\_id |
| id                                                                      | order\_id       |
| note::date\_added                                                       | date\_added     |
| note::user\_name, limit: 64                                             | user\_name      |
| note::content, limit: 64                                                | content         |
| source\_id, limit: 64                                                   | \_\_source\_id  |
| Daasity: shop\_id                                                       | \_\_shop\_id    |
| seller\_id                                                              | seller\_id      |
| marketplace\_id                                                         | marketplace\_id |
| Daasity: account\_id                                                    | \_account\_id   |
| Daasity: MD5(id + note::date\_added + note::user\_name + note::content) | \_\_sync\_key   |
| Daasity: timestamp when loaded into DB                                  | \_\_synced\_at  |

### **Order Items**

* Endpoint: [Orders](https://apidocs.orderdesk.com/#orders)
* Update Method: UPSERT
* Table Name: \[`order_desk.order_items`]

| JSON Element                           | Database Column |
| -------------------------------------- | --------------- |
| MD5(id + item::id)                     | order\_item\_id |
| id                                     | order\_id       |
| item::id                               | id              |
| item::name                             | name            |
| item::price                            | price           |
| item::quantity                         | quantity        |
| item::weight                           | weight          |
| item::code, limit: 64                  | code            |
| item::delivery\_type, limit: 64        | delivery\_type  |
| item::category\_code, limit:64         | category\_code  |
| item::metadata                         | metadata        |
| source\_id, limit: 64                  | \_\_source\_id  |
| Daasity: shop\_id                      | \_\_shop\_id    |
| seller\_id                             | seller\_id      |
| marketplace\_id                        | marketplace\_id |
| Daasity: account\_id                   | \_account\_id   |
| Daasity: MD5(id + item::id)            | \_\_sync\_key   |
| Daasity: timestamp when loaded into DB | \_\_synced\_at  |

### **Order Items Variation List**

* Endpoint: [Orders](https://apidocs.orderdesk.com/#orders)
* Update Method: UPSERT
* Table Name: \[`order_desk.order_items_variation_list`]

| JSON Element                           | Database Column                       |
| -------------------------------------- | ------------------------------------- |
| MD5(id + custom\_data.first)           | order\_item\_variation\_id            |
| id                                     | order\_id                             |
| custom\_data::first, limit: 4095       | order\_item\_variation\_custom\_key   |
| custom\_data::last, limit: 4095        | order\_item\_variation\_custom\_value |
| source\_id, limit: 64                  | \_\_source\_id                        |
| Daasity: shop\_id                      | \_\_shop\_id                          |
| seller\_id                             | seller\_id                            |
| marketplace\_id                        | marketplace\_id                       |
| Daasity: account\_id                   | \_account\_id                         |
| Daasity: MD5(id + custom\_data.first)  | \_\_sync\_key                         |
| Daasity: timestamp when loaded into DB | \_\_synced\_at                        |

### **Order Shipments**

* Endpoint: [Orders](https://apidocs.orderdesk.com/#orders)
* Update Method: UPSERT
* Table Name: \[`order_desk.order_shipments`]

| JSON Element                                                            | Database Column     |
| ----------------------------------------------------------------------- | ------------------- |
| MD5(id + shipping::tracking\_number + shipping::carrier\_code)          | order\_shipment\_id |
| id                                                                      | order\_id           |
| shipping::tracking\_number                                              | tracking\_number    |
| shipping::carrier\_code                                                 | carrier\_code       |
| shipping::shipment\_method                                              | shipment\_method    |
| shipping::weight                                                        | weight              |
| shipping::cost                                                          | cost                |
| shipping::status, limit: 32                                             | status              |
| shipping::tracking\_url, limit: 4095                                    | tracking\_url       |
| shipping::label\_format, limit: 64                                      | label\_format       |
| shipping::label\_image                                                  | label\_image        |
| shipping::print\_status, limit: 64                                      | print\_status       |
| shipping::order\_items                                                  | order\_items        |
| shipping::source, limit: 64                                             | source              |
| shipping::cart\_shipment\_id, limit: 64                                 | cart\_shipment\_id  |
| shipping::label\_shipment\_id, limit: 64                                | label\_shipment\_id |
| shipping::date\_shipped                                                 | date\_shipped       |
| shipping::date\_added                                                   | date\_added         |
| source\_id, limit: 64                                                   | \_\_source\_id      |
| Daasity: shop\_id                                                       | \_\_shop\_id        |
| seller\_id                                                              | seller\_id          |
| marketplace\_id                                                         | marketplace\_id     |
| Daasity: account\_id                                                    | \_account\_id       |
| Daasity: MD5(id + shipping::tracking\_number + shipping::carrier\_code) | \_\_sync\_key       |
| Daasity: timestamp when loaded into DB                                  | \_\_synced\_at      |


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://help.daasity.com/core-concepts/data-integrations/setup-guides/digital-integrations/order-desk/integration-specifications.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
