Shopify GraphQL获取产品的交货率

Shopify GraphQL获取产品的交货率,graphql,shopify,shipping,shopify-api,Graphql,Shopify,Shipping,Shopify Api,我正在尝试从[deliveryProfiles]对象(或shipping profiles)获取产品及其交付率。使用下面的查询,我可以提取与[deliveryProfile]关联的所有产品,但我无法确定如何获取每个产品的交货率。我们的商店只使用静态运费,所以我认为我需要使用下面的[rateProvider]查询。但我不知道,甚至不知道如何修改查询以包含这样的内容 rateProvider {... on DeliveryRateDefinition {id price {amount} 我正在

我正在尝试从[deliveryProfiles]对象(或shipping profiles)获取产品及其交付率。使用下面的查询,我可以提取与[deliveryProfile]关联的所有产品,但我无法确定如何获取每个产品的交货率。我们的商店只使用静态运费,所以我认为我需要使用下面的[rateProvider]查询。但我不知道,甚至不知道如何修改查询以包含这样的内容

rateProvider {... on DeliveryRateDefinition {id price {amount}
我正在使用的当前查询:

query {
  deliveryProfiles (first: 5) {
    edges {
      node {
        profileItems (first: 10) {
          edges {
            node {
              product {
                  id
                  handle
              }
              variants (first: 10) {
                edges {
                  node {
                    id
                    title
                    sku
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}

我明白了。这只是一个理解嵌套的问题。以下是如何使用GraphQL API在Shopify中获取产品和交付率:

query {
  deliveryProfiles (first: 2) {
    edges {
      node {
        profileItems (first: 8) {
          edges {
            node {
              product {
                id
                handle
              }
              variants (first: 8) {
                edges {
                  node {
                    id
                    title
                  }
                }
              }
            }
          }
        }
        profileLocationGroups {
          locationGroupZones(first: 2) {
            edges {
              node {
                methodDefinitions(first: 2) {
                  edges {
                    node {
                      rateProvider {
                        ... on DeliveryRateDefinition {
                          id
                          price {
                            amount
                          }
                        }
                        ... on DeliveryParticipant {
                          id
                          fixedFee {
                            amount
                            currencyCode
                          }
                          percentageOfRateFee
                          participantServices {
                            active
                            name
                          }
                        }
                      }
                    }
                  }
                }
              }
            }
          }
        }        
      }
    }
  }
}