Create a card
To create an order in Toggle, make a mutation request to createOrder
. The typical use cases for this type of integration are;
Digital sales - Toggle fulfils
Digital sales - Partner fulfils
Physical Sales - Toggles warehouse fulfils
If you would like Toggle to fulfil the email to the guest, then you will need to ensure that;
fulfilment_method_id
= 1fulfilment_email
= guest to receive gift card
mutation CreateOrder {
createOrder(
account_id: 1
currency: "GBP"
merchant_id: 24
group_fulfilment: true
auto_fulfil_group_fulfilment: false
group_fulfilment_postage_category_id: 576
group_fulfilment_address: {
name: "John Smith"
address_line_1: "123 made up street"
address_line_2: "Tixall"
town_city: "Sheffield"
postcode: "S01 1AA"
}
merchant_transaction_reference: "abc-def-123-123-423-aaasdf105"
unit_epos_reference: "2251799825000010"
total: 6000
sales_channel_id: 3
order_items: [
{
product_id: 3983
custom_price_modifier_value: 5000
fulfilment_method_id: 2
generate_card_reference: false
}
]
receipt_contact: {
email: "[email protected]"
first_name: "john"
last_name: "smith"
}
) {
id,
LineItems{
id
Card{
id
card_reference
pin
balance
expiry_time
card_alias_card_reference
product_name
}
}
}
}
Last updated