regis

<back to all web services

CRMApplicationUpsertMultipleRequest

Requires Authentication
Required permission:UpdateApplication
The following routes are available for this service:
POST/DynamicsCRM/Application/Upsert/Multiple
<?php namespace dtos;

use DateTime;
use Exception;
use DateInterval;
use JsonSerializable;
use ServiceStack\{IReturn,IReturnVoid,IGet,IPost,IPut,IDelete,IPatch,IMeta,IHasSessionId,IHasBearerToken,IHasVersion};
use ServiceStack\{ICrud,ICreateDb,IUpdateDb,IPatchDb,IDeleteDb,ISaveDb,AuditBase,QueryDb,QueryDb2,QueryData,QueryData2,QueryResponse};
use ServiceStack\{ResponseStatus,ResponseError,EmptyResponse,IdResponse,ArrayList,KeyValuePair2,StringResponse,StringsResponse,Tuple2,Tuple3,ByteArray};
use ServiceStack\{JsonConverters,Returns,TypeContext};


class CRMApplicationLanguageTestCreateRequest implements JsonSerializable
{
    public function __construct(
        /** @var string|null */
        public ?string $type=null,
        /** @var DateTime|null */
        public ?DateTime $test_date=null,
        /** @var float|null */
        public ?float $score=null,
        /** @var bool|null */
        public ?bool $applicant_defined=null,
        /** @var string|null */
        public ?string $status=null
    ) {
    }

    /** @throws Exception */
    public function fromMap($o): void {
        if (isset($o['type'])) $this->type = $o['type'];
        if (isset($o['test_date'])) $this->test_date = JsonConverters::from('DateTime', $o['test_date']);
        if (isset($o['score'])) $this->score = $o['score'];
        if (isset($o['applicant_defined'])) $this->applicant_defined = $o['applicant_defined'];
        if (isset($o['status'])) $this->status = $o['status'];
    }
    
    /** @throws Exception */
    public function jsonSerialize(): mixed
    {
        $o = [];
        if (isset($this->type)) $o['type'] = $this->type;
        if (isset($this->test_date)) $o['test_date'] = JsonConverters::to('DateTime', $this->test_date);
        if (isset($this->score)) $o['score'] = $this->score;
        if (isset($this->applicant_defined)) $o['applicant_defined'] = $this->applicant_defined;
        if (isset($this->status)) $o['status'] = $this->status;
        return empty($o) ? new class(){} : $o;
    }
}

class CRMApplicationRefereeCreateRequest implements JsonSerializable
{
    public function __construct(
        /** @var int */
        public int $import_id=0,
        /** @var string|null */
        public ?string $first_name=null,
        /** @var string|null */
        public ?string $last_name=null,
        /** @var string|null */
        public ?string $job_title=null,
        /** @var string|null */
        public ?string $email=null,
        /** @var string|null */
        public ?string $phone=null,
        /** @var string|null */
        public ?string $type=null,
        /** @var string|null */
        public ?string $full_name=null,
        /** @var string|null */
        public ?string $position=null,
        /** @var string|null */
        public ?string $organization=null,
        /** @var string|null */
        public ?string $email_from_referee=null,
        /** @var string|null */
        public ?string $relationship=null,
        /** @var string|null */
        public ?string $relationship_details=null,
        /** @var string|null */
        public ?string $personal_evaluation=null,
        /** @var int|null */
        public ?int $ability_question_1=null,
        /** @var int|null */
        public ?int $ability_question_2=null,
        /** @var int|null */
        public ?int $ability_question_3=null,
        /** @var int|null */
        public ?int $ability_question_4=null,
        /** @var int|null */
        public ?int $ability_question_5=null,
        /** @var int|null */
        public ?int $ability_question_6=null,
        /** @var int|null */
        public ?int $ability_question_7=null,
        /** @var int|null */
        public ?int $ability_question_8=null,
        /** @var int|null */
        public ?int $ability_question_9=null,
        /** @var int|null */
        public ?int $ability_question_10=null,
        /** @var string|null */
        public ?string $qualify_assessment=null,
        /** @var string|null */
        public ?string $recommendation=null,
        /** @var string|null */
        public ?string $recommendation_details=null,
        /** @var bool|null */
        public ?bool $is_regent_alum=null,
        /** @var bool|null */
        public ?bool $is_complete=null,
        /** @var DateTime|null */
        public ?DateTime $email_sent=null,
        /** @var DateTime|null */
        public ?DateTime $submitted_date=null
    ) {
    }

