80 lines
1.8 KiB
YAML
80 lines
1.8 KiB
YAML
type: object
|
|
description: The promotion's details.
|
|
x-schemaName: AdminPromotion
|
|
required:
|
|
- id
|
|
- created_at
|
|
- updated_at
|
|
- deleted_at
|
|
properties:
|
|
application_method:
|
|
$ref: ./AdminApplicationMethod.yaml
|
|
rules:
|
|
type: array
|
|
description: The promotion's rules.
|
|
items:
|
|
$ref: ./AdminPromotionRule.yaml
|
|
id:
|
|
type: string
|
|
title: id
|
|
description: The promotion's ID.
|
|
code:
|
|
type: string
|
|
title: code
|
|
description: The promotion's code.
|
|
example: OFF50
|
|
type:
|
|
type: string
|
|
description: The promotion's type.
|
|
enum:
|
|
- standard
|
|
- buyget
|
|
is_automatic:
|
|
type: boolean
|
|
title: is_automatic
|
|
description: >-
|
|
Whether the promotion is applied on a cart automatically if it matches the
|
|
promotion's rules.
|
|
campaign_id:
|
|
type: string
|
|
title: campaign_id
|
|
description: The ID of the campaign this promotion belongs to.
|
|
campaign:
|
|
$ref: ./AdminCampaign.yaml
|
|
created_at:
|
|
type: string
|
|
format: date-time
|
|
title: created_at
|
|
description: The date the promotion was created.
|
|
updated_at:
|
|
type: string
|
|
format: date-time
|
|
title: updated_at
|
|
description: The date the promotion was updated.
|
|
deleted_at:
|
|
type: string
|
|
format: date-time
|
|
title: deleted_at
|
|
description: The date the promotion was deleted.
|
|
status:
|
|
type: string
|
|
description: The promotion's status.
|
|
enum:
|
|
- draft
|
|
- active
|
|
- inactive
|
|
is_tax_inclusive:
|
|
type: boolean
|
|
title: is_tax_inclusive
|
|
description: >-
|
|
Whether the promotion is tax inclusive. If enabled, the promotion is
|
|
applied after tax is calculated.
|
|
limit:
|
|
type: number
|
|
title: limit
|
|
description: The limit of times the promotion can be used.
|
|
used:
|
|
type: number
|
|
title: used
|
|
description: The number of times the promotion has been used.
|