POST | /Initiation/Transferee | Initiates a transferee. |
---|
using System;
using System.Collections;
using System.Collections.Generic;
using System.Runtime.Serialization;
using ServiceStack;
using ServiceStack.DataAnnotations;
using SIRVA.Relocation.Services.InitiationGateway.ServiceModel;
using SIRVA.Relocation.Services.InitiationGateway.ServiceModel.Types;
namespace SIRVA.Relocation.Services.InitiationGateway.ServiceModel
{
public partial class TransfereeInitiationRequest
: IRequireClientScoped, IPost
{
///<summary>
///Transferee initiation info needed for creation.
///</summary>
[ApiMember(Description="Transferee initiation info needed for creation.", IsRequired=true, ParameterType="body")]
public virtual TransfereeInitiation InitiationInfo { get; set; }
}
public partial class TransfereeInitiationResponse
{
public virtual ResponseStatus ResponseStatus { get; set; }
}
}
namespace SIRVA.Relocation.Services.InitiationGateway.ServiceModel.Types
{
public partial class Address
: Location
{
public virtual string Line1 { get; set; }
public virtual string Line2 { get; set; }
public virtual string Line3 { get; set; }
public virtual string PostalCode { get; set; }
}
public partial class CustomField
{
///<summary>
///Custom field name
///</summary>
[ApiMember(Description="Custom field name", IsRequired=true)]
public virtual string FieldName { get; set; }
///<summary>
///Custom field value
///</summary>
[ApiMember(Description="Custom field value")]
public virtual string FieldValue { get; set; }
}
public partial class Dependent
{
public virtual string FirstName { get; set; }
public virtual string LastName { get; set; }
public virtual DateTime? BirthDate { get; set; }
[ApiMember(IsRequired=true, Name="RelationshipToAssignee")]
public virtual DependentAssigneeRelationship? RelationshipToAssignee { get; set; }
}
public enum DependentAssigneeRelationship
{
Child,
Other,
}
public enum HomeOwnerStatus
{
Homeowner,
Renter,
}
public partial class Location
{
public virtual string Title { get; set; }
public virtual string City { get; set; }
public virtual string StateCode { get; set; }
public virtual string CountryCode { get; set; }
}
public enum MaritalStatus
{
Single,
Married,
DomesticPartner,
Divorcee,
Defacto,
Other,
Separated,
Interdependent,
Widowed,
Divorced,
}
public partial class Service
{
public Service()
{
Data = new List<ServiceData>{};
}
///<summary>
///Service name
///</summary>
[ApiMember(Description="Service name", IsRequired=true)]
public virtual string Name { get; set; }
///<summary>
///Service data
///</summary>
[ApiMember(Description="Service data")]
public virtual List<ServiceData> Data { get; set; }
///<summary>
///Cancel
///</summary>
[ApiMember(Description="Cancel")]
public virtual string Cancel { get; set; }
}
public partial class ServiceData
{
///<summary>
///Service data field name
///</summary>
[ApiMember(Description="Service data field name", IsRequired=true)]
public virtual string FieldName { get; set; }
///<summary>
///Service data field value
///</summary>
[ApiMember(Description="Service data field value", IsRequired=true)]
public virtual string FieldValue { get; set; }
}
public partial class SpousePartner
{
public virtual string FirstName { get; set; }
public virtual string LastName { get; set; }
public virtual DateTime? BirthDate { get; set; }
}
public partial class TransfereeInitiation
{
public TransfereeInitiation()
{
CustomFields = new List<CustomField>{};
Dependents = new List<Dependent>{};
Services = new List<Service>{};
}
///<summary>
///Client ID
///</summary>
[ApiMember(Description="Client ID")]
public virtual string ClientId { get; set; }
///<summary>
///External ID. This must be unique to the intiation's parent client
///</summary>
[ApiMember(Description="External ID. This must be unique to the intiation's parent client", IsRequired=true)]
public virtual string ExternalId { get; set; }
///<summary>
///Transferee first name
///</summary>
[ApiMember(Description="Transferee first name", IsRequired=true)]
public virtual string FirstName { get; set; }
///<summary>
///Transferee last name
///</summary>
[ApiMember(Description="Transferee last name", IsRequired=true)]
public virtual string LastName { get; set; }
///<summary>
///Assignment type
///</summary>
[ApiMember(Description="Assignment type")]
public virtual string AssignmentType { get; set; }
///<summary>
///Is this transferee pre-decision
///</summary>
[ApiMember(Description="Is this transferee pre-decision")]
public virtual bool? PreDecision { get; set; }
///<summary>
///Is this transferee a VIP
///</summary>
[ApiMember(Description="Is this transferee a VIP")]
public virtual bool? VIP { get; set; }
///<summary>
///Custom fields
///</summary>
[ApiMember(Description="Custom fields")]
public virtual List<CustomField> CustomFields { get; set; }
///<summary>
///Employee ID
///</summary>
[ApiMember(Description="Employee ID")]
public virtual string EmployeeId { get; set; }
///<summary>
///Start date
///</summary>
[ApiMember(Description="Start date")]
public virtual DateTime? StartDate { get; set; }
///<summary>
///End date
///</summary>
[ApiMember(Description="End date")]
public virtual DateTime? EndDate { get; set; }
///<summary>
///Origin work location
///</summary>
[ApiMember(Description="Origin work location", IsRequired=true)]
public virtual Location OriginWorkLocation { get; set; }
///<summary>
///Origin home address
///</summary>
[ApiMember(Description="Origin home address", IsRequired=true)]
public virtual Address OriginHomeAddress { get; set; }
///<summary>
///Destination work location
///</summary>
[ApiMember(Description="Destination work location", IsRequired=true)]
public virtual Location DestinationWorkLocation { get; set; }
///<summary>
///Repat
///</summary>
[ApiMember(Description="Repat")]
public virtual string Repat { get; set; }
///<summary>
///Repat From City
///</summary>
[ApiMember(Description="Repat From City")]
public virtual string RepatFromCity { get; set; }
///<summary>
///Repat From State code
///</summary>
[ApiMember(Description="Repat From State code")]
public virtual string RepatFromStateCode { get; set; }
///<summary>
///Repat From Country Code
///</summary>
[ApiMember(Description="Repat From Country Code")]
public virtual string RepatFromCountryCode { get; set; }
///<summary>
///Repat To City
///</summary>
[ApiMember(Description="Repat To City")]
public virtual string RepatToCity { get; set; }
///<summary>
///Repat To State Code
///</summary>
[ApiMember(Description="Repat To State Code")]
public virtual string RepatToStateCode { get; set; }
///<summary>
///Repat To Country Code
///</summary>
[ApiMember(Description="Repat To Country Code")]
public virtual string RepatToCountryCode { get; set; }
///<summary>
///Transferee citizenship country
///</summary>
[ApiMember(Description="Transferee citizenship country")]
public virtual string CitizenshipCountry { get; set; }
///<summary>
///Transferee dual citizenship country
///</summary>
[ApiMember(Description="Transferee dual citizenship country")]
public virtual string DualCitizenshipCountry { get; set; }
///<summary>
///Policy
///</summary>
[ApiMember(Description="Policy", IsRequired=true)]
public virtual string Policy { get; set; }
///<summary>
///Job title
///</summary>
[ApiMember(Description="Job title")]
public virtual string JobTitle { get; set; }
///<summary>
///Marital status
///</summary>
[ApiMember(Description="Marital status", Name="MaritalStatus")]
public virtual MaritalStatus? MaritalStatus { get; set; }
///<summary>
///Pay grade
///</summary>
[ApiMember(Description="Pay grade")]
public virtual string PayGrade { get; set; }
///<summary>
///Assignment family size
///</summary>
[ApiMember(Description="Assignment family size")]
public virtual int? AssignmentFamilySize { get; set; }
///<summary>
///Home owner status
///</summary>
[ApiMember(Description="Home owner status", Name="HomeOwnerStatus")]
public virtual HomeOwnerStatus? HomeOwnerStatus { get; set; }
///<summary>
///Line of business
///</summary>
[ApiMember(Description="Line of business", IsRequired=true)]
public virtual string LineOfBusiness { get; set; }
///<summary>
///HostCurrency
///</summary>
[ApiMember(Description="HostCurrency")]
public virtual string HostCurrency { get; set; }
///<summary>
///ServiceLevel
///</summary>
[ApiMember(Description="ServiceLevel")]
public virtual string ServiceLevel { get; set; }
///<summary>
///CompanyCodePrimary
///</summary>
[ApiMember(Description="CompanyCodePrimary")]
public virtual string CompanyCodePrimary { get; set; }
///<summary>
///CompanyCodeSecondary
///</summary>
[ApiMember(Description="CompanyCodeSecondary")]
public virtual string CompanyCodeSecondary { get; set; }
///<summary>
///CostCenterPrimary
///</summary>
[ApiMember(Description="CostCenterPrimary")]
public virtual string CostCenterPrimary { get; set; }
///<summary>
///CostCenterSecondary
///</summary>
[ApiMember(Description="CostCenterSecondary")]
public virtual string CostCenterSecondary { get; set; }
///<summary>
///CostCenterTertiary
///</summary>
[ApiMember(Description="CostCenterTertiary")]
public virtual string CostCenterTertiary { get; set; }
///<summary>
///Is the assignment confidential
///</summary>
[ApiMember(Description="Is the assignment confidential")]
public virtual bool? Confidential { get; set; }
///<summary>
///Special Instructions
///</summary>
[ApiMember(Description="Special Instructions")]
public virtual string SpecialInstructions { get; set; }
///<summary>
///Destination entity legal name
///</summary>
[ApiMember(Description="Destination entity legal name")]
public virtual string DestinationEntityLegalName { get; set; }
///<summary>
///Transferee mobile phone number
///</summary>
[ApiMember(Description="Transferee mobile phone number", IsRequired=true)]
public virtual string MobilePhoneNumber { get; set; }
///<summary>
///Transferee work phone number
///</summary>
[ApiMember(Description="Transferee work phone number")]
public virtual string WorkPhoneNumber { get; set; }
///<summary>
///Transferee home phone number
///</summary>
[ApiMember(Description="Transferee home phone number")]
public virtual string HomePhoneNumber { get; set; }
///<summary>
///Transferee primary email
///</summary>
[ApiMember(Description="Transferee primary email", IsRequired=true)]
public virtual string PrimaryEmail { get; set; }
///<summary>
///Transferee secondary email
///</summary>
[ApiMember(Description="Transferee secondary email")]
public virtual string SecondaryEmail { get; set; }
///<summary>
///HR Contact First Name
///</summary>
[ApiMember(Description="HR Contact First Name")]
public virtual string HRContactFirstName { get; set; }
///<summary>
///HR Contact Last Name
///</summary>
[ApiMember(Description="HR Contact Last Name")]
public virtual string HRContactLastName { get; set; }
///<summary>
///HR contact full name
///</summary>
[ApiMember(Description="HR contact full name")]
public virtual string HRContactFullName { get; set; }
///<summary>
///Transferee annual salary
///</summary>
[ApiMember(Description="Transferee annual salary")]
public virtual string AnnualSalary { get; set; }
///<summary>
///Transferee spouse/partner
///</summary>
[ApiMember(Description="Transferee spouse/partner")]
public virtual SpousePartner SpousePartner { get; set; }
///<summary>
///Transferee dependents
///</summary>
[ApiMember(Description="Transferee dependents")]
public virtual List<Dependent> Dependents { get; set; }
///<summary>
///Assignment Services
///</summary>
[ApiMember(Description="Assignment Services")]
public virtual List<Service> Services { get; set; }
///<summary>
///Relocation Status
///</summary>
[ApiMember(Description="Relocation Status")]
public virtual string RelocationStatus { get; set; }
///<summary>
///Cancel
///</summary>
[ApiMember(Description="Cancel")]
public virtual string Cancel { get; set; }
}
}
C# TransfereeInitiationRequest DTOs
To override the Content-type in your clients, use the HTTP Accept Header, append the .xml suffix or ?format=xml
The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.
POST /Initiation/Transferee HTTP/1.1
Host: initiation-api-pen.sirva.com
Accept: application/xml
Content-Type: application/xml
Content-Length: length
<TransfereeInitiationRequest xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/SIRVA.Relocation.Services.InitiationGateway.ServiceModel">
<InitiationInfo xmlns:d2p1="http://schemas.datacontract.org/2004/07/SIRVA.Relocation.Services.InitiationGateway.ServiceModel.Types">
<d2p1:AnnualSalary>String</d2p1:AnnualSalary>
<d2p1:AssignmentFamilySize>0</d2p1:AssignmentFamilySize>
<d2p1:AssignmentType>String</d2p1:AssignmentType>
<d2p1:Cancel>String</d2p1:Cancel>
<d2p1:CitizenshipCountry>String</d2p1:CitizenshipCountry>
<d2p1:ClientId>String</d2p1:ClientId>
<d2p1:CompanyCodePrimary>String</d2p1:CompanyCodePrimary>
<d2p1:CompanyCodeSecondary>String</d2p1:CompanyCodeSecondary>
<d2p1:Confidential>false</d2p1:Confidential>
<d2p1:CostCenterPrimary>String</d2p1:CostCenterPrimary>
<d2p1:CostCenterSecondary>String</d2p1:CostCenterSecondary>
<d2p1:CostCenterTertiary>String</d2p1:CostCenterTertiary>
<d2p1:CustomFields>
<d2p1:CustomField>
<d2p1:FieldName>String</d2p1:FieldName>
<d2p1:FieldValue>String</d2p1:FieldValue>
</d2p1:CustomField>
</d2p1:CustomFields>
<d2p1:Dependents>
<d2p1:Dependent>
<d2p1:BirthDate>0001-01-01T00:00:00</d2p1:BirthDate>
<d2p1:FirstName>String</d2p1:FirstName>
<d2p1:LastName>String</d2p1:LastName>
<d2p1:RelationshipToAssignee>Child</d2p1:RelationshipToAssignee>
</d2p1:Dependent>
</d2p1:Dependents>
<d2p1:DestinationEntityLegalName>String</d2p1:DestinationEntityLegalName>
<d2p1:DestinationWorkLocation>
<d2p1:City>String</d2p1:City>
<d2p1:CountryCode>String</d2p1:CountryCode>
<d2p1:StateCode>String</d2p1:StateCode>
<d2p1:Title>String</d2p1:Title>
</d2p1:DestinationWorkLocation>
<d2p1:DualCitizenshipCountry>String</d2p1:DualCitizenshipCountry>
<d2p1:EmployeeId>String</d2p1:EmployeeId>
<d2p1:EndDate>0001-01-01T00:00:00</d2p1:EndDate>
<d2p1:ExternalId>String</d2p1:ExternalId>
<d2p1:FirstName>String</d2p1:FirstName>
<d2p1:HRContactFirstName>String</d2p1:HRContactFirstName>
<d2p1:HRContactFullName>String</d2p1:HRContactFullName>
<d2p1:HRContactLastName>String</d2p1:HRContactLastName>
<d2p1:HomeOwnerStatus>Homeowner</d2p1:HomeOwnerStatus>
<d2p1:HomePhoneNumber>String</d2p1:HomePhoneNumber>
<d2p1:HostCurrency>String</d2p1:HostCurrency>
<d2p1:JobTitle>String</d2p1:JobTitle>
<d2p1:LastName>String</d2p1:LastName>
<d2p1:LineOfBusiness>String</d2p1:LineOfBusiness>
<d2p1:MaritalStatus>Single</d2p1:MaritalStatus>
<d2p1:MobilePhoneNumber>String</d2p1:MobilePhoneNumber>
<d2p1:OriginHomeAddress>
<d2p1:City>String</d2p1:City>
<d2p1:CountryCode>String</d2p1:CountryCode>
<d2p1:StateCode>String</d2p1:StateCode>
<d2p1:Title>String</d2p1:Title>
<d2p1:Line1>String</d2p1:Line1>
<d2p1:Line2>String</d2p1:Line2>
<d2p1:Line3>String</d2p1:Line3>
<d2p1:PostalCode>String</d2p1:PostalCode>
</d2p1:OriginHomeAddress>
<d2p1:OriginWorkLocation>
<d2p1:City>String</d2p1:City>
<d2p1:CountryCode>String</d2p1:CountryCode>
<d2p1:StateCode>String</d2p1:StateCode>
<d2p1:Title>String</d2p1:Title>
</d2p1:OriginWorkLocation>
<d2p1:PayGrade>String</d2p1:PayGrade>
<d2p1:Policy>String</d2p1:Policy>
<d2p1:PreDecision>false</d2p1:PreDecision>
<d2p1:PrimaryEmail>String</d2p1:PrimaryEmail>
<d2p1:RelocationStatus>String</d2p1:RelocationStatus>
<d2p1:Repat>String</d2p1:Repat>
<d2p1:RepatFromCity>String</d2p1:RepatFromCity>
<d2p1:RepatFromCountryCode>String</d2p1:RepatFromCountryCode>
<d2p1:RepatFromStateCode>String</d2p1:RepatFromStateCode>
<d2p1:RepatToCity>String</d2p1:RepatToCity>
<d2p1:RepatToCountryCode>String</d2p1:RepatToCountryCode>
<d2p1:RepatToStateCode>String</d2p1:RepatToStateCode>
<d2p1:SecondaryEmail>String</d2p1:SecondaryEmail>
<d2p1:ServiceLevel>String</d2p1:ServiceLevel>
<d2p1:Services>
<d2p1:Service>
<d2p1:Cancel>String</d2p1:Cancel>
<d2p1:Data>
<d2p1:ServiceData>
<d2p1:FieldName>String</d2p1:FieldName>
<d2p1:FieldValue>String</d2p1:FieldValue>
</d2p1:ServiceData>
</d2p1:Data>
<d2p1:Name>String</d2p1:Name>
</d2p1:Service>
</d2p1:Services>
<d2p1:SpecialInstructions>String</d2p1:SpecialInstructions>
<d2p1:SpousePartner>
<d2p1:BirthDate>0001-01-01T00:00:00</d2p1:BirthDate>
<d2p1:FirstName>String</d2p1:FirstName>
<d2p1:LastName>String</d2p1:LastName>
</d2p1:SpousePartner>
<d2p1:StartDate>0001-01-01T00:00:00</d2p1:StartDate>
<d2p1:VIP>false</d2p1:VIP>
<d2p1:WorkPhoneNumber>String</d2p1:WorkPhoneNumber>
</InitiationInfo>
</TransfereeInitiationRequest>
HTTP/1.1 200 OK Content-Type: application/xml Content-Length: length <TransfereeInitiationResponse xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/SIRVA.Relocation.Services.InitiationGateway.ServiceModel"> <ResponseStatus xmlns:d2p1="http://schemas.servicestack.net/types"> <d2p1:ErrorCode>String</d2p1:ErrorCode> <d2p1:Message>String</d2p1:Message> <d2p1:StackTrace>String</d2p1:StackTrace> <d2p1:Errors> <d2p1:ResponseError> <d2p1:ErrorCode>String</d2p1:ErrorCode> <d2p1:FieldName>String</d2p1:FieldName> <d2p1:Message>String</d2p1:Message> <d2p1:Meta xmlns:d5p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays"> <d5p1:KeyValueOfstringstring> <d5p1:Key>String</d5p1:Key> <d5p1:Value>String</d5p1:Value> </d5p1:KeyValueOfstringstring> </d2p1:Meta> </d2p1:ResponseError> </d2p1:Errors> <d2p1:Meta xmlns:d3p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays"> <d3p1:KeyValueOfstringstring> <d3p1:Key>String</d3p1:Key> <d3p1:Value>String</d3p1:Value> </d3p1:KeyValueOfstringstring> </d2p1:Meta> </ResponseStatus> </TransfereeInitiationResponse>