    /** @throws Exception */
    public function fromMap($o): void {
        if (isset($o['import_id'])) $this->import_id = $o['import_id'];
        if (isset($o['first_name'])) $this->first_name = $o['first_name'];
        if (isset($o['last_name'])) $this->last_name = $o['last_name'];
        if (isset($o['job_title'])) $this->job_title = $o['job_title'];
        if (isset($o['email'])) $this->email = $o['email'];
        if (isset($o['phone'])) $this->phone = $o['phone'];
        if (isset($o['type'])) $this->type = $o['type'];
        if (isset($o['full_name'])) $this->full_name = $o['full_name'];
        if (isset($o['position'])) $this->position = $o['position'];
        if (isset($o['organization'])) $this->organization = $o['organization'];
        if (isset($o['email_from_referee'])) $this->email_from_referee = $o['email_from_referee'];
        if (isset($o['relationship'])) $this->relationship = $o['relationship'];
        if (isset($o['relationship_details'])) $this->relationship_details = $o['relationship_details'];
        if (isset($o['personal_evaluation'])) $this->personal_evaluation = $o['personal_evaluation'];
        if (isset($o['ability_question_1'])) $this->ability_question_1 = $o['ability_question_1'];
        if (isset($o['ability_question_2'])) $this->ability_question_2 = $o['ability_question_2'];
        if (isset($o['ability_question_3'])) $this->ability_question_3 = $o['ability_question_3'];
        if (isset($o['ability_question_4'])) $this->ability_question_4 = $o['ability_question_4'];
        if (isset($o['ability_question_5'])) $this->ability_question_5 = $o['ability_question_5'];
        if (isset($o['ability_question_6'])) $this->ability_question_6 = $o['ability_question_6'];
        if (isset($o['ability_question_7'])) $this->ability_question_7 = $o['ability_question_7'];
        if (isset($o['ability_question_8'])) $this->ability_question_8 = $o['ability_question_8'];
        if (isset($o['ability_question_9'])) $this->ability_question_9 = $o['ability_question_9'];
        if (isset($o['ability_question_10'])) $this->ability_question_10 = $o['ability_question_10'];
        if (isset($o['qualify_assessment'])) $this->qualify_assessment = $o['qualify_assessment'];
        if (isset($o['recommendation'])) $this->recommendation = $o['recommendation'];
        if (isset($o['recommendation_details'])) $this->recommendation_details = $o['recommendation_details'];
        if (isset($o['is_regent_alum'])) $this->is_regent_alum = $o['is_regent_alum'];
        if (isset($o['is_complete'])) $this->is_complete = $o['is_complete'];
        if (isset($o['email_sent'])) $this->email_sent = JsonConverters::from('DateTime', $o['email_sent']);
        if (isset($o['submitted_date'])) $this->submitted_date = JsonConverters::from('DateTime', $o['submitted_date']);
    }
    
    /** @throws Exception */
    public function jsonSerialize(): mixed
    {
        $o = [];
        if (isset($this->import_id)) $o['import_id'] = $this->import_id;
        if (isset($this->first_name)) $o['first_name'] = $this->first_name;
        if (isset($this->last_name)) $o['last_name'] = $this->last_name;
        if (isset($this->job_title)) $o['job_title'] = $this->job_title;
        if (isset($this->email)) $o['email'] = $this->email;
        if (isset($this->phone)) $o['phone'] = $this->phone;
        if (isset($this->type)) $o['type'] = $this->type;
        if (isset($this->full_name)) $o['full_name'] = $this->full_name;
        if (isset($this->position)) $o['position'] = $this->position;
        if (isset($this->organization)) $o['organization'] = $this->organization;
        if (isset($this->email_from_referee)) $o['email_from_referee'] = $this->email_from_referee;
        if (isset($this->relationship)) $o['relationship'] = $this->relationship;
        if (isset($this->relationship_details)) $o['relationship_details'] = $this->relationship_details;
        if (isset($this->personal_evaluation)) $o['personal_evaluation'] = $this->personal_evaluation;
        if (isset($this->ability_question_1)) $o['ability_question_1'] = $this->ability_question_1;
        if (isset($this->ability_question_2)) $o['ability_question_2'] = $this->ability_question_2;
        if (isset($this->ability_question_3)) $o['ability_question_3'] = $this->ability_question_3;
        if (isset($this->ability_question_4)) $o['ability_question_4'] = $this->ability_question_4;
        if (isset($this->ability_question_5)) $o['ability_question_5'] = $this->ability_question_5;
        if (isset($this->ability_question_6)) $o['ability_question_6'] = $this->ability_question_6;
        if (isset($this->ability_question_7)) $o['ability_question_7'] = $this->ability_question_7;
        if (isset($this->ability_question_8)) $o['ability_question_8'] = $this->ability_question_8;
        if (isset($this->ability_question_9)) $o['ability_question_9'] = $this->ability_question_9;
        if (isset($this->ability_question_10)) $o['ability_question_10'] = $this->ability_question_10;
        if (isset($this->qualify_assessment)) $o['qualify_assessment'] = $this->qualify_assessment;
        if (isset($this->recommendation)) $o['recommendation'] = $this->recommendation;
        if (isset($this->recommendation_details)) $o['recommendation_details'] = $this->recommendation_details;
        if (isset($this->is_regent_alum)) $o['is_regent_alum'] = $this->is_regent_alum;
        if (isset($this->is_complete)) $o['is_complete'] = $this->is_complete;
        if (isset($this->email_sent)) $o['email_sent'] = JsonConverters::to('DateTime', $this->email_sent);
        if (isset($this->submitted_date)) $o['submitted_date'] = JsonConverters::to('DateTime', $this->submitted_date);
        return empty($o) ? new class(){} : $o;
    }
}

class CRMApplicationRequirementCreateRequest implements JsonSerializable
{
    public function __construct(
        /** @var string|null */
        public ?string $status=null,
        /** @var string|null */
        public ?string $requirement_name=null,
        /** @var DateTime|null */
        public ?DateTime $requested_date=null,
        /** @var DateTime|null */
        public ?DateTime $received_date=null
    ) {
    }

    /** @throws Exception */
    public function fromMap($o): void {
        if (isset($o['status'])) $this->status = $o['status'];
        if (isset($o['requirement_name'])) $this->requirement_name = $o['requirement_name'];
        if (isset($o['requested_date'])) $this->requested_date = JsonConverters::from('DateTime', $o['requested_date']);
        if (isset($o['received_date'])) $this->received_date = JsonConverters::from('DateTime', $o['received_date']);
    }
    
