How to obtain tax number information in orders from Mexico

How to obtain tax number information in orders from Mexico

363518457
Shopify Partner
19 0 4

{"query":"query { order(id: "gid://shopify/Order/*****") { name localizationExtensions(first: 100) { edges { node { key countryCode purpose title value } } }}}"}

 

We obtain the tax ID information of the order through the above interface. But I found a problem. Brazilian tax numbers can be obtained successfully, but Mexican tax numbers cannot be obtained. May I ask how to solve this problem.

 

 

Successfully retrieved data from data1, but when retrieving data from data2, the returned data was empty.

 

data1: CPF/CNPJ:00755720873

data2: RFC:BORO630127DU8

Replies 2 (2)

Foxfur
Shopify Partner
9 0 1

I was just looking for the same number but as you say the endpoint you mention doesn't include the RFC number on Mexican orders.

I noticed on the 2025-01 version of the GraphQL API there's a connection on the object order that's called localizedFields which supposedly should contain the same data, however when I try to query that version of the API it just returns 'bad request', regardless of what I query it with, so I haven't yet been able to see if that localizedFields connection contains the RFC number for Mexico. 

 

If anyone knows where else I can find this number in the GraphQL API, I'd love to know, thank you!

Foxfur
Shopify Partner
9 0 1

Ok I managed to fix the bad request issue I had and indeed if you query 

 

 

localizedFields(first: 100) {
    nodes {
          title
          value
     }
}

 

on the order object, you will indeed get the RFC number on Mexican orders, but you need to switch to the 2025-01 version of the API, since it's a change that has only just been introduced at the beginning of this year.

Hope it works for you!
 

 

Foxfur_3-1736363036678.png