Search
K
Illustration

Calculate age

Calculates age based on date of birth and as-of date using specified calculation method

post
https://dev.api.zinnia.io/illustration/v3/utility/calculateAge

Body

application/json

Age calculation request containing date of birth, as-of date, and calculation method

Age-Calculation-Request

dateOfBirthstring(date)required

Date of birth in ISO-8601 format

Example:1990-08-25

asOfDatestring(date)required

As-of date in ISO-8601 format

Example:2025-08-25

calculationMethodstringrequired

Age calculation method - AGE_LAST for age at last birthday, AGE_NEAREST for age at nearest birthday

Allowed values:AGE_LASTAGE_NEAREST

Example:AGE_LAST

Response

application/json

Age calculation completed successfully

Age-Calculation-Response

ageinteger

Calculated age

Example:35

monthsSinceLastBirthdayinteger

Number of months since last birthday

Example:0

post/illustration/v3/utility/calculateAge

Body

{ "dateOfBirth": "1990-08-25", "asOfDate": "2025-08-25", "calculationMethod": "AGE_LAST" }
 
application/json

Age-Calculation-Request

object
dateOfBirthstring(date)required

Date of birth in ISO-8601 format

Example:1990-08-25

asOfDatestring(date)required

As-of date in ISO-8601 format

Example:2025-08-25

calculationMethodstringrequired

Age calculation method - AGE_LAST for age at last birthday, AGE_NEAREST for age at nearest birthday

Allowed values:AGE_LASTAGE_NEAREST

Example:AGE_LAST

Example

Age-Calculation-Response

object
ageinteger

Calculated age

Example:35

monthsSinceLastBirthdayinteger

Number of months since last birthday

Example

Age-Calculation-Method

string

Age calculation method - AGE_LAST for age at last birthday, AGE_NEAREST for age at nearest birthday

Allowed values:AGE_LASTAGE_NEAREST

Example

Illustration Request

Fundamental Illustration request schema. See the schema for a specific product

calculationTypestringrequired

Type of calculation. Only SINGLE_ILLUSTRATION triggers a PDF to be generated.

Allowed values:QUICK_QUOTESINGLE_ILLUSTRATIONAGGREGATE_ILLUSTRATIONCOMPOSITE_ILLUSTRATIONPOLICY_PAGE_PROJECTIONINITIAL_QUOTE

Example:QUICK_QUOTE

sourcestring

Source of the request

Example:ZINNIA

illustrationRequestDatestring(date)required

Date (with pattern “yyyy-mm-dd”)

Match pattern:([0-9]{4})-([0-9]{2})-([0-9]{2})

Example:2025-05-13

jurisdictionstringrequired

Allowed values:AKALARASAZCACOCTDCDEFLGAGUHIIAIDILINKSKYLAMAMDMEMIMNMOMPMSMTNCNDNENHNJNMNVNYOHOKORPAPRRISCSDTNTXUMUTVAVIVTWAWIWVWY

planCodestringrequired

Plan code

Example:EG123

coveragesarray[object]required

A benefit conferred to a group of one or more participants

Show Child Parameters
partiesAny Of
arrayrequiredunique-items

Must have at least one party representing the Insured participant

>= 1 items

Non-Insured Partyobject

Represents a party with a roleCode other than INSURED

Show Child Parameters
optionsobject

Fundamental Options schema. Some products may have product-specific Options.

Show Child Parameters
reportsobject
Show Child Parameters
Example