    /** @throws Exception */
    public function jsonSerialize(): mixed
    {
        $o = [];
        if (isset($this->status)) $o['status'] = $this->status;
        if (isset($this->requirement_name)) $o['requirement_name'] = $this->requirement_name;
        if (isset($this->requested_date)) $o['requested_date'] = JsonConverters::to('DateTime', $this->requested_date);
        if (isset($this->received_date)) $o['received_date'] = JsonConverters::to('DateTime', $this->received_date);
        return empty($o) ? new class(){} : $o;
    }
}

class CRMEducationUpsertRequest implements JsonSerializable
{
    public function __construct(
        /** @var int */
        public int $regent_id=0,
        /** @var int|null */
        public ?int $import_id=null,
        /** @var int|null */
        public ?int $institution_regent_id=null,
        /** @var string|null */
        public ?string $application_guid=null,
        /** @var string|null */
        public ?string $degree_status=null,
        /** @var string|null */
        public ?string $degree_type=null,
        /** @var string|null */
        public ?string $unofficial_institution_name=null,
        /** @var string|null */
        public ?string $unofficial_degree_name=null,
        /** @var string|null */
        public ?string $degree_name=null,
        /** @var string|null */
        public ?string $degree_code=null,
        /** @var string|null */
        public ?string $description=null,
        /** @var string|null */
        public ?string $major=null,
        /** @var string|null */
        public ?string $second_major=null,
        /** @var float|null */
        public ?float $cumulative_gpa=null,
        /** @var bool|null */
        public ?bool $is_final=null,
        /** @var bool|null */
        public ?bool $is_regis_external_degree=null,
        /** @var int|null */
        public ?int $start_year=null,
        /** @var int|null */
        public ?int $end_year=null,
        /** @var int|null */
        public ?int $month_graduated=null,
        /** @var int|null */
        public ?int $year_graduated=null,
        /** @var DateTime|null */
        public ?DateTime $added_date=null
    ) {
    }

    /** @throws Exception */
    public function fromMap($o): void {
        if (isset($o['regent_id'])) $this->regent_id = $o['regent_id'];
        if (isset($o['import_id'])) $this->import_id = $o['import_id'];
        if (isset($o['institution_regent_id'])) $this->institution_regent_id = $o['institution_regent_id'];
        if (isset($o['application_guid'])) $this->application_guid = $o['application_guid'];
        if (isset($o['degree_status'])) $this->degree_status = $o['degree_status'];
        if (isset($o['degree_type'])) $this->degree_type = $o['degree_type'];
        if (isset($o['unofficial_institution_name'])) $this->unofficial_institution_name = $o['unofficial_institution_name'];
        if (isset($o['unofficial_degree_name'])) $this->unofficial_degree_name = $o['unofficial_degree_name'];
        if (isset($o['degree_name'])) $this->degree_name = $o['degree_name'];
        if (isset($o['degree_code'])) $this->degree_code = $o['degree_code'];
        if (isset($o['description'])) $this->description = $o['description'];
        if (isset($o['major'])) $this->major = $o['major'];
        if (isset($o['second_major'])) $this->second_major = $o['second_major'];
        if (isset($o['cumulative_gpa'])) $this->cumulative_gpa = $o['cumulative_gpa'];
        if (isset($o['is_final'])) $this->is_final = $o['is_final'];
        if (isset($o['is_regis_external_degree'])) $this->is_regis_external_degree = $o['is_regis_external_degree'];
        if (isset($o['start_year'])) $this->start_year = $o['start_year'];
        if (isset($o['end_year'])) $this->end_year = $o['end_year'];
        if (isset($o['month_graduated'])) $this->month_graduated = $o['month_graduated'];
        if (isset($o['year_graduated'])) $this->year_graduated = $o['year_graduated'];
        if (isset($o['added_date'])) $this->added_date = JsonConverters::from('DateTime', $o['added_date']);
    }
    
    /** @throws Exception */
    public function jsonSerialize(): mixed
    {
        $o = [];
        if (isset($this->regent_id)) $o['regent_id'] = $this->regent_id;
        if (isset($this->import_id)) $o['import_id'] = $this->import_id;
        if (isset($this->institution_regent_id)) $o['institution_regent_id'] = $this->institution_regent_id;
        if (isset($this->application_guid)) $o['application_guid'] = $this->application_guid;
        if (isset($this->degree_status)) $o['degree_status'] = $this->degree_status;
        if (isset($this->degree_type)) $o['degree_type'] = $this->degree_type;
        if (isset($this->unofficial_institution_name)) $o['unofficial_institution_name'] = $this->unofficial_institution_name;
        if (isset($this->unofficial_degree_name)) $o['unofficial_degree_name'] = $this->unofficial_degree_name;
        if (isset($this->degree_name)) $o['degree_name'] = $this->degree_name;
        if (isset($this->degree_code)) $o['degree_code'] = $this->degree_code;
        if (isset($this->description)) $o['description'] = $this->description;
        if (isset($this->major)) $o['major'] = $this->major;
        if (isset($this->second_major)) $o['second_major'] = $this->second_major;
        if (isset($this->cumulative_gpa)) $o['cumulative_gpa'] = $this->cumulative_gpa;
        if (isset($this->is_final)) $o['is_final'] = $this->is_final;
        if (isset($this->is_regis_external_degree)) $o['is_regis_external_degree'] = $this->is_regis_external_degree;
        if (isset($this->start_year)) $o['start_year'] = $this->start_year;
        if (isset($this->end_year)) $o['end_year'] = $this->end_year;
        if (isset($this->month_graduated)) $o['month_graduated'] = $this->month_graduated;
        if (isset($this->year_graduated)) $o['year_graduated'] = $this->year_graduated;
        if (isset($this->added_date)) $o['added_date'] = JsonConverters::to('DateTime', $this->added_date);
        return empty($o) ? new class(){} : $o;
    }
}

