On this page
fileClaimWarranty
mutation · in the family Selling
What it does
File a claim on an active warranty — link the customer-service case and the warranty flips to claimed.
File a claim on an ACTIVE Warranty: links a warranty_claim CsCase BOTH ways in ONE transaction (the warranty’s caseId + the case’s warrantyId); the maker/supplier routing is the snapshotted provider. Refuses CONFLICT/EXPIRED on an expired warranty, CONFLICT/REF_STATE on a non-warranty or closed/cancelled case, CONFLICT/REVISION_STALE on a stale expectedRevision; a claimed warranty declares no further edge (claim resolution is the deferred sub-flow).
What happens
The case records the claim; the warranty stays claimed (resolution with the maker or supplier is handled on the case).
Who may call it
Capability area: Selling — Ringing sales, serving customers and issuing invoices.
- Owner
- Manager
- Associate Manager
- Sales Associate
- Cashier
- An API key whose scope allows
api:fileClaimWarranty
Arguments
| Name | Type | Required | Notes |
|---|---|---|---|
input | ClaimWarrantyInput ClaimWarrantyInput! | yes | No further notes. |
Returns
Warranty Warranty! — A Warranty — THE WARRANTY INSTANCE: one sold order line under one WarrantyTerms template. Born by the ENGINE when the sale completes (paid AND delivered) for every variant line whose product carries an active product-attached template or whose variant names a manufacturer carrying an active manufacturer-attached template (one warranty per matching template); never created on the wire. The policy is SNAPSHOTTED at birth (provider · durationDays → expiresAt = startsAt + durationDays), so later template edits never rewrite an issued warranty. active → expired is the scheduler’s over expiresAt; active → claimed is fileClaimWarranty (a warranty_claim CsCase linked both ways). The serial number is optional and stamped through updateWarranty. Listings keep expired warranties as coverage history (the settled-payment class — a status filter narrows to active); every warranty stays reachable by id from the order line’s warrantyIds.
Example request
mutation ExampleFileClaimWarranty($input: ClaimWarrantyInput!) {
fileClaimWarranty(input: $input) {
id
sysId
type
caption
status
parentId
rootId
createdAt
updatedAt
revisionNum
revision
organizationId
orderLineNo
variantId
productId
warrantyTermsId
provider
durationDays
quantity
startsAt
expiresAt
consumerId
serialNumber
caseId
}
}
Variables:
{
"input": {
"warrantyId": "01900000-0000-7000-8000-5da144780000",
"expectedRevision": "01900000-0000-7000-8000-e02b2e6c0000",
"caseId": "01900000-0000-7000-8000-4559fce40000",
"reason": "Correcting a miscount."
}
}
Send it with the envelope naming the version: "extensions": {"at": {"version": {"name":"genesis","number":0}}}.
Example response
{
"data": {
"fileClaimWarranty": {
"id": "01900000-0000-7000-8000-37386ae00000",
"sysId": "WR-EXMP-0000-000F",
"type": "Warranty",
"caption": "Blue jeans",
"status": "active",
"parentId": "01900000-0000-7000-8000-065235280000",
"rootId": "01900000-0000-7000-8000-a093dd800000",
"createdAt": "2027-01-31T00:00:00.000Z",
"updatedAt": "2027-01-31T00:00:00.000Z",
"revisionNum": 1,
"revision": "01900000-0000-7000-8000-b7960e180000",
"organizationId": "01900000-0000-7000-8000-44b781470000",
"orderLineNo": 1,
"variantId": "01900000-0000-7000-8000-8415e73b0000",
"productId": "01900000-0000-7000-8000-969657010000",
"warrantyTermsId": "01900000-0000-7000-8000-d9cacfd90000",
"provider": "manufacturer",
"durationDays": 1,
"quantity": "2",
"startsAt": "2027-01-31T00:00:00.000Z",
"expiresAt": "2027-01-31T00:00:00.000Z",
"consumerId": "01900000-0000-7000-8000-6e8c92ec0000",
"serialNumber": "<serial number>",
"caseId": "01900000-0000-7000-8000-4559fce40000"
}
},
"extensions": {
"at": {
"callId": "01EXAMPLE-CALL-ID",
"version": {
"requested": {
"name": "genesis",
"number": 0
},
"serviced": {
"name": "genesis",
"number": 0
}
}
}
}
}
Errors this call can answer
VALIDATION/INVALID— Something in the request is not valid. (VALIDATION)AUTHN/REQUIRED— Sign in to do this. (AUTHN)AUTHZ/FORBIDDEN— Your role does not allow this action. (AUTHZ)RATE_LIMIT/THROTTLED— Too many requests in a short time. (RATE_LIMIT)NOT_FOUND/*— That record could not be found. (NOT_FOUND)CONFLICT/*— The record’s state, or a change made in the meantime, does not allow this; the codes are on the CONFLICT page. (CONFLICT)VALIDATION/VERSION_REQUIRED— The request did not say which app version it came from. (VALIDATION)