Files
medusa-store/www/apps/docs/content/references/services/classes/GiftCardTransaction.mdx
Shahed Nasser c51dce164d docs: general fixes to references (#5653)
* fixed typedoc plugin's escape strategy

* move props comments to the associated property

* regenerate references
2023-11-17 19:36:58 +02:00

126 lines
2.7 KiB
Plaintext

---
displayed_sidebar: servicesSidebar
---
import ParameterTypes from "@site/src/components/ParameterTypes"
# GiftCardTransaction
Gift Card Transactions are created once a Customer uses a Gift Card to pay for their Order.
## Constructors
### constructor
`**new GiftCardTransaction**()`
Gift Card Transactions are created once a Customer uses a Gift Card to pay for their Order.
## Properties
<ParameterTypes parameters={[
{
"name": "amount",
"type": "`number`",
"description": "The amount that was used from the Gift Card.",
"optional": false,
"defaultValue": "",
"expandable": false,
"children": []
},
{
"name": "created_at",
"type": "`Date`",
"description": "The date with timezone at which the resource was created.",
"optional": false,
"defaultValue": "",
"expandable": false,
"children": []
},
{
"name": "gift_card",
"type": "[GiftCard](GiftCard.mdx)",
"description": "The details of the gift card associated used in this transaction.",
"optional": false,
"defaultValue": "",
"expandable": true,
"children": []
},
{
"name": "gift_card_id",
"type": "`string`",
"description": "The ID of the Gift Card that was used in the transaction.",
"optional": false,
"defaultValue": "",
"expandable": false,
"children": []
},
{
"name": "id",
"type": "`string`",
"description": "The gift card transaction's ID",
"optional": false,
"defaultValue": "",
"expandable": false,
"children": []
},
{
"name": "is_taxable",
"type": "`boolean`",
"description": "Whether the transaction is taxable or not.",
"optional": false,
"defaultValue": "",
"expandable": false,
"children": []
},
{
"name": "order",
"type": "[Order](Order.mdx)",
"description": "The details of the order that the gift card was used for payment.",
"optional": false,
"defaultValue": "",
"expandable": true,
"children": []
},
{
"name": "order_id",
"type": "`string`",
"description": "The ID of the order that the gift card was used for payment.",
"optional": false,
"defaultValue": "",
"expandable": false,
"children": []
},
{
"name": "tax_rate",
"type": "`null` \\| `number`",
"description": "The tax rate of the transaction",
"optional": false,
"defaultValue": "",
"expandable": false,
"children": []
}
]} />
## Methods
### beforeInsert
`Private **beforeInsert**(): void`
#### Returns
`void`
<ParameterTypes parameters={[
{
"name": "void",
"type": "`void`",
"optional": true,
"defaultValue": "",
"description": "",
"expandable": false,
"children": []
}
]} />