class CRMApplicationCreateRequest implements JsonSerializable
{
    public function __construct(
        /** @var int */
        public int $regent_id=0,
        /** @var int */
        public int $import_id=0,
        /** @var string|null */
        public ?string $application_name=null,
        /** @var string|null */
        public ?string $academic_program=null,
        /** @var string|null */
        public ?string $start_term=null,
        /** @var string|null */
        public ?string $location=null,
        /** @var string|null */
        public ?string $addr1=null,
        /** @var string|null */
        public ?string $addr2=null,
        /** @var string|null */
        public ?string $city=null,
        /** @var string|null */
        public ?string $state=null,
        /** @var string|null */
        public ?string $country=null,
        /** @var string|null */
        public ?string $code=null,
        /** @var string|null */
        public ?string $former_name=null,
        /** @var string|null */
        public ?string $citizenship=null,
        /** @var string|null */
        public ?string $citizenship_other=null,
        /** @var string|null */
        public ?string $permanent_resident=null,
        /** @var string|null */
        public ?string $spouse_name=null,
        /** @var string|null */
        public ?string $children=null,
        /** @var bool|null */
        public ?bool $native_english_speaker=null,
        /** @var string|null */
        public ?string $native_language=null,
        /** @var string|null */
        public ?string $birth_place=null,
        /** @var string|null */
        public ?string $residency_status=null,
        /** @var DateTime|null */
        public ?DateTime $language_test_exemption_request_date=null,
        /** @var DateTime|null */
        public ?DateTime $language_test_exemption_decision_date=null,
        /** @var string|null */
        public ?string $language_test_exemption_decision=null,
        /** @var string|null */
        public ?string $language_test_comment=null,
        /** @var array<CRMApplicationLanguageTestCreateRequest>|null */
        public ?array $language_tests=null,
        /** @var array<CRMApplicationRefereeCreateRequest>|null */
        public ?array $references=null,
        /** @var array<CRMApplicationRequirementCreateRequest>|null */
        public ?array $requirements=null,
        /** @var array<CRMEducationUpsertRequest>|null */
        public ?array $education=null,
        /** @var string|null */
        public ?string $church_attended=null,
        /** @var string|null */
        public ?string $pastor_first_name=null,
        /** @var string|null */
        public ?string $pastor_last_name=null,
        /** @var bool|null */
        public ?bool $has_impairment=null,
        /** @var string|null */
        public ?string $impairment_description=null,
        /** @var bool|null */
        public ?bool $apply_for_financial_aid=null,
        /** @var string|null */
        public ?string $financial_description=null,
        /** @var float|null */
        public ?float $employment_years=null,
        /** @var string|null */
        public ?string $employment_description=null,
        /** @var float|null */
        public ?float $church_volunteer_years=null,
        /** @var string|null */
        public ?string $church_volunteer_description=null,
        /** @var float|null */
        public ?float $other_volunteer_years=null,
        /** @var string|null */
        public ?string $other_volunteer_description=null,
        /** @var string|null */
        public ?string $accomplishments_description=null,
        /** @var string|null */
        public ?string $what_other_graduate_schools_are_you_apply=null,
        /** @var string|null */
        public ?string $what_else_interests_you_about_regent=null,
        /** @var string|null */
        public ?string $heard_about_regent_from_book=null,
        /** @var string|null */
        public ?string $heard_about_regent_from_event=null,
        /** @var string|null */
        public ?string $heard_about_regent_from_organization=null,
        /** @var string|null */
        public ?string $heard_about_regent_from_person=null,
        /** @var string|null */
        public ?string $heard_about_regent_from_website_pub=null,
        /** @var array<string>|null */
        public ?array $what_interests_you_about_regent=null,
        /** @var string|null */
        public ?string $what_else_brought_you_to_regent=null,
        /** @var bool|null */
        public ?bool $start_via_distance_ed=null,
        /** @var bool|null */
        public ?bool $transfer_credits=null,
        /** @var string|null */
        public ?string $applicant_comments=null,
        /** @var float|null */
        public ?float $cumulative_undergraduate_gpa=null,
        /** @var float|null */
        public ?float $cumulative_graduate_gpa=null,
        /** @var bool|null */
        public ?bool $conditional_admission=null,
        /** @var array<string>|null */
        public ?array $conditional_admission_reason=null,
        /** @var string|null */
        public ?string $admission_notes=null,
        /** @var string|null */
        public ?string $admission_decision_notes=null,
        /** @var string|null */
        public ?string $withdrawn_reason=null,
        /** @var DateTime|null */
        public ?DateTime $submitted=null,
        /** @var DateTime|null */
        public ?DateTime $paid=null,
        /** @var DateTime|null */
        public ?DateTime $reviewed=null,
        /** @var DateTime|null */
        public ?DateTime $completed=null,
        /** @var DateTime|null */
        public ?DateTime $rejected=null,
        /** @var DateTime|null */
        public ?DateTime $admitted=null,
        /** @var DateTime|null */
        public ?DateTime $postponed=null,
        /** @var DateTime|null */
        public ?DateTime $withdrawn=null,
        /** @var DateTime|null */
        public ?DateTime $confirmed=null,
        /** @var DateTime|null */
        public ?DateTime $read_theological_position=null,
        /** @var string|null */
        public ?string $current_status=null,
        /** @var string|null */
        public ?string $image_base64=null,
        /** @var string|null */
        public ?string $promo_code=null,
        /** @var DateTime */
        public DateTime $added_date=new DateTime(),
        /** @var DateTime|null */
        public ?DateTime $last_contacted_date=null,
        /** @var string|null */
        public ?string $owning_username=null
    ) {
    }

