SDK API - 상품 상세 조회
기본정보
- 스팀은 다른 스토어와 다르게 스팀에서 상품관리 및 상품 정보를 제공해주지 않아서 직접 관리가 필요합니다.
- 빌링 시스템에서 상품을 관리해드리고 있으며 해당 상품의 상세 정보를 제공하는 API
- 현재 스팀에서 지원하는 통화만 처리하였으며, 이를 기반으로 국가 코드도 처리하고 있습니다.
- 관리툴에서 모든 통화를 등록할 필요는 없으며, 없을 경우 관리툴 등록 시 기본으로 설정한 값으로 응답합니다.
- 개발을 위해선 상품이 먼저 빌링 시스템에 등록되어있어야 합니다.
| 항목 | 내용 | 비고 |
|---|---|---|
| 호출주체 | Game Platform SDK | |
| 도메인 | 각 환경별 도메인 | |
| 인증 방식 | 없음 | |
| HTTP 메소드 | POST | |
| Content-Type | application/json |
Request
HTTP Request end point
POST https://{각 환경별 빌링시스템 도메인}/billing/him-platform-sdk/v1/steam/product/details
HTTP Request Body
| 이름 | 데이터타입 | 필수 여부 | 설명 | 예 |
|---|---|---|---|---|
| pjid | String(20) | Y | 프로젝트ID
| 1004 |
| productType | String | Y | 상품 종류
| INAPP |
| productIds | [String] | Y | 상품 정보를 조회하고자 하는 Product ID
| ["test.item.gem","test.item.ruby"] |
| languageCode | String | Y | 사용자 디바이스에서 사용중인 Language code. BCP-47 format
| en-US |
| currency | String | Y |
| |
| steamId | long | Y | Steam ID of user making purchase
|
Response
- ProductIds에 존재하지 않는 값인 경우 응답값에서 제외됩니다.
- N건의 상품을 지원하기 위해서 아래 데이터셋이 array List로 응답됩니다.
| 이름 | 데이터타입 | 설명 | 예 |
|---|---|---|---|
| productId | String | 조회 요청한 상품 아이디 | steam_test_product_01 |
| productIdNo | uint32 | uint32타입의 상품 아이디
| 1827203053 |
| name | String | 상품 명
| 100 GEM |
| description | String | 상품 상세 설명
| Get 100 gems |
| priceMicros | String | micro 단위의 가격
| 1200000000 |
| formattedPrice | String | 현지화된 가격 정보
| ₩1,200 |
| currency | String | 통화
| KRW |
Success sample
{
"resultCode": "SUCCESS",
"resultMessage": "request success",
"resultData": [
{
"productId": "steam_test_item_01",
"productIdNo": 850212141,
"name": "젬 100개",
"description": "젬 100개 지급",
"priceMicros": "990000",
"formattedPrice": "$0.99",
"currency": "USD"
},
{
"productId": "steam_test_item_02",
"productIdNo": 4003161157,
"name": "젬 100개",
"description": "젬 100개 지급",
"priceMicros": "990000",
"formattedPrice": "$0.99",
"currency": "USD"
},
{
"productId": "steam_test_item_03",
"productIdNo": 3628703750,
"name": "젬 100개",
"description": "젬 100개 지급",
"priceMicros": "990000",
"formattedPrice": "$0.99",
"currency": "USD"
}
]
}
Error sample
- 조회된 데이터가 없는 경우 (요청한 모든 productIds의 데이터가 없는 경우도 해당)
{
"resultCode": "NOT_EXIST_DATA",
"resultMessage": "요청한 파라미터에 대한 데이터가 없음. pjid: '1201', payment: 'STEAM'.",
"resultData": null
}
- 요청 값이 올바르지 않은 경우
{
"resultCode": "INVALID_PARAMETER",
"resultMessage": "'productIds' must be 1 ~ 20 in size. | productIds is not empty",
"resultData": null
}
요청 curl 샘플
- 도메인 및 요청 값은 변경 필요
curl --location 'https://api-dev.pub-dev.hybegames.io/billing/him-platform-sdk/v1/steam/product/details' \
--header 'Content-Type: application/json' \
--data '{
"pjid":"1201",
"productType":"INAPP",
"productIds":["steam_test_item_01", "steam_test_item_02", "steam_test_item_03"],
"languageCode":"ko-KR",
"currency": "USD"
}'