membershipToggles
query
An access token is required to call this API. Refer to Authorization for more information about how to obtain the token.
Check the status of feature toggles in the store.
Returns
Is the gift card feature currently enabled
Is the membership feature currently enabled
Is the points feature currently enabled
Is the referral feature currently enabled
Is the store credit feature currently enabled
Error Code
For more information about common error codes, refer to Status and error codes.
Example
Check the status of feature toggles in the store.
Code
query {
membershipToggles {
giftCardToggle
pointsToggle
storeCreditsToggle
referralToggle
membershipToggle
}
}
Response
{
"data": {
"membershipToggles": {
"giftCardToggle": true,
"membershipToggle": true,
"pointsToggle": true,
"referralToggle": true,
"storeCreditsToggle": true
}
},
"extensions": {
"dataloader": {
"individual-statistics": {
"LD-com.shopline.merchant.website.openapi.interfaces.OnlineStorefrontApi-commentsQuery": {
"batchInvokeCount": 0,
"batchLoadCount": 0,
"batchLoadExceptionCount": 0,
"batchLoadExceptionRatio": 0,
"batchLoadRatio": 0,
"cacheHitCount": 0,
"cacheHitRatio": 0,
"loadCount": 0,
"loadErrorCount": 0,
"loadErrorRatio": 0
},
"LD-com.shopline.pixiu.pcq.storefront.api.CollectionStorefrontQueryService-onlineStoreUrl": {
"batchInvokeCount": 0,
"batchLoadCount": 0,
"batchLoadExceptionCount": 0,
"batchLoadExceptionRatio": 0,
"batchLoadRatio": 0,
"cacheHitCount": 0,
"cacheHitRatio": 0,
"loadCount": 0,
"loadErrorCount": 0,
"loadErrorRatio": 0
},
"LD-com.shopline.pixiu.pcq.storefront.api.CollectionStorefrontQueryService-queryCollectionByProduct": {
"batchInvokeCount": 0,
"batchLoadCount": 0,
"batchLoadExceptionCount": 0,
"batchLoadExceptionRatio": 0,
"batchLoadRatio": 0,
"cacheHitCount": 0,
"cacheHitRatio": 0,
"loadCount": 0,
"loadErrorCount": 0,
"loadErrorRatio": 0
},
"LD-com.shopline.pixiu.pcq.storefront.api.DescriptionQueryService-query": {
"batchInvokeCount": 0,
"batchLoadCount": 0,
"batchLoadExceptionCount": 0,
"batchLoadExceptionRatio": 0,
"batchLoadRatio": 0,
"cacheHitCount": 0,
"cacheHitRatio": 0,
"loadCount": 0,
"loadErrorCount": 0,
"loadErrorRatio": 0
},
"LD-com.shopline.pixiu.pcq.storefront.api.ProductStorefrontQueryV2Service-images": {
"batchInvokeCount": 0,
"batchLoadCount": 0,
"batchLoadExceptionCount": 0,
"batchLoadExceptionRatio": 0,
"batchLoadRatio": 0,
"cacheHitCount": 0,
"cacheHitRatio": 0,
"loadCount": 0,
"loadErrorCount": 0,
"loadErrorRatio": 0
},
"LD-com.shopline.pixiu.pcq.storefront.api.ProductStorefrontQueryV2Service-onlineStoreUrl": {
"batchInvokeCount": 0,
"batchLoadCount": 0,
"batchLoadExceptionCount": 0,
"batchLoadExceptionRatio": 0,
"batchLoadRatio": 0,
"cacheHitCount": 0,
"cacheHitRatio": 0,
"loadCount": 0,
"loadErrorCount": 0,
"loadErrorRatio": 0
},
"LD-com.shopline.pixiu.pcq.storefront.api.ProductStorefrontQueryV2Service-options": {
"batchInvokeCount": 0,
"batchLoadCount": 0,
"batchLoadExceptionCount": 0,
"batchLoadExceptionRatio": 0,
"batchLoadRatio": 0,
"cacheHitCount": 0,
"cacheHitRatio": 0,
"loadCount": 0,
"loadErrorCount": 0,
"loadErrorRatio": 0
},
"LD-com.shopline.pixiu.pcq.storefront.api.ProductStorefrontQueryV2Service-publishedAtForLoader": {
"batchInvokeCount": 0,
"batchLoadCount": 0,
"batchLoadExceptionCount": 0,
"batchLoadExceptionRatio": 0,
"batchLoadRatio": 0,
"cacheHitCount": 0,
"cacheHitRatio": 0,
"loadCount": 0,
"loadErrorCount": 0,
"loadErrorRatio": 0
},
"LD-com.shopline.pixiu.pcq.storefront.api.ProductStorefrontQueryV2Service-template": {
"batchInvokeCount": 0,
"batchLoadCount": 0,
"batchLoadExceptionCount": 0,
"batchLoadExceptionRatio": 0,
"batchLoadRatio": 0,
"cacheHitCount": 0,
"cacheHitRatio": 0,
"loadCount": 0,
"loadErrorCount": 0,
"loadErrorRatio": 0
},
"LD-com.shopline.pixiu.pcq.storefront.api.ProductStorefrontQueryV2Service-variants": {
"batchInvokeCount": 0,
"batchLoadCount": 0,
"batchLoadExceptionCount": 0,
"batchLoadExceptionRatio": 0,
"batchLoadRatio": 0,
"cacheHitCount": 0,
"cacheHitRatio": 0,
"loadCount": 0,
"loadErrorCount": 0,
"loadErrorRatio": 0
},
"LD-com.shopline.pixiu.pcq.storefront.api.ProductStorefrontQueryV2Service-variantsForLoader": {
"batchInvokeCount": 0,
"batchLoadCount": 0,
"batchLoadExceptionCount": 0,
"batchLoadExceptionRatio": 0,
"batchLoadRatio": 0,
"cacheHitCount": 0,
"cacheHitRatio": 0,
"loadCount": 0,
"loadErrorCount": 0,
"loadErrorRatio": 0
}
},
"overall-statistics": {
"batchInvokeCount": 0,
"batchLoadCount": 0,
"batchLoadExceptionCount": 0,
"batchLoadExceptionRatio": 0,
"batchLoadRatio": 0,
"cacheHitCount": 0,
"cacheHitRatio": 0,
"loadCount": 0,
"loadErrorCount": 0,
"loadErrorRatio": 0
}
},
"metrics": {
"dataFetcherMetrics": [
{
"dfErrorCode": null,
"dfProtocol": "dubbo",
"dfRootCoordinate": "/membershipToggles",
"dfRt": 16,
"dfServiceIdentity": "com.shopline.ec.openapi.interfaces.MemberStoreFrontApi@storeSwitchInfoQuery",
"dfStartTime": 1721889831418
}
],
"graphQLMetrics": {
"appId": "265337",
"appKey": "936eda168305ed82cee702c6822354ee6de2e802",
"clientIp": "218.253.130.212",
"countryCode": null,
"customizedClientIp": "218.253.130.212",
"deepLevel": 2,
"endParseTimeMillis": 1721889831416,
"errorFieldsCount": 0,
"executionId": "a576905b-3a3f-4212-b114-b93aaadad8a3",
"fieldCount": 11,
"includeDeprecatedField": false,
"includeQuery": false,
"languageCode": null,
"loaderCount": 0,
"merchantId": "4200114610",
"namespace": "storefront",
"operation": "QUERY",
"parseRt": 0,
"ratelimitPermits": 1,
"ratelimitRemaining": 1,
"rt": 19,
"saleChannel": null,
"startParseTimeMillis": 1721889831416,
"startTimeMillis": 1721889831415,
"storeId": "1641993455937",
"storePlus": false,
"successType": "SUCCESS",
"tenant": "ec20",
"traceId": "b8f29b93d22f10521d0512e4ed889b09",
"version": "v20241201"
}
},
"tracing": {
"duration": 18607532,
"endTime": "2024-07-25T06:43:51.434Z",
"execution": {
"resolvers": [
{
"duration": 16395730,
"fieldName": "membershipToggles",
"parentType": "Query",
"path": [
"membershipToggles"
],
"returnType": "MembershipToggles",
"startOffset": 1963748
},
{
"duration": 6975,
"fieldName": "giftCardToggle",
"parentType": "MembershipToggles",
"path": [
"membershipToggles",
"giftCardToggle"
],
"returnType": "Boolean",
"startOffset": 18445700
},
{
"duration": 3595,
"fieldName": "pointsToggle",
"parentType": "MembershipToggles",
"path": [
"membershipToggles",
"pointsToggle"
],
"returnType": "Boolean",
"startOffset": 18470330
},
{
"duration": 2519,
"fieldName": "storeCreditsToggle",
"parentType": "MembershipToggles",
"path": [
"membershipToggles",
"storeCreditsToggle"
],
"returnType": "Boolean",
"startOffset": 18488763
},
{
"duration": 2169,
"fieldName": "referralToggle",
"parentType": "MembershipToggles",
"path": [
"membershipToggles",
"referralToggle"
],
"returnType": "Boolean",
"startOffset": 18506026
},
{
"duration": 1901,
"fieldName": "membershipToggle",
"parentType": "MembershipToggles",
"path": [
"membershipToggles",
"membershipToggle"
],
"returnType": "Boolean",
"startOffset": 18518663
}
]
},
"parsing": {
"duration": 169078,
"startOffset": 213887
},
"startTime": "2024-07-25T06:43:51.415Z",
"validation": {
"duration": 222089,
"startOffset": 540141
},
"version": 1
}
}
}
Was this article helpful to you?