    /** @throws Exception */
    public function fromMap($o): void {
        if (isset($o['regent_id'])) $this->regent_id = $o['regent_id'];
        if (isset($o['import_id'])) $this->import_id = $o['import_id'];
        if (isset($o['application_name'])) $this->application_name = $o['application_name'];
        if (isset($o['academic_program'])) $this->academic_program = $o['academic_program'];
        if (isset($o['start_term'])) $this->start_term = $o['start_term'];
        if (isset($o['location'])) $this->location = $o['location'];
        if (isset($o['addr1'])) $this->addr1 = $o['addr1'];
        if (isset($o['addr2'])) $this->addr2 = $o['addr2'];
        if (isset($o['city'])) $this->city = $o['city'];
        if (isset($o['state'])) $this->state = $o['state'];
        if (isset($o['country'])) $this->country = $o['country'];
        if (isset($o['code'])) $this->code = $o['code'];
        if (isset($o['former_name'])) $this->former_name = $o['former_name'];
        if (isset($o['citizenship'])) $this->citizenship = $o['citizenship'];
        if (isset($o['citizenship_other'])) $this->citizenship_other = $o['citizenship_other'];
        if (isset($o['permanent_resident'])) $this->permanent_resident = $o['permanent_resident'];
        if (isset($o['spouse_name'])) $this->spouse_name = $o['spouse_name'];
        if (isset($o['children'])) $this->children = $o['children'];
        if (isset($o['native_english_speaker'])) $this->native_english_speaker = $o['native_english_speaker'];
        if (isset($o['native_language'])) $this->native_language = $o['native_language'];
        if (isset($o['birth_place'])) $this->birth_place = $o['birth_place'];
        if (isset($o['residency_status'])) $this->residency_status = $o['residency_status'];
        if (isset($o['language_test_exemption_request_date'])) $this->language_test_exemption_request_date = JsonConverters::from('DateTime', $o['language_test_exemption_request_date']);
        if (isset($o['language_test_exemption_decision_date'])) $this->language_test_exemption_decision_date = JsonConverters::from('DateTime', $o['language_test_exemption_decision_date']);
        if (isset($o['language_test_exemption_decision'])) $this->language_test_exemption_decision = $o['language_test_exemption_decision'];
        if (isset($o['language_test_comment'])) $this->language_test_comment = $o['language_test_comment'];
        if (isset($o['language_tests'])) $this->language_tests = JsonConverters::fromArray('CRMApplicationLanguageTestCreateRequest', $o['language_tests']);
        if (isset($o['references'])) $this->references = JsonConverters::fromArray('CRMApplicationRefereeCreateRequest', $o['references']);
        if (isset($o['requirements'])) $this->requirements = JsonConverters::fromArray('CRMApplicationRequirementCreateRequest', $o['requirements']);
        if (isset($o['education'])) $this->education = JsonConverters::fromArray('CRMEducationUpsertRequest', $o['education']);
        if (isset($o['church_attended'])) $this->church_attended = $o['church_attended'];
        if (isset($o['pastor_first_name'])) $this->pastor_first_name = $o['pastor_first_name'];
        if (isset($o['pastor_last_name'])) $this->pastor_last_name = $o['pastor_last_name'];
        if (isset($o['has_impairment'])) $this->has_impairment = $o['has_impairment'];
        if (isset($o['impairment_description'])) $this->impairment_description = $o['impairment_description'];
        if (isset($o['apply_for_financial_aid'])) $this->apply_for_financial_aid = $o['apply_for_financial_aid'];
        if (isset($o['financial_description'])) $this->financial_description = $o['financial_description'];
        if (isset($o['employment_years'])) $this->employment_years = $o['employment_years'];
        if (isset($o['employment_description'])) $this->employment_description = $o['employment_description'];
        if (isset($o['church_volunteer_years'])) $this->church_volunteer_years = $o['church_volunteer_years'];
        if (isset($o['church_volunteer_description'])) $this->church_volunteer_description = $o['church_volunteer_description'];
        if (isset($o['other_volunteer_years'])) $this->other_volunteer_years = $o['other_volunteer_years'];
        if (isset($o['other_volunteer_description'])) $this->other_volunteer_description = $o['other_volunteer_description'];
        if (isset($o['accomplishments_description'])) $this->accomplishments_description = $o['accomplishments_description'];
        if (isset($o['what_other_graduate_schools_are_you_apply'])) $this->what_other_graduate_schools_are_you_apply = $o['what_other_graduate_schools_are_you_apply'];
        if (isset($o['what_else_interests_you_about_regent'])) $this->what_else_interests_you_about_regent = $o['what_else_interests_you_about_regent'];
        if (isset($o['heard_about_regent_from_book'])) $this->heard_about_regent_from_book = $o['heard_about_regent_from_book'];
        if (isset($o['heard_about_regent_from_event'])) $this->heard_about_regent_from_event = $o['heard_about_regent_from_event'];
        if (isset($o['heard_about_regent_from_organization'])) $this->heard_about_regent_from_organization = $o['heard_about_regent_from_organization'];
        if (isset($o['heard_about_regent_from_person'])) $this->heard_about_regent_from_person = $o['heard_about_regent_from_person'];
        if (isset($o['heard_about_regent_from_website_pub'])) $this->heard_about_regent_from_website_pub = $o['heard_about_regent_from_website_pub'];
        if (isset($o['what_interests_you_about_regent'])) $this->what_interests_you_about_regent = JsonConverters::fromArray('string', $o['what_interests_you_about_regent']);
        if (isset($o['what_else_brought_you_to_regent'])) $this->what_else_brought_you_to_regent = $o['what_else_brought_you_to_regent'];
        if (isset($o['start_via_distance_ed'])) $this->start_via_distance_ed = $o['start_via_distance_ed'];
        if (isset($o['transfer_credits'])) $this->transfer_credits = $o['transfer_credits'];
        if (isset($o['applicant_comments'])) $this->applicant_comments = $o['applicant_comments'];
        if (isset($o['cumulative_undergraduate_gpa'])) $this->cumulative_undergraduate_gpa = $o['cumulative_undergraduate_gpa'];
        if (isset($o['cumulative_graduate_gpa'])) $this->cumulative_graduate_gpa = $o['cumulative_graduate_gpa'];
        if (isset($o['conditional_admission'])) $this->conditional_admission = $o['conditional_admission'];
        if (isset($o['conditional_admission_reason'])) $this->conditional_admission_reason = JsonConverters::fromArray('string', $o['conditional_admission_reason']);
        if (isset($o['admission_notes'])) $this->admission_notes = $o['admission_notes'];
        if (isset($o['admission_decision_notes'])) $this->admission_decision_notes = $o['admission_decision_notes'];
        if (isset($o['withdrawn_reason'])) $this->withdrawn_reason = $o['withdrawn_reason'];
        if (isset($o['submitted'])) $this->submitted = JsonConverters::from('DateTime', $o['submitted']);
        if (isset($o['paid'])) $this->paid = JsonConverters::from('DateTime', $o['paid']);
        if (isset($o['reviewed'])) $this->reviewed = JsonConverters::from('DateTime', $o['reviewed']);
        if (isset($o['completed'])) $this->completed = JsonConverters::from('DateTime', $o['completed']);
        if (isset($o['rejected'])) $this->rejected = JsonConverters::from('DateTime', $o['rejected']);
        if (isset($o['admitted'])) $this->admitted = JsonConverters::from('DateTime', $o['admitted']);
        if (isset($o['postponed'])) $this->postponed = JsonConverters::from('DateTime', $o['postponed']);
        if (isset($o['withdrawn'])) $this->withdrawn = JsonConverters::from('DateTime', $o['withdrawn']);
        if (isset($o['confirmed'])) $this->confirmed = JsonConverters::from('DateTime', $o['confirmed']);
        if (isset($o['read_theological_position'])) $this->read_theological_position = JsonConverters::from('DateTime', $o['read_theological_position']);
        if (isset($o['current_status'])) $this->current_status = $o['current_status'];
        if (isset($o['image_base64'])) $this->image_base64 = $o['image_base64'];
        if (isset($o['promo_code'])) $this->promo_code = $o['promo_code'];
        if (isset($o['added_date'])) $this->added_date = JsonConverters::from('DateTime', $o['added_date']);
        if (isset($o['last_contacted_date'])) $this->last_contacted_date = JsonConverters::from('DateTime', $o['last_contacted_date']);
        if (isset($o['owning_username'])) $this->owning_username = $o['owning_username'];
    }
    
