Hey there,
I am trying to fetch the inventoryLevels via connection using the Shopify GraphQL Bulk API but each time I start a Bulk Operation, I get the error
INTERNAL_SERVER_ERROR
The query I am using is the following:
mutation {
bulkOperationRunQuery(
query: """
query InventoryLevels {
products(query: "published_status:published") {
edges {
node {
__typename
id
variants {
edges {
node {
__typename
id
... on ProductVariant {
inventoryQuantity
inventoryPolicy
inventoryManagement
inventoryItem {
id
requiresShipping
tracked
inventoryLevels {
edges {
node {
__typename
id
... on InventoryLevel {
canDeactivate
createdAt
location {
id
}
quantities(names: ["available"]) {
name
quantity
updatedAt
}
}
}
}
}
}
}
}
}
}
}
}
}
}
"""
) {
bulkOperation {
id
status
}
userErrors {
field
message
}
}
}
Please note that I already have the read_inventory/write_inventory access scopes, is there any additional requirement to be able to query the inventoryLevels via Bulk API ?
PS: When I try the GraphQL query directly (without the Bulk API) for a couple of products, the API is returning data, the issue is only happening when I am using the Bulk API as we need to fetch all the data for all the products.
X-Request-ID of the failed operation request is 3b9502f0-4c5d-4907-a1c5-fa8a84e77366