# Get Order LineItem custom\_options field type

**URL:** <https://community.shiphero.com/t/get-order-lineitem-custom-options-field-type/1826>\
**Category:** GraphQL API\
**Created:** [January 24, 2022, 3:17pm UTC](https://community.shiphero.com/t/get-order-lineitem-custom-options-field-type/1826 "2022-01-24T15:17:42Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![heyjess](https://avatars.discourse-cdn.com/v4/letter/h/c6cbf5/32.png) [@heyjess](https://community.shiphero.com/u/heyjess)\
**Post date:** [January 24, 2022, 3:17pm UTC](https://community.shiphero.com/t/get-order-lineitem-custom-options-field-type/1826/1 "2022-01-24T15:17:42Z")

</div>

custom\_options field in Order LineItem is defined as string type on the documentation.

 ![image](https://us1.discourse-cdn.com/flex020/uploads/shiphero/original/1X/c1b8a323dc775f3dc3097cb5e7c0aa5de81b8cf8.png)

However, when we get the data, it doesn’t look like string.

 ![image](https://us1.discourse-cdn.com/flex020/uploads/shiphero/original/1X/5e44cc947f089833b6077065c6295a1a1211eed2.png)

![image](https://us1.discourse-cdn.com/flex020/uploads/shiphero/original/1X/1e12c9d57a0ffe1c63d3cf8b8bb02dccc76d5dd9.png)

“request\_id”: “61eebc6d83a35df05997fbc9”

**What is the actual type of custom\_options field?** We’re having an issue to deserialize a response from Shiphero API due to the unmatched type.

---

<div class="post-metadata">

**Author:** ![tomasfd](https://avatars.discourse-cdn.com/v4/letter/t/5daacb/32.png) [@tomasfd](https://community.shiphero.com/u/tomasfd)\
**Post date:** [January 24, 2022, 4:43pm UTC](https://community.shiphero.com/t/get-order-lineitem-custom-options-field-type/1826/2 "2022-01-24T16:43:57Z")

</div>

Hello @heyjess!

I was just updating our documentation regarding that field!

Please refer to the following announcement: [UPDATE: We refactored custom\_options field for line\_items](https://community.shiphero.com/t/update-we-refactored-custom-options-field-for-line-items/1827)

Let me know if you have any trouble implementing it.

Have a nice day!  
TomasFD

---

<div class="post-metadata">

**Author:** ![heyjess](https://avatars.discourse-cdn.com/v4/letter/h/c6cbf5/32.png) [@heyjess](https://community.shiphero.com/u/heyjess)\
**Post date:** [January 25, 2022, 2:30pm UTC](https://community.shiphero.com/t/get-order-lineitem-custom-options-field-type/1826/3 "2022-01-25T14:30:38Z")

</div>

Hi @tomasfd

Thanks for the rapid response!  
I’m just wondering what those custom options key and values mean?

“\_\_Added with Frequently Bought Together button”: “”  
“\_ZapietId”: “M=S”

Who set these custom options? customers?

Unlike other fields, custom options filed’s keys are dynamic.  
Sometimes, custom\_options: null, sometimes it has “\_\_Added with Frequently Bought Together button”: “” or “\_ZapietId”: “M=S” or both.  
It is difficult to make a class for that.

---

<div class="post-metadata">

**Author:** ![tomasfd](https://avatars.discourse-cdn.com/v4/letter/t/5daacb/32.png) [@tomasfd](https://community.shiphero.com/u/tomasfd)\
**Post date:** [January 25, 2022, 2:56pm UTC](https://community.shiphero.com/t/get-order-lineitem-custom-options-field-type/1826/4 "2022-01-25T14:56:04Z")

</div>

Hello @heyjess!

when working with the API, you can use that to add any king of additional information:

`custom_options: {size:"M", color:"blue", giftwrapped:"yes"}`

They are read-only. They won’t affect the picking or packing process.

If you have an order with custom options you don’t recognize, please share the order id (the number you find in the URL), and I can take a look at it.

Have a nice day!  
TomasFD

---

<div class="post-metadata">

**Author:** ![heyjess](https://avatars.discourse-cdn.com/v4/letter/h/c6cbf5/32.png) [@heyjess](https://community.shiphero.com/u/heyjess)\
**Post date:** [January 25, 2022, 3:15pm UTC](https://community.shiphero.com/t/get-order-lineitem-custom-options-field-type/1826/5 "2022-01-25T15:15:36Z")

</div>

Thanks @tomasfd

The custom\_options examples above are from order id T3JkZXI6MjQ0MjgyNjU1  
When we pull the order data, custom\_options are always either null, or “\_\_Added with Frequently Bought Together button”: “” ot “\_ZapietId”: “M=S” or both and the keys and values are ununderstandable.

So, I’m trying to figure it out that the custom\_options is needed to us or not.

I’d appreciate your support!

---

<div class="post-metadata">

**Author:** ![tomasfd](https://avatars.discourse-cdn.com/v4/letter/t/5daacb/32.png) [@tomasfd](https://community.shiphero.com/u/tomasfd)\
**Post date:** [January 26, 2022, 2:51pm UTC](https://community.shiphero.com/t/get-order-lineitem-custom-options-field-type/1826/6 "2022-01-26T14:51:19Z")

</div>

Hello @heyjess!

There is a field in Shopify called `properties` inside of `line_items`, that has a value that works ina similar way:

`properties[{name1:"string":value1:"string"},{name2:"string":value2:"string"}]`

We poll that field to fill our `custom_options` field.

I hope this clears it out. If not, please let me know.

Kind regards,  
TomasFD
