planning-center-monorepo v1.0.0
planning-center-monorepo / planning-center-people-ts/src / PersonMatchOptions
Interface: PersonMatchOptions
Defined in: packages/planning-center-people-ts/src/modules/people.ts:74
Options for finding or creating a person with smart matching
Properties
firstName?
optionalfirstName:string
Defined in: packages/planning-center-people-ts/src/modules/people.ts:76
Person’s first name
lastName?
optionallastName:string
Defined in: packages/planning-center-people-ts/src/modules/people.ts:78
Person’s last name
email?
optionalemail:string
Defined in: packages/planning-center-people-ts/src/modules/people.ts:80
Person’s email address
phone?
optionalphone:string
Defined in: packages/planning-center-people-ts/src/modules/people.ts:82
Person’s phone number
matchStrategy?
optionalmatchStrategy:"exact"|"fuzzy"|"aggressive"
Defined in: packages/planning-center-people-ts/src/modules/people.ts:89
Matching strategy to use:
- ‘exact’: Only return matches with verified email/phone matches (high confidence)
- ‘fuzzy’: Return best match above threshold (default)
- ‘aggressive’: Return best match with lower threshold
searchStrategy?
optionalsearchStrategy:"single"|"multi-step"
Defined in: packages/planning-center-people-ts/src/modules/people.ts:99
Search strategy for finding matches:
- ‘single’: Use only the specified matchStrategy (default)
- ‘multi-step’: Try multiple strategies in order until a match is found:
- Fuzzy with age preference
- Fuzzy without age preference
- Exact with age preference
- Exact without age preference
campusId?
optionalcampusId:string
Defined in: packages/planning-center-people-ts/src/modules/people.ts:101
Campus ID to associate with the person
createIfNotFound?
optionalcreateIfNotFound:boolean
Defined in: packages/planning-center-people-ts/src/modules/people.ts:103
If true, create a new person if no match is found (default: true)
addMissingContactInfo?
optionaladdMissingContactInfo:boolean
Defined in: packages/planning-center-people-ts/src/modules/people.ts:109
If true, automatically add missing email/phone contact information to a person’s profile when a match is found. Missing contacts are added as non-primary to avoid overriding existing primary contacts. (default: false)
agePreference?
optionalagePreference:"adults"|"children"|"any"
Defined in: packages/planning-center-people-ts/src/modules/people.ts:111
Age preference filter: ‘adults’ (18+), ‘children’ (<18), or ‘any’
agePreferenceLenient?
optionalagePreferenceLenient:boolean
Defined in: packages/planning-center-people-ts/src/modules/people.ts:117
When true, age preference filters only apply to profiles with birthdates. Profiles without birthdates are included regardless of agePreference. When false (default), profiles without birthdates only match when agePreference is ‘any’.
minAge?
optionalminAge:number
Defined in: packages/planning-center-people-ts/src/modules/people.ts:119
Minimum age filter
maxAge?
optionalmaxAge:number
Defined in: packages/planning-center-people-ts/src/modules/people.ts:121
Maximum age filter
birthYear?
optionalbirthYear:number
Defined in: packages/planning-center-people-ts/src/modules/people.ts:123
Birth year filter (exact match)
retryConfig?
optionalretryConfig:RetryConfig
Defined in: packages/planning-center-people-ts/src/modules/people.ts:129
Retry configuration for handling PCO contact verification delays. When a person is created, PCO needs time (30-90+ seconds) to verify/index contacts before they become searchable. This retry logic helps prevent duplicate person creation.
retryConfigs?
optionalretryConfigs:object
Defined in: packages/planning-center-people-ts/src/modules/people.ts:134
Phase-specific retry configurations for advanced control. When both retryConfig and retryConfigs are provided, retryConfigs takes precedence.
initial?
optionalinitial:RetryConfig
Configuration for initial/quick search phase (default: 30s max wait)
aggressive?
optionalaggressive:RetryConfig
Configuration for aggressive search before creating (default: 60s max wait)
fallbackToNameSearch?
optionalfallbackToNameSearch:boolean
Defined in: packages/planning-center-people-ts/src/modules/people.ts:145
If true, fall back to name-based search when email/phone search fails. Requires both firstName and lastName to be provided. Uses contact validation to avoid wrong-person matches. (default: false)
contactValidation?
optionalcontactValidation:"strict"|"domain"|"similarity"
Defined in: packages/planning-center-people-ts/src/modules/people.ts:152
Contact validation strategy for name-based search fallback:
- ‘strict’: Requires exact email or phone match
- ‘domain’: Requires matching email domain or similar phone
- ‘similarity’: Uses domain matching for email, similarity for phone (default)