    /** @throws Exception */
    public function jsonSerialize(): mixed
    {
        $o = [];
        if (isset($this->regent_id)) $o['regent_id'] = $this->regent_id;
        if (isset($this->import_id)) $o['import_id'] = $this->import_id;
        if (isset($this->application_name)) $o['application_name'] = $this->application_name;
        if (isset($this->academic_program)) $o['academic_program'] = $this->academic_program;
        if (isset($this->start_term)) $o['start_term'] = $this->start_term;
        if (isset($this->location)) $o['location'] = $this->location;
        if (isset($this->addr1)) $o['addr1'] = $this->addr1;
        if (isset($this->addr2)) $o['addr2'] = $this->addr2;
        if (isset($this->city)) $o['city'] = $this->city;
        if (isset($this->state)) $o['state'] = $this->state;
        if (isset($this->country)) $o['country'] = $this->country;
        if (isset($this->code)) $o['code'] = $this->code;
        if (isset($this->former_name)) $o['former_name'] = $this->former_name;
        if (isset($this->citizenship)) $o['citizenship'] = $this->citizenship;
        if (isset($this->citizenship_other)) $o['citizenship_other'] = $this->citizenship_other;
        if (isset($this->permanent_resident)) $o['permanent_resident'] = $this->permanent_resident;
        if (isset($this->spouse_name)) $o['spouse_name'] = $this->spouse_name;
        if (isset($this->children)) $o['children'] = $this->children;
        if (isset($this->native_english_speaker)) $o['native_english_speaker'] = $this->native_english_speaker;
        if (isset($this->native_language)) $o['native_language'] = $this->native_language;
        if (isset($this->birth_place)) $o['birth_place'] = $this->birth_place;
        if (isset($this->residency_status)) $o['residency_status'] = $this->residency_status;
        if (isset($this->language_test_exemption_request_date)) $o['language_test_exemption_request_date'] = JsonConverters::to('DateTime', $this->language_test_exemption_request_date);
        if (isset($this->language_test_exemption_decision_date)) $o['language_test_exemption_decision_date'] = JsonConverters::to('DateTime', $this->language_test_exemption_decision_date);
        if (isset($this->language_test_exemption_decision)) $o['language_test_exemption_decision'] = $this->language_test_exemption_decision;
        if (isset($this->language_test_comment)) $o['language_test_comment'] = $this->language_test_comment;
        if (isset($this->language_tests)) $o['language_tests'] = JsonConverters::toArray('CRMApplicationLanguageTestCreateRequest', $this->language_tests);
        if (isset($this->references)) $o['references'] = JsonConverters::toArray('CRMApplicationRefereeCreateRequest', $this->references);
        if (isset($this->requirements)) $o['requirements'] = JsonConverters::toArray('CRMApplicationRequirementCreateRequest', $this->requirements);
        if (isset($this->education)) $o['education'] = JsonConverters::toArray('CRMEducationUpsertRequest', $this->education);
        if (isset($this->church_attended)) $o['church_attended'] = $this->church_attended;
        if (isset($this->pastor_first_name)) $o['pastor_first_name'] = $this->pastor_first_name;
        if (isset($this->pastor_last_name)) $o['pastor_last_name'] = $this->pastor_last_name;
        if (isset($this->has_impairment)) $o['has_impairment'] = $this->has_impairment;
        if (isset($this->impairment_description)) $o['impairment_description'] = $this->impairment_description;
        if (isset($this->apply_for_financial_aid)) $o['apply_for_financial_aid'] = $this->apply_for_financial_aid;
        if (isset($this->financial_description)) $o['financial_description'] = $this->financial_description;
        if (isset($this->employment_years)) $o['employment_years'] = $this->employment_years;
        if (isset($this->employment_description)) $o['employment_description'] = $this->employment_description;
        if (isset($this->church_volunteer_years)) $o['church_volunteer_years'] = $this->church_volunteer_years;
        if (isset($this->church_volunteer_description)) $o['church_volunteer_description'] = $this->church_volunteer_description;
        if (isset($this->other_volunteer_years)) $o['other_volunteer_years'] = $this->other_volunteer_years;
        if (isset($this->other_volunteer_description)) $o['other_volunteer_description'] = $this->other_volunteer_description;
        if (isset($this->accomplishments_description)) $o['accomplishments_description'] = $this->accomplishments_description;
        if (isset($this->what_other_graduate_schools_are_you_apply)) $o['what_other_graduate_schools_are_you_apply'] = $this->what_other_graduate_schools_are_you_apply;
        if (isset($this->what_else_interests_you_about_regent)) $o['what_else_interests_you_about_regent'] = $this->what_else_interests_you_about_regent;
        if (isset($this->heard_about_regent_from_book)) $o['heard_about_regent_from_book'] = $this->heard_about_regent_from_book;
        if (isset($this->heard_about_regent_from_event)) $o['heard_about_regent_from_event'] = $this->heard_about_regent_from_event;
        if (isset($this->heard_about_regent_from_organization)) $o['heard_about_regent_from_organization'] = $this->heard_about_regent_from_organization;
        if (isset($this->heard_about_regent_from_person)) $o['heard_about_regent_from_person'] = $this->heard_about_regent_from_person;
        if (isset($this->heard_about_regent_from_website_pub)) $o['heard_about_regent_from_website_pub'] = $this->heard_about_regent_from_website_pub;
        if (isset($this->what_interests_you_about_regent)) $o['what_interests_you_about_regent'] = JsonConverters::toArray('string', $this->what_interests_you_about_regent);
        if (isset($this->what_else_brought_you_to_regent)) $o['what_else_brought_you_to_regent'] = $this->what_else_brought_you_to_regent;
        if (isset($this->start_via_distance_ed)) $o['start_via_distance_ed'] = $this->start_via_distance_ed;
        if (isset($this->transfer_credits)) $o['transfer_credits'] = $this->transfer_credits;
        if (isset($this->applicant_comments)) $o['applicant_comments'] = $this->applicant_comments;
        if (isset($this->cumulative_undergraduate_gpa)) $o['cumulative_undergraduate_gpa'] = $this->cumulative_undergraduate_gpa;
        if (isset($this->cumulative_graduate_gpa)) $o['cumulative_graduate_gpa'] = $this->cumulative_graduate_gpa;
        if (isset($this->conditional_admission)) $o['conditional_admission'] = $this->conditional_admission;
        if (isset($this->conditional_admission_reason)) $o['conditional_admission_reason'] = JsonConverters::toArray('string', $this->conditional_admission_reason);
        if (isset($this->admission_notes)) $o['admission_notes'] = $this->admission_notes;
        if (isset($this->admission_decision_notes)) $o['admission_decision_notes'] = $this->admission_decision_notes;
        if (isset($this->withdrawn_reason)) $o['withdrawn_reason'] = $this->withdrawn_reason;
        if (isset($this->submitted)) $o['submitted'] = JsonConverters::to('DateTime', $this->submitted);
        if (isset($this->paid)) $o['paid'] = JsonConverters::to('DateTime', $this->paid);
        if (isset($this->reviewed)) $o['reviewed'] = JsonConverters::to('DateTime', $this->reviewed);
        if (isset($this->completed)) $o['completed'] = JsonConverters::to('DateTime', $this->completed);
        if (isset($this->rejected)) $o['rejected'] = JsonConverters::to('DateTime', $this->rejected);
        if (isset($this->admitted)) $o['admitted'] = JsonConverters::to('DateTime', $this->admitted);
        if (isset($this->postponed)) $o['postponed'] = JsonConverters::to('DateTime', $this->postponed);
        if (isset($this->withdrawn)) $o['withdrawn'] = JsonConverters::to('DateTime', $this->withdrawn);
        if (isset($this->confirmed)) $o['confirmed'] = JsonConverters::to('DateTime', $this->confirmed);
        if (isset($this->read_theological_position)) $o['read_theological_position'] = JsonConverters::to('DateTime', $this->read_theological_position);
        if (isset($this->current_status)) $o['current_status'] = $this->current_status;
        if (isset($this->image_base64)) $o['image_base64'] = $this->image_base64;
        if (isset($this->promo_code)) $o['promo_code'] = $this->promo_code;
        if (isset($this->added_date)) $o['added_date'] = JsonConverters::to('DateTime', $this->added_date);
        if (isset($this->last_contacted_date)) $o['last_contacted_date'] = JsonConverters::to('DateTime', $this->last_contacted_date);
        if (isset($this->owning_username)) $o['owning_username'] = $this->owning_username;
        return empty($o) ? new class(){} : $o;
    }
}

