com.dft.api.shopify.v202410.ShopifyGraphQlCarrierServiceAPI Maven / Gradle / Ivy
package com.dft.api.shopify.v202410;
import com.dft.api.shopify.ShopifyGraphQLSdk;
import com.dft.api.shopify.model.auth.AccessCredential;
import com.dft.api.shopify.v202410.model.carrier.CarrierServiceData;
import com.dft.api.shopify.v202410.model.carrier.DeliveryCarrierServiceCreateInput;
import com.dft.api.shopify.v202410.model.common.GraphQlQuery;
import com.dft.api.shopify.v202410.model.common.GraphQlVariable;
import com.dft.api.shopify.v202410.model.common.QueryResponse;
import com.fasterxml.jackson.core.type.TypeReference;
public class ShopifyGraphQlCarrierServiceAPI extends ShopifyGraphQLSdk {
public ShopifyGraphQlCarrierServiceAPI(AccessCredential accessCredential) {
super(accessCredential);
}
public QueryResponse createCarrierService(GraphQlVariable variables) {
GraphQlQuery graphQlQuery = new GraphQlQuery();
graphQlQuery.setQuery("mutation carrierServiceCreate($input: DeliveryCarrierServiceCreateInput!) { carrierServiceCreate(input: $input) { carrierService { id name supportsServiceDiscovery active callbackUrl formattedName } userErrors { field message } } }");
graphQlQuery.setVariables(variables);
return getQueryData(graphQlQuery, new TypeReference<>() {});
}
}
© 2015 - 2024 Weber Informatics LLC | Privacy Policy