CreateProduct

@Summary(value = "Create a product")
data class CreateProduct(val name: String, val price: BigDecimal, val description: String = "", val brandId: String? = null, val categoryId: String? = null)

Adds a draft product named name at price to the catalog. The brandId and categoryId name a brand and a category of this context; a product can be created without them, but is published only with both.

Constructors

Link copied to clipboard
constructor(name: String, price: BigDecimal, description: String = "", brandId: String? = null, categoryId: String? = null)

Properties

Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
@NotBlank
val name: String
Link copied to clipboard
@Positive
val price: BigDecimal