logout Mutation
Description
Logs out the current user session.
mutation logout($checkoutId: String) {
logout(checkoutId: $checkoutId) {
ok
checkout {
_id
id
configRef
origin
created
orderId
updated
expires
status
message
useSingleAddress
}
}
}
Variables
{
"checkoutId": "checkoutId"
}
Response
{
"logout": {
"ok": true,
"checkout": {
"_id": "9f1ba5c75e7fe58135ee6855",
"id": "cpZ-XB8x0",
"configRef": "ededccc32b9ac45690345da8",
"origin": "example",
"created": 1769732912279,
"orderId": "example",
"updated": 1723572204740,
"expires": 1743826383821,
"status": "example",
"message": "example",
"useSingleAddress": true
}
}
}
Arguments
| Name | Type | Description |
|---|---|---|
checkoutId | String | Optional checkout identifier to preserve. |