Selling plan group id is different in GraphQL and on Storefront Liquid

I am trying to compare the SellingPlanGroup id that I receive through the GraphQL api and the storefront liquid api.

Through the GraphQL api the id I receive looks like:

gid://shopify/SellingPlanGroup/76390826260

However when I try to access the selling plan group through the storefront via liquid it outs the following for the id:

 562296a49db5ea2882517591b6e1c2c157e4fe7f

It appears that the storefront is encoding the id somehow. I have tried to create an md5 hash of the id that I get through the graphql API but it doesn’t appear to create the correct output

{{ "gid://shopify/SellingPlanGroup/76390826260" | md5 }} outputs "cb3571edaec37d191de017cc3b826834"

If possible could someone explain how to get this hashed id? Thank you.

1 Like