Skip to Content
StoreOSv0.27.1
Storefront GraphQL APIReferenceObjects

Coupon

typeCoupon

Fields

  1. fields
_id*ID!
usesLimit*Int!
isAutoGenerated*Boolean!
code*String!
value*Float!

The value of the coupon

valueType*CouponValueType!

The value type of the coupon. Can be either PRICE or PERCENTAGE

Value inPRICEPERCENTAGE
maxAllowedValue?Float

The maximum value that can be redeemed by a single user. If not provided or -1 then there is no limit.

grantType?CouponGrantType
Value inSPECIFIC_USERSGLOBAL
grantedUsers?

The users that are granted access to this coupon

applicableForMinimumExpense?Float

This is the minimum expense that is required to redeem the coupon

validTill?DateTime

The valid till date. If not provided then the coupon is valid forever

createdAt*DateTime!

A date-time string at UTC, such as 2019-12-03T09:54:33Z, compliant with the date-time format.

updatedAt*DateTime!

A date-time string at UTC, such as 2019-12-03T09:54:33Z, compliant with the date-time format.

commits?
isDemo?Boolean
tenant?String
SDL
type Coupon {  _id: ID!  usesLimit: Int!  isAutoGenerated: Boolean!  code: String!  value: Float!  valueType: CouponValueType!  maxAllowedValue: Float  grantType: CouponGrantType  grantedUsers: [User!]  applicableForMinimumExpense: Float  validTill: DateTime  createdAt: DateTime!  updatedAt: DateTime!  commits: [ResourceCommitHistoryReference!]  isDemo: Boolean  tenant: String}