Set new Location's Type to Pallet

Hi,
I’m using the product_create mutation to create skus and simultaneously providing a new location name to be created in the same command. Is there a way for me to also specify the location type to be ‘Pallet’?

If it won’t work in that same command, what’s the next best alternative to change the location type once it’s created?

Thank you,
Raj

Hi Raj! Location names cannot be updated from the API, this can only be done in the UI for now.
Have a nice day!

Hi @tomasfd , NOT location names, I’m trying to change the location type (pallet, bin, shelf etc) - is that possible?

Hi @Raj, I meant to say types. It is the same for both, though.

Hi @tomasfd , can you tell me what this location_type_id field does and what kind of values it accepts?


Thank you

Hi @tomasfd - anything on above question pls?

Hi @Raj!

Apologies for the confusion. I was checking for Bins instead of locations and those mutations slid through me.

You should be able to update the type using that mutation + field:

mutation{
  location_update(data:{
    location_id:"#######"
    location_type_id:"####"    
  }){
    request_id
  }
}

However, we don’t currently have a way to query all the available type IDs. You can find them by navigating to https://app.shiphero.com/dashboard/location-types, and when you hover over the delete button, you will see the ID at the end of the URL.

Have a great day!

1 Like

Ah got it, no worries!

So at the given link, I see these:


Would I just provide one of these strings as the location_type_id value to update Location Type?

Thank you so much!

Hey @Raj, in that screen, if you hover over the delete button for a type, you should see the destination URL pop up in your browser, usually down left. The last part of the URL has the ID.
Have a great day!

1 Like

Ah, I had a feeling that the id would be something internal and not the ‘name’ that we gave to those location types. Thanks for clarifying that!

1 Like