Skip to main content

$endsWith

$endsWith(string?, suffix) -> boolean
Compact type signature<s-s:b>

If string is omitted, the current context value is used.

Browse categories

Source: FUME

Documentation

Returns true if str ends with the sequence chars, false otherwise.

Examples

Check a suffix

Input

This example uses the eligibility example input. The expression reads plan.planCode and checks its suffix.

Example input

JSON
{
"memberId": "mbr-3001",
"patientId": "pat-0001",
"plan": {
"planCode": "PLAN-100",
"planName": "ExampleCare Standard"
},
"active": true,
"effective": {
"start": "2026-01-01",
"end": "2026-12-31"
},
"copay": {
"visit": 25,
"urgentCare": 50
},
"deductibleRemaining": 300
}

Expression

$endsWith(plan.planCode, "100")

Result

true