kiolyn-api-specs
Version:
238 lines (232 loc) • 6.37 kB
YAML
/giftcard/{storeid}:
get:
tags:
- giftcard
description: Return all the giftcards belong to given store
operationId: listGiftcards
security:
- bearerAuth: []
parameters:
- $ref#storeid: './parameters/storeid.yaml'
responses:
$ref#4xx: './responses/4xx.yaml'
200:
description: list of giftcard
content:
application/json:
schema:
type: array
items:
$ref: '#/components/schemas/Giftcard'
post:
tags:
- giftcard
description: Update/Create giftcard
operationId: saveGiftcard
security:
- bearerAuth: []
parameters:
- $ref#storeid: './parameters/storeid.yaml'
requestBody:
required: true
content:
application/json:
schema:
$ref: '#/components/schemas/Giftcard'
responses:
$ref#4xx: './responses/4xx.yaml'
$ref#upsert: './responses/20x-upsert.yaml'
/giftcard/{storeid}/{id}:
get:
tags:
- giftcard
description: Return the giftcard with given id
operationId: loadGiftcard
security:
- bearerAuth: []
parameters:
- $ref#storeid: './parameters/storeid.yaml'
- $ref#id: './parameters/objectid.yaml'
responses:
$ref#4xx: './responses/4xx.yaml'
200:
description: giftcard detail
content:
application/json:
schema:
type: object
properties:
value:
$ref: '#/components/schemas/Giftcard'
delete:
tags:
- giftcard
description: Delete a giftcard with given id
operationId: deleteGiftcard
security:
- bearerAuth: []
parameters:
- $ref#storeid: './parameters/storeid.yaml'
- $ref#id: './parameters/objectid.yaml'
responses:
$ref#4xx: './responses/4xx.yaml'
$ref#204: './responses/204.yaml'
/giftcard/{storeid}/import:
post:
tags:
- giftcard
description: Import giftcards by csv file and return an id to track import process.
operationId: importGiftcard
security:
- bearerAuth: []
parameters:
- $ref#storeid: './parameters/storeid.yaml'
requestBody:
content:
multipart/form-data:
schema:
type: object
properties:
file:
type: string
format: binary
responses:
$ref#4xx: './responses/4xx.yaml'
200:
description: data import start
content:
application/json:
schema:
type: object
properties:
importid:
description: import id to track import process
type: string
/merchant/giftcard/{merchantid}:
get:
tags:
- giftcard
description: Return all the giftcards belong to given merchant id.
operationId: listGiftcardsByMerchant
security:
- bearerAuth: []
parameters:
- $ref#merchantid: './parameters/merchantid.yaml'
responses:
$ref#4xx: './responses/4xx.yaml'
200:
description: list of giftcard
content:
application/json:
schema:
type: array
items:
$ref: '#/components/schemas/Giftcard'
post:
tags:
- giftcard
description: Update/Create giftcard by merhcna
operationId: saveGiftcardByMerchantId
security:
- bearerAuth: []
parameters:
- $ref#merchantid: './parameters/merchantid.yaml'
requestBody:
required: true
content:
application/json:
schema:
$ref: '#/components/schemas/Giftcard'
responses:
$ref#4xx: './responses/4xx.yaml'
$ref#upsert: './responses/20x-upsert.yaml'
/merchant/giftcard/{merchantid}/{id}:
get:
tags:
- giftcard
description: Return the giftcard with given id
operationId: loadGiftcardByMerchant
security:
- bearerAuth: []
parameters:
- $ref#merchantid: './parameters/merchantid.yaml'
- $ref#id: './parameters/objectid.yaml'
responses:
$ref#4xx: './responses/4xx.yaml'
200:
description: giftcard detail
content:
application/json:
schema:
type: object
properties:
value:
$ref: '#/components/schemas/Giftcard'
delete:
tags:
- giftcard
description: Delete a giftcard with given id
operationId: deleteGiftcardByMerchant
security:
- bearerAuth: []
parameters:
- $ref#merchantid: './parameters/merchantid.yaml'
- $ref#id: './parameters/objectid.yaml'
responses:
$ref#4xx: './responses/4xx.yaml'
$ref#204: './responses/204.yaml'
/giftcard/{storeid}/{merchantid}/{id}:
get:
tags:
- giftcard
description: transfer giftcard to merchant
operationId: transferGiftcardToMerchant
security:
- bearerAuth: []
parameters:
- $ref#merchantid: './parameters/merchantid.yaml'
- $ref#storeid: './parameters/storeid.yaml'
- $ref#id: './parameters/objectid.yaml'
responses:
$ref#4xx: './responses/4xx.yaml'
200:
description: data transfer start
content:
application/json:
schema:
type: object
properties:
transferid:
description: transfer id to track transfer process
type: string
/merchant/giftcard/{merchantid}/import:
post:
tags:
- giftcard
description: Import giftcards by csv file and return an id to track import process.
operationId: importGiftcardByMerchant
security:
- bearerAuth: []
parameters:
- $ref#merchantid: './parameters/merchantid.yaml'
requestBody:
content:
multipart/form-data:
schema:
type: object
properties:
file:
type: string
format: binary
responses:
$ref#4xx: './responses/4xx.yaml'
200:
description: data import start
content:
application/json:
schema:
type: object
properties:
importid:
description: import id to track import process
type: string