class CRMApplicationUpsertMultipleRequest implements JsonSerializable
{
    public function __construct(
        /** @var array<CRMApplicationCreateRequest>|null */
        public ?array $applications=null
    ) {
    }

    /** @throws Exception */
    public function fromMap($o): void {
        if (isset($o['applications'])) $this->applications = JsonConverters::fromArray('CRMApplicationCreateRequest', $o['applications']);
    }
    
    /** @throws Exception */
    public function jsonSerialize(): mixed
    {
        $o = [];
        if (isset($this->applications)) $o['applications'] = JsonConverters::toArray('CRMApplicationCreateRequest', $this->applications);
        return empty($o) ? new class(){} : $o;
    }
}

PHP CRMApplicationUpsertMultipleRequest DTOs

To override the Content-type in your clients, use the HTTP Accept Header, append the .csv suffix or ?format=csv

HTTP + CSV

The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.

POST /DynamicsCRM/Application/Upsert/Multiple HTTP/1.1 
Host: data.regent-college.edu 
Accept: text/csv
Content-Type: text/csv
Content-Length: length

{"applications":[{"regent_id":0,"import_id":0,"application_name":"String","academic_program":"String","start_term":"String","location":"String","addr1":"String","addr2":"String","city":"String","state":"String","country":"String","code":"String","former_name":"String","citizenship":"String","citizenship_other":"String","permanent_resident":"String","spouse_name":"String","children":"String","native_english_speaker":false,"native_language":"String","birth_place":"String","residency_status":"String","language_test_exemption_request_date":"0001-01-01T00:00:00.0000000","language_test_exemption_decision_date":"0001-01-01T00:00:00.0000000","language_test_exemption_decision":"String","language_test_comment":"String","language_tests":[{"type":"String","test_date":"0001-01-01T00:00:00.0000000","score":0,"applicant_defined":false,"status":"String"}],"references":[{"import_id":0,"first_name":"String","last_name":"String","job_title":"String","email":"String","phone":"String","type":"String","full_name":"String","position":"String","organization":"String","email_from_referee":"String","relationship":"String","relationship_details":"String","personal_evaluation":"String","ability_question_1":0,"ability_question_2":0,"ability_question_3":0,"ability_question_4":0,"ability_question_5":0,"ability_question_6":0,"ability_question_7":0,"ability_question_8":0,"ability_question_9":0,"ability_question_10":0,"qualify_assessment":"String","recommendation":"String","recommendation_details":"String","is_regent_alum":false,"is_complete":false,"email_sent":"0001-01-01T00:00:00.0000000","submitted_date":"0001-01-01T00:00:00.0000000"}],"requirements":[{"status":"String","requirement_name":"String","requested_date":"0001-01-01T00:00:00.0000000","received_date":"0001-01-01T00:00:00.0000000"}],"education":[{"regent_id":0,"import_id":0,"institution_regent_id":0,"application_guid":"String","degree_status":"String","degree_type":"String","unofficial_institution_name":"String","unofficial_degree_name":"String","degree_name":"String","degree_code":"String","description":"String","major":"String","second_major":"String","cumulative_gpa":0,"is_final":false,"is_regis_external_degree":false,"start_year":0,"end_year":0,"month_graduated":0,"year_graduated":0,"added_date":"0001-01-01T00:00:00.0000000"}],"church_attended":"String","pastor_first_name":"String","pastor_last_name":"String","has_impairment":false,"impairment_description":"String","apply_for_financial_aid":false,"financial_description":"String","employment_years":0,"employment_description":"String","church_volunteer_years":0,"church_volunteer_description":"String","other_volunteer_years":0,"other_volunteer_description":"String","accomplishments_description":"String","what_other_graduate_schools_are_you_apply":"String","what_else_interests_you_about_regent":"String","heard_about_regent_from_book":"String","heard_about_regent_from_event":"String","heard_about_regent_from_organization":"String","heard_about_regent_from_person":"String","heard_about_regent_from_website_pub":"String","what_interests_you_about_regent":["String"],"what_else_brought_you_to_regent":"String","start_via_distance_ed":false,"transfer_credits":false,"applicant_comments":"String","cumulative_undergraduate_gpa":0,"cumulative_graduate_gpa":0,"conditional_admission":false,"conditional_admission_reason":["String"],"admission_notes":"String","admission_decision_notes":"String","withdrawn_reason":"String","submitted":"0001-01-01T00:00:00.0000000","paid":"0001-01-01T00:00:00.0000000","reviewed":"0001-01-01T00:00:00.0000000","completed":"0001-01-01T00:00:00.0000000","rejected":"0001-01-01T00:00:00.0000000","admitted":"0001-01-01T00:00:00.0000000","postponed":"0001-01-01T00:00:00.0000000","withdrawn":"0001-01-01T00:00:00.0000000","confirmed":"0001-01-01T00:00:00.0000000","read_theological_position":"0001-01-01T00:00:00.0000000","current_status":"String","image_base64":"String","promo_code":"String","added_date":"0001-01-01T00:00:00.0000000","last_contacted_date":"0001-01-01T00:00:00.0000000","owning_username":"String"}]}
HTTP/1.1 200 OK
Content-Type: text/csv
Content-Length: length

{"errorCode":"String","message":"String","stackTrace":"String","errors":[{"errorCode":"String","fieldName":"String","message":"String","meta":{"String":"String"}}],"meta":{"String":"String"}}