Skip to content

Api reference

components.eligibility.public.entities

AlsaceMoselleParsedData dataclass

AlsaceMoselleParsedData(start_date, end_date)

Bases: DataClassJsonMixin

end_date instance-attribute

end_date

start_date instance-attribute

start_date

DocumentParsingUsedForValidation dataclass

DocumentParsingUsedForValidation(
    id, validation_id, document_id, parsing_version
)

Bases: DataClassJsonMixin

document_id instance-attribute

document_id

id instance-attribute

id

parsing_version instance-attribute

parsing_version

validation_id instance-attribute

validation_id

EligibilityDocumentType

Bases: AlanBaseEnum

Enum representing the type of document used for eligibility validation.

payslip class-attribute instance-attribute

payslip = 'payslip'

tax_notice class-attribute instance-attribute

tax_notice = 'tax_notice'

EligibilityRequest dataclass

EligibilityRequest(
    id,
    status,
    validations,
    documents,
    created_at,
    eligibility_type,
    entity_ref,
    entity_type,
    current_validation,
    parsed_data=None,
    task_ref=None,
)

Bases: DataClassJsonMixin

are_all_documents_parsed property

are_all_documents_parsed

can_be_validated property

can_be_validated

created_at instance-attribute

created_at

current_validation instance-attribute

current_validation

documents instance-attribute

documents

eligibility_type instance-attribute

eligibility_type

entity_ref instance-attribute

entity_ref

entity_type instance-attribute

entity_type

id instance-attribute

id

is_in_final_state property

is_in_final_state

parsed_data class-attribute instance-attribute

parsed_data = None

status instance-attribute

status

task_ref class-attribute instance-attribute

task_ref = None

validations instance-attribute

validations

EligibilityRequestDocument dataclass

EligibilityRequestDocument(
    id, document_ref, status, request_id
)

Bases: DataClassJsonMixin

document_ref instance-attribute

document_ref

id instance-attribute

id

is_processed property

is_processed

request_id instance-attribute

request_id

status instance-attribute

status

EligibilityRequestDocumentStatus

Bases: AlanBaseEnum

Enum representing the status of a eligibility request document.

Attributes:

Name Type Description
uploaded

Indicates that the document has been uploaded.

reparsing

Indicates that the document is being reparsed.

parsed

Indicates that the document has been parsed.

rejected

Indicates that the document has been rejected during parsing.

parsed class-attribute instance-attribute

parsed = 'parsed'

rejected class-attribute instance-attribute

rejected = 'rejected'

reparsing class-attribute instance-attribute

reparsing = 'reparsing'

uploaded class-attribute instance-attribute

uploaded = 'uploaded'

EligibilityRequestEntityType

Bases: AlanBaseEnum

Enum representing the entity type of an eligibility request is linked to.

Attributes:

Name Type Description
user

The eligibility request is linked to a user.

retiree_request

The eligibility request is linked to a retiree request.

retiree_request class-attribute instance-attribute

retiree_request = 'retiree_request'

user class-attribute instance-attribute

user = 'user'

EligibilityRequestStatus

Bases: AlanBaseEnum

Enum representing the status of a eligibility request.

Attributes:

Name Type Description
uploaded

The request has been uploaded.

parsing

The request is currently being parsed.

parsed

The request has been parsed.

rejected

The request has been rejected.

validated

The request has been validated.

not_eligible

The request is not eligible (can happen when there is an extra eligibility step and not simplpy parsing validiation).

not_eligible class-attribute instance-attribute

not_eligible = 'not_eligible'

parsed class-attribute instance-attribute

parsed = 'parsed'

parsing class-attribute instance-attribute

parsing = 'parsing'

rejected class-attribute instance-attribute

rejected = 'rejected'

to_manual_review class-attribute instance-attribute

to_manual_review = 'to_manual_review'

uploaded class-attribute instance-attribute

uploaded = 'uploaded'

validated class-attribute instance-attribute

validated = 'validated'

EligibilityRequestType

Bases: AlanBaseEnum

Enum representing the type of an eligibility request.

Attributes:

Name Type Description
alsace_moselle

The eligibility request is for the Alsace-Moselle regime.

social_funds

The eligibility request is for the social funds.

retiree

The eligibility request is for the retiree.

income

The eligibility request is for income (revenue gathering).

alsace_moselle class-attribute instance-attribute

alsace_moselle = 'alsace_moselle'

income class-attribute instance-attribute

income = 'income'

retiree class-attribute instance-attribute

retiree = 'retiree'

social_funds class-attribute instance-attribute

social_funds = 'social_funds'

EligibilityRequestValidation dataclass

EligibilityRequestValidation(
    id,
    request_id,
    validation_rules,
    document_parsings,
    eligibility_status,
    created_at,
)

Bases: DataClassJsonMixin

created_at instance-attribute

created_at

document_parsings instance-attribute

document_parsings

eligibility_status instance-attribute

eligibility_status

id instance-attribute

id

request_id instance-attribute

request_id

validation_rules instance-attribute

validation_rules

EligibilityRequestValidationRule dataclass

EligibilityRequestValidationRule(
    id, validation_id, rule_type, rule_version, status
)

Bases: DataClassJsonMixin

id instance-attribute

id

rule_type instance-attribute

rule_type

rule_version instance-attribute

rule_version

status instance-attribute

status

validation_id instance-attribute

validation_id

EligibilityRequestValidationRuleStatus

Bases: AlanBaseEnum

Enum representing the status of a eligibility request validation rule.

Attributes:

Name Type Description
passed

Indicates that the validation rule has passed.

not_applicable

Indicates that the validation rule is not applicable.

failed

Indicates that the validation rule has failed.

failed class-attribute instance-attribute

failed = 'failed'

not_applicable class-attribute instance-attribute

not_applicable = 'not_applicable'

passed class-attribute instance-attribute

passed = 'passed'

EligibilityRequestValidationRuleType

Bases: AlanBaseEnum

Enum representing the type of a eligibility request validation rule.

Attributes:

Name Type Description
attestation_is_local_regime

Indicates that the attestation is for the local regime.

attestation_is_ongoing

Indicates that the attestation is ongoing.

ssn_match_attestation

Indicates that the SSN of the member and the attestation match.

names_match_attestation

Indicates that the names of the member and the attestation match.

names_match_tax_notice

Indicates that the names of the member and the tax regime match.

tax_notice_year_is_the_latest

Indicates that the tax notice year is the latest.

siret_is_valid

Indicates that the SIRET number is valid.

names_match

Indicates that the names of the retiree and the document match.

ssn_match

Indicates that the SSN of the retiree and the document match.

retirement_dates_match

Indicates that the retirement dates of the form and the document match.

retirement_date_close_to_last_payslip

Indicates that the dates are close enough.

gross_monthly_income_present

Indicates that the gross monthly income is present in the document.

ssn_match_payslip

Indicates that the SSN of the member and the payslip match.

attestation_is_local_regime class-attribute instance-attribute

attestation_is_local_regime = 'attestation_is_local_regime'

attestation_is_ongoing class-attribute instance-attribute

attestation_is_ongoing = 'attestation_is_ongoing'

gross_monthly_income_present class-attribute instance-attribute

gross_monthly_income_present = (
    "gross_monthly_income_present"
)

names_match class-attribute instance-attribute

names_match = 'names_match'

names_match_attestation class-attribute instance-attribute

names_match_attestation = 'names_match_attestation'

names_match_tax_notice class-attribute instance-attribute

names_match_tax_notice = 'names_match_tax_notice'

payslip_is_recent class-attribute instance-attribute

payslip_is_recent = 'payslip_is_recent'

retirement_date_close_to_last_payslip class-attribute instance-attribute

retirement_date_close_to_last_payslip = (
    "retirement_date_close_to_last_payslip"
)

retirement_dates_match class-attribute instance-attribute

retirement_dates_match = 'retirement_dates_match'

siret_is_valid class-attribute instance-attribute

siret_is_valid = 'siret_is_valid'

ssn_match class-attribute instance-attribute

ssn_match = 'ssn_match'

ssn_match_attestation class-attribute instance-attribute

ssn_match_attestation = 'ssn_match_attestation'

ssn_match_payslip class-attribute instance-attribute

ssn_match_payslip = 'ssn_match_payslip'

tax_notice_year_is_the_latest class-attribute instance-attribute

tax_notice_year_is_the_latest = (
    "tax_notice_year_is_the_latest"
)

IncomeEligibilityParsedData dataclass

IncomeEligibilityParsedData(
    gross_monthly_income,
    tax_income,
    number_of_tax_shares,
    proof_year,
    proof_month,
    proof_type,
)

Bases: DataClassJsonMixin

gross_monthly_income instance-attribute

gross_monthly_income

number_of_tax_shares instance-attribute

number_of_tax_shares

proof_month instance-attribute

proof_month

proof_type instance-attribute

proof_type

proof_year instance-attribute

proof_year

tax_income instance-attribute

tax_income

SocialFundsParsedData dataclass

SocialFundsParsedData(
    tax_income, number_of_tax_shares, year
)

Bases: DataClassJsonMixin

number_of_tax_shares instance-attribute

number_of_tax_shares

tax_income instance-attribute

tax_income

year instance-attribute

year

components.eligibility.public.message_types

IncomeEligibilityRequestRejected dataclass

IncomeEligibilityRequestRejected(entity_type, entity_ref)

Bases: Message

Represents a rejected Income eligibility request for an entity

entity_ref instance-attribute

entity_ref

entity_type instance-attribute

entity_type

IncomeEligibilityRequestValidated dataclass

IncomeEligibilityRequestValidated(
    entity_ref,
    entity_type,
    gross_monthly_income,
    tax_income,
    number_of_tax_shares,
    proof_ref,
    proof_month,
    proof_type,
)

Bases: Message

Represents a validated Income eligibility request for an entity

entity_ref instance-attribute

entity_ref

entity_type instance-attribute

entity_type

gross_monthly_income instance-attribute

gross_monthly_income

number_of_tax_shares instance-attribute

number_of_tax_shares

proof_month instance-attribute

proof_month

proof_ref instance-attribute

proof_ref

proof_type instance-attribute

proof_type

tax_income instance-attribute

tax_income