# Issue creating label for shipment

**URL:** <https://community.shiphero.com/t/issue-creating-label-for-shipment/2938>\
**Category:** GraphQL API\
**Created:** [June 5, 2024, 9:27pm UTC](https://community.shiphero.com/t/issue-creating-label-for-shipment/2938 "2024-06-05T21:27:10Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![rypaul12](https://avatars.discourse-cdn.com/v4/letter/r/ec9cab/32.png) [@rypaul12](https://community.shiphero.com/u/rypaul12)\
**Post date:** [June 5, 2024, 9:27pm UTC](https://community.shiphero.com/t/issue-creating-label-for-shipment/2938/1 "2024-06-05T21:27:10Z")

</div>

I am trying to create a label for a shipment, but whenever I do there is an issue where the shipment line items show as None, and there are no label line items.

I have the following shipment:

```auto
"shipment": {
			"data": {
				"id": "U2hpcG1lbnQ6NDYxODAwMzc3",
				"completed": true,
				"warehouse_id": "V2FyZWhvdXNlOjk2ODc5",
				"created_date": "2024-06-05T21:14:25",
				"address": {
					"name": "Jane Doe None",
					"address1": "123 Main St",
					"address2": "Apt 4",
					"city": "San Francisco",
					"state": "CA",
					"country": "US",
					"zip": null
				},
				"line_items": {
					"edges": [
						{
							"node": {
								"line_item_id": "TGluZUl0ZW06MTE4MTQ4NzM4MQ==",
								"line_item": {
									"sku": "sku12345",
									"quantity": 5
								}
							}
						}
					]
				},
				"shipping_labels": []
			}
		}
	},

```

I perform the following mutation:

```auto
mutation {
    shipment_create_shipping_label(
        data: {
            shipment_id: "U2hpcG1lbnQ6NDYxODAwMzc3"
            customer_account_id: "QWNjb3VudDo3NDE0OQ=="
            address: {
                name: "Jane Doe"
                address1: "123 Main St"
                address2: "Apt 4"
                city: "San Francisco"
                state: "CA"
                zip: "94105"
                country: "US"
            }
            carrier: "test_carrier"
            shipping_name: "shipping_name"
            shipping_method: "shipping_method"
            cost: "1.1"
            dimensions: {
                length: "1.0"
                width: "2.0"
                height: "3.0"
                weight: "4.0"
            }
            line_item_ids: "TGluZUl0ZW06MTE4MTQ4NzM4MQ=="
            label: {
                pdf_location: "pdf_location"
            }
            tracking_number: "tracking_number"
        }
    ) {
        request_id
    }
}

```

After both of these actions, the shipment looks as follows:

```auto
		"shipment": {
			"data": {
				"id": "U2hpcG1lbnQ6NDYxODAwMzc3",
				"completed": true,
				"warehouse_id": "V2FyZWhvdXNlOjk2ODc5",
				"created_date": "2024-06-05T21:14:25",
				"address": {
					"name": "Jane Doe None",
					"address1": "123 Main St",
					"address2": "Apt 4",
					"city": "San Francisco",
					"state": "CA",
					"country": "US",
					"zip": null
				},
				"line_items": {
					"edges": [
						{
							"node": {
								"line_item_id": null,
								"line_item": null
							}
						}
					]
				},
				"shipping_labels": [
					{
						"box_id": null,
						"tracking_number": "tracking_number",
						"carrier": "test_carrier",
						"cost": "1.10",
						"tracking_url": "https://www.google.com/search?q=tracking_number",
						"dimensions": {
							"weight": "4.0000 oz",
							"height": "3.0000 inch",
							"width": "2.00 inch",
							"length": "1.00 inch"
						},
						"shipment_line_items": {
							"pageInfo": {
								"hasNextPage": false
							},
							"edges": []
						}
					}
				]
			}
		}
	}

```

Can you please assist with this issue? Is there anything wrong with my mutation query (please note I tried passing line\_item\_ids as a list also and the same behavior occurred).

Thanks!

---

<div class="post-metadata">

**Author:** ![Luisperrone](https://avatars.discourse-cdn.com/v4/letter/l/ed655f/32.png) [@Luisperrone](https://community.shiphero.com/u/Luisperrone)\
**Post date:** [June 6, 2024, 2:54pm UTC](https://community.shiphero.com/t/issue-creating-label-for-shipment/2938/2 "2024-06-06T14:54:29Z")

</div>

Hi @rypaul12

Where are you getting the `"line_item_id": "TGluZUl0ZW06MTE4MTQ4NzM4MQ==",` ?  
I could not find that ID anywhere in our DB

I understand that you are not creating the label within the shipment\_create mutation. Is this correct?

Try passing the order line\_item\_id to the shipment\_create\_shipping\_label mutation to see if that works.

Here is an example of the shipment\_create mutation in our docs [Examples-mutation – Developer Resources | ShipHero](https://developer.shiphero.com/examples-mutation/#mutationshipment)

Have a nice day!

---

<div class="post-metadata">

**Author:** ![rypaul12](https://avatars.discourse-cdn.com/v4/letter/r/ec9cab/32.png) [@rypaul12](https://community.shiphero.com/u/rypaul12)\
**Post date:** [June 6, 2024, 4:25pm UTC](https://community.shiphero.com/t/issue-creating-label-for-shipment/2938/3 "2024-06-06T16:25:51Z")

</div>

Yes our goal is to create a label for an existing shipment.

That line\_item\_id was grabbed from the existing shipment (as shown in the beginning of my initial question) we wanted to update with a new label. However once we ran the _shipment\_create\_shipping\_label_ mutation it got changed to None, so that is the reason you can’t find the ID in your DB anywhere.

We’ve also tried using the _order\_line\_item\_id_ but saw the same behavior.

---

<div class="post-metadata">

**Author:** ![daniellanger](https://avatars.discourse-cdn.com/v4/letter/d/ad7895/32.png) [@daniellanger](https://community.shiphero.com/u/daniellanger)\
**Post date:** [June 7, 2024, 1:28pm UTC](https://community.shiphero.com/t/issue-creating-label-for-shipment/2938/4 "2024-06-07T13:28:12Z")

</div>

@Luisperrone any thoughts on this? it’s a blocker for us

---

<div class="post-metadata">

**Author:** ![Luisperrone](https://avatars.discourse-cdn.com/v4/letter/l/ed655f/32.png) [@Luisperrone](https://community.shiphero.com/u/Luisperrone)\
**Post date:** [June 7, 2024, 1:36pm UTC](https://community.shiphero.com/t/issue-creating-label-for-shipment/2938/5 "2024-06-07T13:36:25Z")

</div>

@daniellanger

I just replied to the ticket 187549 you created about this issue. Let’s follow up there!
