Skip to content

Instantly share code, notes, and snippets.

@480
Last active November 3, 2017 13:51
Show Gist options
  • Save 480/cd10cacb886b4f9256cf5c05d5b36bb3 to your computer and use it in GitHub Desktop.
Save 480/cd10cacb886b4f9256cf5c05d5b36bb3 to your computer and use it in GitHub Desktop.
swagger: "2.0"
info:
description: "μ—¬λŸ¬ λ§ˆμΌ“μ„ ν•˜λ‚˜μ˜ API둜 톡합 연동 ν•  수 μžˆμŠ΅λ‹ˆλ‹€. `RESTful API`둜 제곡되며, `snake_case`λ₯Ό μ‚¬μš© ν•©λ‹ˆλ‹€."
version: 4.0.0
title: PLAYAPI ENGINES API V4
termsOfService: "http://www.playauto.co.kr/"
contact:
email: "[email protected]"
license:
name: PLAYAUTO INC (ISC)
host: engines.playapi.io
basePath: /v4
tags:
- name: products
description: μƒν’ˆ API
schemes:
- https
consumes:
- application/json
produces:
- application/json
# -----------------------------------------
# Endpoint μ •μ˜ μ‹œμž‘
# -----------------------------------------
paths:
/products:
post:
tags:
- products
summary: λ§ˆμΌ“μ— μƒν’ˆμ„ 등둝 ν•©λ‹ˆλ‹€.
description: ""
parameters:
- in: body
name: products
description: 등둝 데이터
required: true
schema:
type: array
items:
$ref: "#/definitions/product"
responses:
200:
description: 처리 결과
400:
description: Invalid input
500:
description: Server Error
# -----------------------------------------
# λͺ¨λΈ μ •μ˜ μ‹œμž‘
# - product
# - product_item
# - product_ids
# - shipping
# -----------------------------------------
definitions:
product:
description: μƒν’ˆ λͺ¨λΈ (ν•˜μœ„μ— μ—¬λŸ¬κ°œμ˜ SKU μƒν’ˆμœΌλ‘œ ꡬ성 λ©λ‹ˆλ‹€.)
properties:
market_account_uuid:
description: 등둝할 판맀자 계정 고유ID
type: string
market_category_id:
description: λ§ˆμΌ“ μΉ΄ν…Œκ³ λ¦¬ ID
type: string
parent_sku:
description: μƒν’ˆ κ·Έλ£Ή μ½”λ“œ (이 값은 `λΆ€λͺ¨ SKU`둜 μ‚¬μš© λ©λ‹ˆλ‹€.)
type: string
parent_title:
description: κ·Έλ£Ή λŒ€ν‘œ μƒν’ˆλͺ…
type: string
items:
description: SKU λ‹¨μœ„μ˜ μžμ‹ μƒν’ˆ λͺ©λ‘ (μ„ νƒν˜• μ˜΅μ…˜μœΌλ‘œ 등둝)
type: array
items:
$ref: "#/definitions/product_item"
main_sku:
description: μžμ‹ μƒν’ˆ λͺ©λ‘ 쀑, λΆ€λͺ¨ μƒν’ˆμ—μ„œ λŒ€ν‘œλ‘œ μ‚¬μš©ν•  μƒν’ˆ SKUκ°’
type: string
addon_items:
description: SKU λ‹¨μœ„μ˜ μΆ”κ°€ ꡬ맀 μƒν’ˆ λͺ©λ‘ (일뢀 λ§ˆμΌ“μ€ μ§€μ›ν•˜μ§€ μ•ŠμŒ)
type: array
items:
$ref: "#/definitions/product_item"
shipping:
type: string
description: 배솑 정보 ꡬ성쀑
setform_uuid:
description: μ„ΈνŠΈνΌ 고유 ID
type: string
required:
- market_account_uuid
- setform_uuid
- sku
- market_category_id
- product_name
- product_items
- master_sku
- shipping
# μƒν’ˆ sku λ‹¨μœ„ λͺ¨λΈ
product_item:
description: SKU λ‹¨μœ„ μƒν’ˆ λͺ¨λΈ
properties:
sku:
description: μƒν’ˆ SKU
type: string
product_ids:
$ref: "#/definitions/product_ids"
title:
description: μƒν’ˆλͺ…
type: string
currency:
description: 적용 톡화
type: string
enum: [USD,CAD,EUR,KRW,JPY,CNY]
standard_price:
description: 정상 νŒλ§€κ°€
type: double
sale:
description: 세일 μ„€μ •
properties:
start_date:
description: 세일 μ‹œμž‘μΌ
type: datetime
end_date:
description: 세일 μ’…λ£ŒμΌ
type: datetime
sale_price:
description: 세일 νŒλ§€κ°€
type: double
promo_tag:
description: ν”„λ‘œλͺ¨μ…˜
properties:
promo_type:
description: ν”„λ‘œλͺ¨μ…˜ νƒ€μž…
type: string
enum: [SALE, NEW, NEWARRIVAL, WEBONLY, CLEARANCE, LIMITEDOFFER, SPECIALOFFER, SPECIALPURCHASE, ONLYINSTORES]
from_data:
description: ν”„λ‘œλͺ¨μ…˜ μ‹œμž‘μΌ
type: date
through_data:
description: ν”„λ‘œλͺ¨μ…˜ μ’…λ£ŒμΌ
type: date
quantity:
description: 재고 μˆ˜λŸ‰
type: integer
tax_code:
description: >
κ³Όμ„Έ μœ ν˜• μ½”λ“œ:
* `GEN_TAX` - 일반 μƒν’ˆ (κ³Όμ„Έ)
* `GEN_NOTAX` - 일반 μƒν’ˆ (λΉ„κ³Όμ„Έ)
* `BOOKS_GEN` - 일반 μ„œμ λ₯˜
* `BOOKS_RELIG` - 쒅ꡐ μ„œμ λ₯˜
type: string
enum: [GEN_TAX, GEN_NOTAX, BOOKS_GEN, BOOKS_RELIG]
condition:
description: μƒν’ˆ μƒνƒœ
properties:
condition_type:
description: >
μƒν’ˆ μƒνƒœ:
* `NEW` - μƒˆ μƒν’ˆ
* `USED_LIKE_NEW` - μƒˆ μƒν’ˆ 같은 쀑고
* `USED_VERY_GOOD` - μƒνƒœ 쒋은 쀑고
* `REFURBISHED` - λ°˜ν’ˆλœ μƒν’ˆ
type: string
enum: [NEW, USED_LIKE_NEW, USED_VERY_GOOD, REFURBISHED]
condition_note:
description: μƒν’ˆ μƒνƒœ μ½”λ©˜νŠΈ
type: string
item_package_quantity:
description: ν•˜λ‚˜μ˜ νŒ¨ν‚€μ§€μ— 포함 된 λ™μΌν•œ μ œν’ˆμ˜ 갯수. 10개의 양말 νŒ¨ν‚€μ§€μ˜ 경우, item_package_quantityλŠ” 10μž…λ‹ˆλ‹€.
type: integer
number_of_items:
description: μ œν’ˆμ— 포함 된 κ°œλ³„ ν’ˆλͺ©μ˜ 수둜, 각 ν’ˆλͺ©μ€ κ°œλ³„ 판맀용으둜 포μž₯λ˜μ§€ μ•ŠμŠ΅λ‹ˆλ‹€. 각 νŒ¨ν‚€μ§€μ— 3쌍의 양말이 λ“€μ–΄μžˆλŠ” 10개 짜리 μƒν’ˆμ˜ 경우 number_of_itemsλŠ” 30μž…λ‹ˆλ‹€.
type: integer
brand:
description: λΈŒλžœλ“œ
type: string
designer:
description: λ””μžμ΄λ„ˆ
type: string
description_text:
description: κΈ΄ μƒν’ˆ μ†Œκ°œ Text (HTML을 μ‚¬μš©ν•  수 μ—†λŠ” λ§ˆμΌ“μš©)
type: string
description_html:
description: κΈ΄ μƒν’ˆ μ†Œκ°œ HTML
type: string
bullet_point:
description: μ œν’ˆ κΈ°λŠ₯에 λŒ€ν•œ κ°„λž΅ν•œ μ„€λͺ…
type: string
item_dimensions:
$ref: "#/definitions/dimensions"
package_dimensions:
$ref: "#/definitions/dimensions"
merchant_catalog_code:
description: 판맀자의 자체 μƒν’ˆ μ½”λ“œ (SKU와 λ‹€λ₯Έ 값인 경우 μ‚¬μš©)
type: string
msrp:
description: μ œμ‘°μ‚¬μ˜ ꢌμž₯ μ†ŒλΉ„μžκ°€
type: double
max_order_quantity:
description: 고객이 μ£Όλ¬Έν•  μˆ˜μžˆλŠ” μ œν’ˆμ˜ μ΅œλŒ€ μˆ˜λŸ‰
type: integer
manufacturer:
description: μ œμ‘°μ‚¬
type: string
search_terms:
description: μ œν’ˆ κ²€μƒ‰μš© ν‚€μ›Œλ“œ (μ΅œλŒ€ 5개)
type: array
items:
type: string
target_audience:
description: ꡬ맀 κ°€λŠ₯ λŒ€μƒ μ œν•œ
type: string
enum: [ADULTS,CHILDREN,MEN,WOMEN]
is_gift_wrap_available:
description: μ„ λ¬Ό 포μž₯ κ°€λŠ₯ μ—¬λΆ€
type: boolean
is_gift_message_available:
description: μ„ λ¬Ό λ©”μ‹œμ§€ 전달 κ°€λŠ₯ μ—¬λΆ€
type: boolean
size:
description: μ‚¬μ΄μ¦ˆ κ°’
type: string
color:
description: 색상 κ°’
type: string
style_name:
description: μŠ€νƒ€μΌ κ°’
type: string
model_number:
description: λͺ¨λΈλͺ…
type: string
country_of_origin:
description: 원산지 κ΅­κ°€ μ½”λ“œ (2자둜 된 κ΅­κ°€μ½”λ“œ)
type: string
country_produced_in:
description: 원산지 ν‘œμ‹œλͺ…
type: string
images:
description: 이미지 URL λͺ©λ‘ (첫번째 url을 메인 μ΄λ―Έμ§€λ‘œ μ‚¬μš©)
type: array
items:
type: string
description: 이미지 URL (http/https)
required:
- sku
- title
- standard_price
- quantity
- tax_code
- condition
- description_text
- description_html
- manufacturer
- size
- color
- images
- country_of_origin
product_ids:
description: μƒν’ˆ ν‘œμ€€ID 정보
properties:
asin:
type: string
description: ASIN (Amazon Standard Identification Numbers)
upc:
type: string
description: UPC (Universal Product Code)
ean:
type: string
description: EAN (European Article Number)
isbn:
type: string
description: ISBN (International Standard Book Number)
hscode:
type: string
description: HS CODE (Harmonized System code)
dimensions:
description: 치수 정보
properties:
unit_of_size_measure:
description: μ‚¬μ΄μ¦ˆ λ‹¨μœ„
enum: [CM,M,IN,FT]
type: string
width:
description: κ°€λ‘œ
type: float
length:
description: μ„Έλ‘œ
type: float
height:
description: 높이
type: float
unit_of_weight_measure:
description: 무게 λ‹¨μœ„
enum: [LB,KG]
type: string
weight:
description: 무게
type: float
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment