Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Fælles for disse eksempler er at [brugernavn] og [adgangskode] skal erstattes med faktiske værdier.

AddJob - opret jobannonce på jobnet.dk

Dette SOAP kald opretter en jobannonce på jobnet.dk. Ved succesfuld oprettelse returneres jobannoncens ID.


Request:

<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:job="http://jobnet.af.dk/JobAdService" xmlns:job1="http://schemas.datacontract.org/2004/07/JobAdService.DataContract" xmlns:job2="http://schemas.datacontract.org/2004/07/JobAdService.v1.DataContract">
<soapenv:Header>
<job:Credentials>
<job1:Password>[adgangskode]</job1:Password>
<job1:Username>[brugernavn]</job1:Username>
</job:Credentials>
</soapenv:Header>
<soapenv:Body>
<job:AddJobRequestType>
<job:jobAd>
<job:ApplicationDetails>
<job:ApplicationMethods>
<job:ApplyOnline>
<job:Url><![CDATA[https://ssl1.peoplexs.com/Peoplexs22/CandidatesPortalNoLogin/ApplicationForm.cfm?PortalID=2035&VacatureID=929638]]></job:Url>
</job:ApplyOnline>
</job:ApplicationMethods>
<job:JobContactList>
<job2:JobContactType>
<job:Email>test@testing.dk</job:Email>
<job:PersonNameStructure>
<job:PersonGivenName>Nora</job:PersonGivenName>
<job:PersonSurnameName>Malkeko</job:PersonSurnameName>
</job:PersonNameStructure>
<job:Title>HR-teamleder</job:Title>
<job2:HidePhoneNumbers>false</job2:HidePhoneNumbers>
<job2:TelephoneNumberStructure>
<job:PrimaryNumber>22334455</job:PrimaryNumber>
</job2:TelephoneNumberStructure>
</job2:JobContactType>
</job:JobContactList>
</job:ApplicationDetails>
<job:HiringOrganizationDetails>
<job:AddressStructure>
<job:CountryCode>DK</job:CountryCode>
<job:MunicipalityId>101</job:MunicipalityId>
<job:MunicipalityName>København</job:MunicipalityName>
<job:PostalCity>København Ø</job:PostalCity>
<job:PostalCode>2100</job:PostalCode>
<job:StreetBuildingIdentifier>11</job:StreetBuildingIdentifier>
<job:StreetName>Lyngbyvej</job:StreetName>
</job:AddressStructure>
<job:CvrNumber>35954716</job:CvrNumber>
<job:Name>FØTEX</job:Name>
<job:PNumber>1013466951</job:PNumber>
</job:HiringOrganizationDetails>
<job:JobAdDetails>
<job:JobPublishDates>
<job:PublishEndDate>2017-11-08T00:00:00.0000000+01:00</job:PublishEndDate>
<job:PublishStartDate>2017-09-14T00:00:00.0000000+02:00</job:PublishStartDate>
</job:JobPublishDates>
<job:PostedBy>
<job:Email>fra@test.dk</job:Email>
<job:PersonNameStructure>
<job:PersonGivenName>Fætter</job:PersonGivenName>
<job:PersonSurnameName>Højben</job:PersonSurnameName>
</job:PersonNameStructure>
<job:Title>HR-konsulent</job:Title>
<job2:ContactGuid>eef750d1-2bb6-e511-80cc-40f2e9c3d2fc</job1:ContactGuid>
<job2:PrimaryNumber>87785000</job1:PrimaryNumber>
</job:PostedBy>
<job:Type>Normal</job:Type>
</job:JobAdDetails>
<job:JobDetails>
<job:AuthorityId>0</job:AuthorityId>
<job:Classification>
<job:EmploymentType>PermanentJob</job:EmploymentType>
<job:IsEuresJob>false</job:IsEuresJob>
<job:IsPublicSectorJob>false</job:IsPublicSectorJob>
<job:IsWorkInDenmarkJob>false</job:IsWorkInDenmarkJob>
</job:Classification>
<job:Description><![CDATA[<p>Som teamkoordinator i Kundeservice refererer du til service- og personalechefen, samt teamlederen. Du bliver ansvarlig for dine egne opgaver relateret til den daglige drift af kasselinje, bager og kundeservice.</p>
<p>Dine fokusomr&aring;der er optimering af bemanding og driften af kundeservice og kasselinje, hvor du skal sikre den bedste indk&oslash;bsoplevelse for vores kunder.&nbsp;<br /><br /><strong>Dine opgaver</strong></p>
<ul>
<li>Du st&aring;r for at planl&aelig;gge og optimere bemandingen - herunder udarbejdelse af bemandingsplaner i vores postbutik og bagerudsalg.</li>
<li>Du kommer til at f&oslash;lge op p&aring; driftsrutiner i Kundeservice</li>
<li>Du arbejder med at vedligeholde og videreudvikle vores h&oslash;je serviceniveau</li>
</ul>
<p>I takt med, at du udvikler dig, vil du f&aring; mere og mere ledelsesansvar for afdelingens medarbejdere.<br /><br />
<strong>Kvalifikationer<br /></strong>
Du er udadvendt, service- og kundeorienteret, og du g&oslash;r dit til at sikre kunden den bedste oplevelse. Du har et stort overblik, en bred viden om service generelt og er en god rollemodel. Dine evner til at samarbejde og kommunikere er i top, og du kan motivere dine kolleger til at yde deres bedste.<br /><br />
<strong>Gode karrieremuligheder<br /></strong>
Vi tilbyder til geng&aelig;ld et sp&aelig;ndende job med gode karrieremuligheder inden for Dansk Supermarked. Varehuset besk&aelig;ftiger ca. 200 medarbejdere, som gl&aelig;der sig til at byde dig velkommen.<br /><br />
<strong>L&oslash;n</strong><br />Efter kvalifikationer.</p>]]>
</job:Description>
<job:HidePhonenumbers>false</job:HidePhonenumbers>
<job:IsAnonymousEmployer>false</job:IsAnonymousEmployer>
<job:IsDisabilityFriendly>false</job:IsDisabilityFriendly>
<job:JobDates>
<job:ApplicationDeadlineDate>2017-11-08T00:00:00.0000000+01:00</job:ApplicationDeadlineDate>
<job:StartAsSoonAsPossible>true</job:StartAsSoonAsPossible>
</job:JobDates>
<job:JobLocation>
<job:Address>
<job:CountryCode>DK</job:CountryCode>
<job:MunicipalityId>101</job:MunicipalityId>
<job:MunicipalityName>København</job:MunicipalityName>
<job:PostalCity>København Ø</job:PostalCity>
<job:PostalCode>2100</job:PostalCode>
<job:StreetBuildingIdentifier>11</job:StreetBuildingIdentifier>
<job:StreetName>Lyngbyvej</job:StreetName>
</job:Address>
<job:NoLocalBusinessAddress>false</job:NoLocalBusinessAddress>
</job:JobLocation>
<job:NumberOfPositions>1</job:NumberOfPositions>
<job:OccupationId>1219902</job:OccupationId>
<job:Schedule>
<job:DailyWorkTime>
<job:Day>false</job:Day>
<job:Evening>false</job:Evening>
<job:Night>false</job:Night>
<job:Weekend>false</job:Weekend>
</job:DailyWorkTime>
<job:WeeklyWorkTimeTypes>PartTime</job:WeeklyWorkTimeTypes>
<job:WorkHour>
<job:Max>25</job:Max>
<job:Min>20</job:Min>
</job:WorkHour>
</job:Schedule>
<job:Title>Teamkoordinator til serviceafdelingen</job:Title>
</job:JobDetails>
</job:jobAd>
</job:AddJobRequestType>
</soapenv:Body>
</soapenv:Envelope>


Påkrævet felter

Det kan være svært at se hvilke felter der påkrævet ud fra requestet. Men følgende felter kræves udfyldt:

<job:JobAdDetails>
   <job:Type>...</job:Type>
</job:JobAdDetails>

<ApplicationDetails>
   <JobContactList>
      <PersonNameStructure>
           <PersonGivenName>...</PersonGivenName>
           <PersonSurnameName>...</PersonSurnameName>
      </PersonNameStructure>
   </JobContactList>
</ApplicationDetails>

<HiringOrganizationDetails>
    <AddressStructure>
       <Contact>
           <PersonNameStructure>
               <PersonGivenName>...</PersonGivenName>
               <PersonSurnameName>...</PersonSurnameName>
           </PersonNameStructure>
       </Contact>
    </AddressStructure>
</HiringOrganizationDetails>


Response:

<s:Envelope xmlns:s="http://schemas.xmlsoap.org/soap/envelope/">
<s:Body>
<AddJobResponse xmlns="http://jobnet.af.dk/JobAdService">
<AddJobResult>4455828</AddJobResult>
</AddJobResponse>
</s:Body>
</s:Envelope>

SearchJob - søg publicerede jobannoncer

Dette SOAP kald fremsøger aktuelt publicerede jobannonce på jobnet.dk.


Request:

<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:job="http://jobnet.af.dk/JobAdService" xmlns:job1="http://schemas.datacontract.org/2004/07/JobAdService.DataContract">
<soapenv:Header>

<job:Credentials>
<job1:Password>[adgangskode]</job1:Password>
<job1:Username>[brugernavn]</job1:Username>
</job:Credentials>
</soapenv:Header>
<soapenv:Body>
<job:SearchJobRequestType>
<job:SearchParameters>
<job:CreatedFrom>2001-01-01</job:CreatedFrom>
<job:CreatedTo>2018-01-01</job:CreatedTo>
</job:SearchParameters>
</job:SearchJobRequestType>
</soapenv:Body>
</soapenv:Envelope>


Da dette request potentielt kan levere ganske mange søgeresultater kan man med fordel sætte paging op eller præcisere søgningen med fx JobAttributes.


Request:

<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:job="http://jobnet.af.dk/JobAdService" xmlns:job1="http://schemas.datacontract.org/2004/07/JobAdService.DataContract">
<soapenv:Header>

<job:Credentials>
<job1:Password>[adgangskode]</job1:Password>
<job1:Username>[brugernavn]</job1:Username>
</job:Credentials>
</soapenv:Header>
<soapenv:Body>
<job:SearchJobRequestType>
<job:SearchParameters>
<job:CompanyName>FØTEX</job:CompanyName>
<job:CreatedFrom>2017-01-01</job:CreatedFrom>
<job:CreatedTo>2018-01-01</job:CreatedTo>
<job:JobAttributes>
<job:JobAttribute>WorkInDenmark</job:JobAttribute>
<job:JobAttribute>EURES</job:JobAttribute>
<job:JobAttribute>Foreign</job:JobAttribute>
<job:JobAttribute>State</job:JobAttribute>
</job:JobAttributes>
</job:SearchParameters>
</job:SearchJobRequestType>
</soapenv:Body>
</soapenv:Envelope>


Response:

<s:Envelope xmlns:s="http://schemas.xmlsoap.org/soap/envelope/">
<s:Body>
<SearchJobResponse xmlns="http://jobnet.af.dk/JobAdService">
<SearchJobResult xmlns:i="http://www.w3.org/2001/XMLSchema-instance">
<SearchResult>
<Created>2017-02-14T00:00:00</Created>
<JobAdId>4410682</JobAdId>
<NumberOfViews>0</NumberOfViews>
<OccupationName i:nil="true"/>
<PublishedBy i:nil="true"/>
<PublishedFrom>9999-12-31T00:00:00</PublishedFrom>
<PublishedTo>9999-12-31T00:00:00</PublishedTo>
<Status>NotReady</Status>
<Title/>
</SearchResult>
<SearchResult>
<Created>2017-02-14T00:00:00</Created>
<JobAdId>4410850</JobAdId>
<NumberOfViews>0</NumberOfViews>
<OccupationName i:nil="true"/>
<PublishedBy i:nil="true"/>
<PublishedFrom>9999-12-31T00:00:00</PublishedFrom>
<PublishedTo>9999-12-31T00:00:00</PublishedTo>
<Status>NotReady</Status>
<Title/>
</SearchResult>
</SearchJobResult>
</SearchJobResponse>
</s:Body>
</s:Envelope>

GetJob - hent jobannonce

Dette SOAP kald henter en jobannonce, som er fremsøgt i listen herover

[id] skal erstattes med et kendt JobAdId.


Request:

<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:job="http://jobnet.af.dk/JobAdService" xmlns:job1="http://schemas.datacontract.org/2004/07/JobAdService.DataContract">
<soapenv:Header>

<job:Credentials>
<job1:Password>[adgangskode]</job1:Password>
<job1:Username>[brugernavn]</job1:Username>
</job:Credentials>
</soapenv:Header>
<soapenv:Body>
<job:GetJobRequestType>
<job:JobAdId>[id]</job:JobAdId>
</job:GetJobRequestType>
</soapenv:Body>
</soapenv:Envelope>


Response:

<s:Envelope xmlns:s="http://schemas.xmlsoap.org/soap/envelope/">
<s:Body>
<GetJobResponseType xmlns="http://jobnet.af.dk/JobAdService">
<JobAd xmlns:i="http://www.w3.org/2001/XMLSchema-instance">
<ApplicationDetails>
<ApplicationMethods>
<ApplyByEmail>
<Email>test@igen.dk</Email>
</ApplyByEmail>
<ApplyByLetter>false</ApplyByLetter>
<ApplyByTelephone>
<TelephoneNumber>33445566</TelephoneNumber>
</ApplyByTelephone>
<ApplyOnline i:nil="true"/>
</ApplicationMethods>
<Description i:nil="true"/>
<JobContactList xmlns:a="http://schemas.datacontract.org/2004/07/JobAdService.v1.DataContract">
<a:JobContactType>
<Email>test@mer.dk</Email>
<PersonNameStructure>
<PersonGivenName>Anders</PersonGivenName>
<PersonSurnameName>And</PersonSurnameName>
</PersonNameStructure>
<Title>Entreprenør</Title>
<a:HidePhoneNumbers>false</a:HidePhoneNumbers>
<a:TelephoneNumberStructure>
<MobileNumber/>
<PrimaryNumber>55667788</PrimaryNumber>
<SecondaryNumber/>
<Telefax>55667789</Telefax>
</a:TelephoneNumberStructure>
</a:JobContactType>
</JobContactList>
<Referral>Karsten Elbæk</Referral>
</ApplicationDetails>
<HiringOrganizationDetails>
<AddressStructure>
<CountryCode>DK</CountryCode>
<FloorIdentifier/>
<MunicipalityId>360</MunicipalityId>
<MunicipalityName>Lolland</MunicipalityName>
<PostalCity>Maribo</PostalCity>
<PostalCode>4930</PostalCode>
<StreetBuildingIdentifier>7</StreetBuildingIdentifier>
<StreetName>V Henriksens Vej</StreetName>
<SuiteIdentifier/>
</AddressStructure>
<BranchCode i:nil="true"/>
<BranchDescription i:nil="true"/>
<Contact xmlns:a="http://schemas.datacontract.org/2004/07/JobAdService.v1.DataContract">
<Email>mne@mne.dk</Email>
<PersonNameStructure>
<PersonGivenName i:nil="true"/>
<PersonSurnameName i:nil="true"/>
</PersonNameStructure>
<Title i:nil="true"/>
<a:PrimaryNumber>55667788</a:PrimaryNumber>
<a:SecondaryNumber i:nil="true"/>
<a:Telefax>55667789</a:Telefax>
</Contact>
<CvrNumber>24212254</CvrNumber>
<Name>M.N. Entreprise A/S</Name>
<PNumber>1006412573</PNumber>
<Url/>
</HiringOrganizationDetails>
<Id>1188921</Id>
<JobAdDetails>
<JobPublishDates>
<LastModifiedDate>2007-12-13T16:47:32.05</LastModifiedDate>
<PublishEndDate>2017-09-10T00:00:00</PublishEndDate>
<PublishStartDate>2017-08-02T00:00:00</PublishStartDate>
</JobPublishDates>
<NumberOfReadsByCitizen>504</NumberOfReadsByCitizen>
<PostedBy i:nil="true" xmlns:a="http://schemas.datacontract.org/2004/07/JobAdService.v1.DataContract"/>
<Status>PublicationEnd</Status>
<Type>Normal</Type>
</JobAdDetails>
<JobDetails>
<AuthorityId>0</AuthorityId>
<AuthorityPhoneNumber/>
<Classification>
<EmploymentType>PermanentJob</EmploymentType>
<IsEuresJob>false</IsEuresJob>
<IsPublicSectorJob>false</IsPublicSectorJob>
</Classification>
<Description>Tømrersvende søges til selvstændigt arbejde. Må kunne tale og forstå dansk. Henvendelse til Karsten Elbæk på tlf. 20826213 eller Martin Nielsen tlf. 25377500.</Description>
<DriversLicences/>
<HidePhonenumbers>false</HidePhonenumbers>
<IsAnonymousEmployer>false</IsAnonymousEmployer>
<IsDisabilityFriendly>false</IsDisabilityFriendly>
<JobDates>
<ApplicationDeadlineDate>2017-09-10T00:00:00</ApplicationDeadlineDate>
<EmploymentDate i:nil="true"/>
<StartAsSoonAsPossible>true</StartAsSoonAsPossible>
</JobDates>
<JobLocation>
<Address>
<CountryCode>DK</CountryCode>
<FloorIdentifier i:nil="true"/>
<MunicipalityId>360</MunicipalityId>
<MunicipalityName>Lolland</MunicipalityName>
<PostalCity i:nil="true"/>
<PostalCode i:nil="true"/>
<StreetBuildingIdentifier i:nil="true"/>
<StreetName i:nil="true"/>
<SuiteIdentifier i:nil="true"/>
</Address>
<NoLocalBusinessAddress>false</NoLocalBusinessAddress>
</JobLocation>
<NumberOfPositions>3</NumberOfPositions>
<OccupationId>7115101</OccupationId>
<Schedule>
<DailyWorkTime>
<Day>false</Day>
<Evening>false</Evening>
<Night>false</Night>
<Weekend>false</Weekend>
</DailyWorkTime>
<WeeklyWorkTimeTypes>FullTime</WeeklyWorkTimeTypes>
<WorkHour>
</WorkHour>
</Schedule>
<Title>Tømrer/Snedkere søges</Title>
</JobDetails>
</JobAd>
</GetJobResponseType>
</s:Body>
</s:Envelope>

Fejlkoder

Dette SOAP kald returnerer en fejlkode på grund af valideringsfejl. Se oversigt over fejlkoder her

Eksempel på kald med ugyldigt JobAdID.


Request:

<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:job="http://jobnet.af.dk/JobAdService" xmlns:job1="http://schemas.datacontract.org/2004/07/JobAdService.DataContract">
<soapenv:Header>

<job:Credentials>
<job1:Password>[adgangskode]</job1:Password>
<job1:Username>[brugernavn]</job1:Username>
</job:Credentials>
</soapenv:Header>
<soapenv:Body>
<job:GetJobRequestType>
<job:JobAdId>42</job:JobAdId>
</job:GetJobRequestType>
</soapenv:Body>
</soapenv:Envelope>


Response:

<s:Envelope xmlns:s="http://schemas.xmlsoap.org/soap/envelope/">
<s:Body>
<s:Fault>
<faultcode>s:Client</faultcode>
<faultstring xml:lang="en-US">JobAd exception when calling GetJob method. Details: The job with id 42 could not be found</faultstring>
<detail>
<JobAdFault xmlns="http://jobnet.af.dk/JobAdService" xmlns:i="http://www.w3.org/2001/XMLSchema-instance">
<Code>JobAdNotFound</Code>
<Message>JobAd exception when calling GetJob method. Details: The job with id 42 could not be found</Message>
</JobAdFault>
</detail>
</s:Fault>
</s:Body>
</s:Envelope>

Eksempel i C#

Her vises et eksempel hvordan et kald til JobAdService skabes med C#. Her er vist et kald til hhv. funktionen GetJob og SearchJob.

private void GetJob()
{
    JobAddServiceClient jobAdService = new JobAddServiceClient("IJobAddService");
    JobAd jobb = jobAdService.GetJob(new Credentials { Username = [brugernavn], Password = [adgangskode] }, 4534569);
    Console.WriteLine(jobb);

}

private void SearchJob()
{
   JobAddServiceClient jobAdService = new JobAddServiceClient("IJobAddService");
   SearchParameters sp = new SearchParameters();
   sp.CreatedFrom = DateTime.Now.AddDays(-400);
   sp.CreatedTo = DateTime.Now;
   sp.PageSize = 10;
   sp.PageNumber = 0;
   sp.Status = Status.Publication;
   sp.JobAttributes = new JobAttribute[] { JobAttribute.EURES };
   SearchResult[] jobs = jobAdService.SearchJob(new Credentials { Username = [brugernavn], Password = [adgangskode] }, sp);
   Console.WriteLine(jobs);

}

Her kan du se en demo console application i c#.

View file
nameTestJobAd.zip
height250

...