공간 분류 추가
- REQUEST (CURL / GET)
curl --request GET \
--url https://apis.openapi.sk.com/urbanbase/v1/space/classifier \
--header 'Accept: application/json' \
--header 'Content-Type: application/json' \
--header 'appKey: My Project의 Project Key'
- REQUEST (CURL / POST)
curl --request POST \
--url https://apis.openapi.sk.com/urbanbase/v1/space/classifier \
--header 'Accept: application/json' \
--header 'Content-Type: application/json' \
--header 'appKey: My Project의 Project Key'
- REQUEST (SAMPLE CODE)
POST /space/classifier
headers: {
"Content-Type": "application/json"
“appkey”: “{appkey}”
}
body: {
"image_path": "https://upload.wikimedia.org/wikipedia/commons/thumb/c/cf/Wohnzimmer_2007.jpg/220px-Wohnzimmer_2007.jpg"
}
- RESPONSE (200 / JSON)
{
"code": "00000",
"message": "success",
"data": {
"space_image_uuid": "c97b6592-0c94-46a2-8d3f-8491bc7b53df",
"image_path": "https://upload.wikimedia.org/wikipedia/commons/thumb/c/cf/Wohnzimmer_2007.jpg/220px-Wohnzimmer_2007.jpg",
"created_date": "2021-01-11T08:16:37.096Z",
"results": [
{
"label": "homeoffice",
"probability": 0.8091437816619873
},
{
"label": "livingroom",
"probability": 0.1627751588821411
},
{
"label": "room",
"probability": 0.011149944737553596
},
{
"label": "bathroom",
"probability": 0.009833515621721745
},
{
"label": "diningroom",
"probability": 0.004330105148255825
},
{
"label": "kitchen",
"probability": 0.0027601311448961496
},
{
"label": "dressingroom",
"probability": 0.000007311527042475063
}
]
}
}
- RESPONSE (400/ JSON)
{
"code": "12001",
"message": "Invalid image_path"
}
- RESPONSE (PARAMETERS)
Name | Type | Mandatory | Example | Description |
---|---|---|---|---|
code | Number | Y | 응답 상태 코드 | |
message | String | Y | 응답 상태 설명 | |
data | object | Y | 데이터 정보 | |
space_image_uuid | String | Y | 범용 고유 식별자(UUID) | |
image_path | String | Y | 이미지 경로 | |
created_date | Date | Y | 분석 결과 | |
label | String | N | 분류 결과 레이블 | |
probability | Number | N | 분류 결과 확률 (0 ~ 1) |
공간 분류 조회
- REQUEST (CURL / GET)
curl --request GET \
--url https://apis.openapi.sk.com/urbanbase/v1/space/classifier/space_image_uuid \
--header 'Accept: application/json' \
--header 'appKey: My Project의 Project Key'
- REQUEST (CURL / POST)
curl --request POST \
--url https://apis.openapi.sk.com/urbanbase/v1/space/classifier/space_image_uuid \
--header 'Accept: application/json' \
--header 'appKey: My Project의 Project Key'
- REQUEST (SAMPLE CODE)
GET /space/classifier/c97b6592-0c94-46a2-8d3f-8491bc7b53df
headers: {
"Content-Type": "application/json",
“appkey”: “{appkey}”
}
- RESPONSE (200 / JSON)
{
"code": "00000",
"message": "success",
"data": {
"space_image_uuid": "c97b6592-0c94-46a2-8d3f-8491bc7b53df",
"image_path": "https://upload.wikimedia.org/wikipedia/commons/thumb/c/cf/Wohnzimmer_2007.jpg/220px-Wohnzimmer_2007.jpg",
"created_date": "2021-01-11T08:16:37.096Z",
"results": [
{
"label": "homeoffice",
"probability": 0.8091437816619873
},
{
"label": "livingroom",
"probability": 0.1627751588821411
},
{
"label": "room",
"probability": 0.011149944737553596
},
{
"label": "bathroom",
"probability": 0.009833515621721745
},
{
"label": "diningroom",
"probability": 0.004330105148255825
},
{
"label": "kitchen",
"probability": 0.0027601311448961496
},
{
"label": "dressingroom",
"probability": 0.000007311527042475063
}
]
}
}
- RESPONSE (400/ JSON)
{
"code": "40000",
"message": "Not Found"
}
- RESPONSE (PARAMETERS)
Name | Type | Mandatory | Example | Description |
---|---|---|---|---|
code | Number | Y | 응답 상태 코드 | |
message | String | Y | 응답 상태 설명 | |
data | Object | Y | 데이터 정보 | |
space_image_uuid | String | Y | 범용 고유 식별자(UUID) | |
image_path | String | Y | 이미지 경로 | |
created_date | Date | Y | 분석 데이터 생성 시간 | |
results | Object | Y | 분석 결과 | |
label | String | N | 분류 결과 레이블 | |
probability | Number | N | 분류 결과 확률 (0 ~ 1) |