接口访问需要令牌,具体如何获取令牌请参考:身份认证
查询单个客户的积分信息,包括店铺内积分名称和该客户剩余可用积分数。
Arguments
customerAccessToken ● String!non-null
客户访问令牌
Return
pointName ● String
积分名称
pointsBalance ● UnsignedInt64
剩余可用积分数
错误码
关于更多通用错误码说明,参考:状态码和错误码
Example
查询积分信息
query {
pointsInfo(customerAccessToken: "#A01#SID0000107BFtXMBlyur1bUgz8HQ7Vi9lQOkT4kXELZOkxlc67dSOPxelgAPrqJh6ksFYHK2D59u9Rk87uTVEY06k4wsOtqd5qxpM8LQ8rcz9RkKQv3aSVwcBzDbhohwVN0sHHLP/3IhqZLhQEQ099BsUc/isnWOUFu9mufoeOIuJFADGqBLnqomPq6osfQsGev0VLZpD6Aw") {
pointName
pointsBalance
}
}
Response
{
"data": {
"pointsInfo": {
"pointsBalance": "100",
"pointName": "Points"
}
},
"extensions": {
"dataloader": {
"individual-statistics": {
"LD-com.shopline.pixiu.pcq.storefront.api.ProductStorefrontQueryV2Service-publishedAtForLoader": {
"loadErrorCount": 0,
"batchInvokeCount": 0,
"cacheHitCount": 0,
"cacheHitRatio": 0,
"loadErrorRatio": 0,
"batchLoadCount": 0,
"batchLoadExceptionCount": 0,
"batchLoadExceptionRatio": 0,
"batchLoadRatio": 0,
"loadCount": 0
},
"LD-com.shopline.pixiu.pcq.storefront.api.ProductStorefrontQueryV2Service-template": {
"cacheHitRatio": 0,
"loadErrorRatio": 0,
"batchLoadExceptionCount": 0,
"loadCount": 0,
"loadErrorCount": 0,
"batchInvokeCount": 0,
"batchLoadCount": 0,
"batchLoadExceptionRatio": 0,
"batchLoadRatio": 0,
"cacheHitCount": 0
},
"LD-com.shopline.pixiu.pcq.storefront.api.ProductStorefrontQueryV2Service-variantsForLoader": {
"batchInvokeCount": 0,
"batchLoadCount": 0,
"batchLoadExceptionRatio": 0,
"batchLoadRatio": 0,
"cacheHitRatio": 0,
"loadCount": 0,
"loadErrorRatio": 0,
"batchLoadExceptionCount": 0,
"cacheHitCount": 0,
"loadErrorCount": 0
},
"LD-com.shopline.merchant.website.openapi.interfaces.OnlineStorefrontApi-commentsQuery": {
"batchInvokeCount": 0,
"batchLoadCount": 0,
"batchLoadExceptionCount": 0,
"batchLoadExceptionRatio": 0,
"batchLoadRatio": 0,
"loadCount": 0,
"cacheHitCount": 0,
"cacheHitRatio": 0,
"loadErrorCount": 0,
"loadErrorRatio": 0
},
"LD-com.shopline.pixiu.pcq.storefront.api.ProductStorefrontQueryV2Service-onlineStoreUrl": {
"cacheHitCount": 0,
"loadCount": 0,
"loadErrorRatio": 0,
"batchInvokeCount": 0,
"batchLoadCount": 0,
"cacheHitRatio": 0,
"loadErrorCount": 0,
"batchLoadExceptionCount": 0,
"batchLoadExceptionRatio": 0,
"batchLoadRatio": 0
},
"LD-com.shopline.pixiu.pcq.storefront.api.ProductStorefrontQueryV2Service-variants": {
"loadErrorCount": 0,
"loadErrorRatio": 0,
"batchInvokeCount": 0,
"batchLoadExceptionCount": 0,
"batchLoadRatio": 0,
"loadCount": 0,
"batchLoadCount": 0,
"batchLoadExceptionRatio": 0,
"cacheHitCount": 0,
"cacheHitRatio": 0
},
"LD-com.shopline.pixiu.pcq.storefront.api.CollectionStorefrontQueryService-onlineStoreUrl": {
"batchLoadRatio": 0,
"cacheHitCount": 0,
"cacheHitRatio": 0,
"loadErrorCount": 0,
"loadErrorRatio": 0,
"batchInvokeCount": 0,
"batchLoadCount": 0,
"batchLoadExceptionRatio": 0,
"loadCount": 0,
"batchLoadExceptionCount": 0
},
"LD-com.shopline.pixiu.pcq.storefront.api.CollectionStorefrontQueryService-queryCollectionByProduct": {
"loadErrorCount": 0,
"batchInvokeCount": 0,
"batchLoadExceptionRatio": 0,
"cacheHitRatio": 0,
"loadCount": 0,
"loadErrorRatio": 0,
"batchLoadCount": 0,
"batchLoadExceptionCount": 0,
"batchLoadRatio": 0,
"cacheHitCount": 0
},
"LD-com.shopline.pixiu.pcq.storefront.api.DescriptionQueryService-query": {
"batchInvokeCount": 0,
"batchLoadExceptionRatio": 0,
"cacheHitRatio": 0,
"loadErrorCount": 0,
"batchLoadCount": 0,
"batchLoadExceptionCount": 0,
"batchLoadRatio": 0,
"cacheHitCount": 0,
"loadCount": 0,
"loadErrorRatio": 0
},
"LD-com.shopline.pixiu.pcq.storefront.api.ProductStorefrontQueryV2Service-images": {
"batchInvokeCount": 0,
"batchLoadCount": 0,
"batchLoadExceptionCount": 0,
"cacheHitCount": 0,
"cacheHitRatio": 0,
"loadCount": 0,
"batchLoadExceptionRatio": 0,
"batchLoadRatio": 0,
"loadErrorCount": 0,
"loadErrorRatio": 0
},
"LD-com.shopline.pixiu.pcq.storefront.api.ProductStorefrontQueryV2Service-options": {
"batchLoadExceptionCount": 0,
"cacheHitCount": 0,
"loadErrorCount": 0,
"batchLoadCount": 0,
"batchLoadExceptionRatio": 0,
"batchLoadRatio": 0,
"cacheHitRatio": 0,
"loadCount": 0,
"loadErrorRatio": 0,
"batchInvokeCount": 0
}
},
"overall-statistics": {
"loadCount": 0,
"loadErrorRatio": 0,
"batchInvokeCount": 0,
"batchLoadCount": 0,
"batchLoadExceptionCount": 0,
"cacheHitCount": 0,
"cacheHitRatio": 0,
"loadErrorCount": 0,
"batchLoadExceptionRatio": 0,
"batchLoadRatio": 0
}
},
"metrics": {
"graphQLMetrics": {
"endParseTimeMillis": 1721889217677,
"rt": 54,
"appId": "265337",
"executionId": "7d5303b2-d826-47d1-a2ad-3ea2b7b76322",
"fieldCount": 5,
"includeQuery": false,
"version": "v20241201",
"deepLevel": 2,
"loaderCount": 0,
"startParseTimeMillis": 1721889217677,
"storeId": "1641993455937",
"successType": "SUCCESS",
"appKey": "936eda168305ed82cee702c6822354ee6de2e802",
"includeDeprecatedField": false,
"merchantId": "4200114610",
"operation": "QUERY",
"ratelimitPermits": 1,
"startTimeMillis": 1721889217677,
"clientIp": "218.253.130.212",
"customizedClientIp": "218.253.130.212",
"languageCode": null,
"saleChannel": null,
"storePlus": false,
"tenant": "ec20",
"errorFieldsCount": 0,
"parseRt": 0,
"traceId": "0f954f3b4628927226cd383c5aefdde8",
"countryCode": null,
"namespace": "storefront",
"ratelimitRemaining": 1
},
"dataFetcherMetrics": [
{
"dfProtocol": "dubbo",
"dfRootCoordinate": "/pointsInfo",
"dfRt": 51,
"dfServiceIdentity": "com.shopline.ec.openapi.interfaces.MemberStoreFrontApi@pointInfoAccount",
"dfStartTime": 1721889217679,
"dfErrorCode": null
}
]
},
"tracing": {
"version": 1,
"duration": 53949277,
"endTime": "2024-07-25T06:33:37.731Z",
"execution": {
"resolvers": [
{
"parentType": "Query",
"path": [
"pointsInfo"
],
"returnType": "PointsInfo",
"startOffset": 1652543,
"duration": 52025994,
"fieldName": "pointsInfo"
},
{
"fieldName": "pointName",
"parentType": "PointsInfo",
"path": [
"pointsInfo",
"pointName"
],
"returnType": "String",
"startOffset": 53808561,
"duration": 9133
},
{
"parentType": "PointsInfo",
"path": [
"pointsInfo",
"pointsBalance"
],
"returnType": "UnsignedInt64",
"startOffset": 53837119,
"duration": 2544,
"fieldName": "pointsBalance"
}
]
},
"parsing": {
"duration": 187572,
"startOffset": 219189
},
"startTime": "2024-07-25T06:33:37.677Z",
"validation": {
"duration": 200704,
"startOffset": 521479
}
}
}
}
这篇文章对你有帮助吗?