Skip to content

Custom Field Associations

API Endpoint Namespace Supported Generics
member/<member_id>/custom-fields evclient.member.custom_fields(<member>).<method> CRUD

Additional parameters

As member related custom fields are always bound to a specific member, the namespace used for custom field associations requires the member as constructor argument, to avoid passing it again to all endpoints:

Name Type Description Default
member Member | int Identifies the member to modify custom field values on. Can be either an id or a Member object. required

Generic Model Mappings

Generic Model Invoice Model
ModelType MemberCustomField
CreateModelType MemberCustomFieldCreate
UpdateModelType MemberCustomFieldUpdate

Additional Methods

ensure_set

ensure_set(custom_field_id: int, value: str) -> MemberCustomField

Convenience method to set the custom field value on a member, no matter if it was set before already (PATCH) or not.

Regarding rate limiting, be aware that this method requires at least two API calls.

Parameters:

Name Type Description Default
custom_field_id int

Custom field ID that should be set or changed

required
value str

New value the specified custom field should be set to

required