companies house error-608



I was try to access company house xml api,The following is my code I got XML schemas from here http://ift.tt/Uf6pYV



$company_name = 'COMPAMY NAME';
$tr_id = rand(0,100);
$value = 'XMLGatewayTestUserID'.'XMLGatewayTestPassword'.$tr_id;
$value = md5($value);

$senderid =md5('SENDER ID');


$xml = '<?xml version="1.0" encoding="utf-8"?>
<GovTalkMessage xmlns="http://ift.tt/WmEw3h" xmlns:dsig="http://ift.tt/uq6naF" xmlns:gt="http://ift.tt/WmEw3j" xmlns:xsi="http://ift.tt/ra1lAU" xsi:schemaLocation="http://ift.tt/WmEw3h http://ift.tt/Uf6snI">
<EnvelopeVersion>1.0</EnvelopeVersion>
<Header>
<MessageDetails>
<Class>CompanyIncorporation</Class>
<Qualifier>request</Qualifier>
<TransactionID>'.$tr_id.'</TransactionID>
<GatewayTest>1</GatewayTest>
</MessageDetails>
<SenderDetails>
<IDAuthentication>
<SenderID>'.$senderid.'</SenderID>
<Authentication>
<Method>clear</Method>
<Value>'.$value.'</Value>
</Authentication>
</IDAuthentication>
</SenderDetails>
</Header>
<GovTalkDetails>
<Keys/>
</GovTalkDetails>
<Body>
<FormSubmission xmlns="http://ift.tt/WmEw3l" xmlns:bs="http://ift.tt/1oDa3aN" xmlns:xsi="http://ift.tt/ra1lAU" xsi:schemaLocation="http://ift.tt/WmEw3l http://ift.tt/WmEx7o">
<FormHeader>
<CompanyName>PHIL COMPANY 03 LIMITED</CompanyName>
<PackageReference>1828</PackageReference>
<FormIdentifier>CompanyIncorporation</FormIdentifier>
<SubmissionNumber>INCb05</SubmissionNumber>
</FormHeader>
<DateSigned>2010-04-01</DateSigned>
<Form>
<CompanyIncorporation xsi:schemaLocation="http://ift.tt/1oDa3aN
http://ift.tt/Uf6pZ7" xmlns="http://ift.tt/1oDa3aN" xmlns:xsi="http://ift.tt/ra1lAU">

<CompanyType>BYSHR</CompanyType>
<CountryOfIncorporation>EW</CountryOfIncorporation>
<RegisteredOfficeAddress>
<Premise>20</Premise>
<Street>Coeden Dal</Street>
<Thoroughfare>Pentwyn</Thoroughfare>
<PostTown>Cardiff</PostTown>
<Country>GB-WLS</Country>
<Postcode>CF23 7DH</Postcode>
</RegisteredOfficeAddress>
<Articles>BESPOKE</Articles>
<RestrictedArticles>false</RestrictedArticles>

<Appointment>
<Authentication>
<PersonalAttribute>BIRTOWN</PersonalAttribute>
<PersonalData>HAV</PersonalData>
</Authentication>
<Authentication>
<PersonalAttribute>DAD</PersonalAttribute>
<PersonalData>FRE</PersonalData>
</Authentication>
<Authentication>
<PersonalAttribute>EYE</PersonalAttribute>
<PersonalData>BLU</PersonalData>
</Authentication>
<Director>
<Person>
<Title>Mr</Title>
<Forename>TOM</Forename>
<Surname>WATSON</Surname>

<ServiceAddress>
<Address>
<Premise>9</Premise>
<Street>Woodland View</Street>
<PostTown>PONTYPRIDD</PostTown>
<Country>GBR</Country>
<Postcode>CF38 1RW</Postcode>
</Address>
</ServiceAddress>
<DOB>1977-08-13</DOB>
<Nationality>British</Nationality>
<Occupation>Director</Occupation>
<CountryOfResidence>United Kingdom</CountryOfResidence>
<ResidentialAddress>
<Address>
<Premise>3</Premise>
<Street>High Street</Street>
<PostTown>Haverfordwest</PostTown>
<County>Dyfed</County>
<Country>GBR</Country>
<Postcode>SA62 6SA</Postcode>
</Address>
</ResidentialAddress>
</Person>
</Director>
</Appointment>

<Appointment>
<Authentication>
<PersonalAttribute>BIRTOWN</PersonalAttribute>
<PersonalData>HAV</PersonalData>
</Authentication>
<Authentication>
<PersonalAttribute>DAD</PersonalAttribute>
<PersonalData>FRE</PersonalData>
</Authentication>
<Authentication>
<PersonalAttribute>EYE</PersonalAttribute>
<PersonalData>BLU</PersonalData>
</Authentication>
<Director>
<Corporate>
<Forename>Phil Marvin</Forename>
<Surname>Glover</Surname>
<CorporateName>Test Team Ltd</CorporateName>
<Address>
<Premise>19</Premise>
<Street>Winnipeg Drive</Street>
<PostTown>Cardiff</PostTown>
<Country>GB-WLS</Country>
<Postcode>CF28 6ET</Postcode>
</Address>
<CompanyIdentification>
<EEA>
<PlaceRegistered>Wales</PlaceRegistered>
<RegistrationNumber>121212</RegistrationNumber>
</EEA>
</CompanyIdentification>
</Corporate>
</Director>
</Appointment>

<Appointment>
<Authentication>
<PersonalAttribute>BIRTOWN</PersonalAttribute>
<PersonalData>SWA</PersonalData>
</Authentication>
<Authentication>
<PersonalAttribute>DAD</PersonalAttribute>
<PersonalData>BIL</PersonalData>
</Authentication>
<Authentication>
<PersonalAttribute>EYE</PersonalAttribute>
<PersonalData>HAZ</PersonalData>
</Authentication>
<Secretary>
<Person>
<Forename>Steve</Forename>
<OtherForenames>Gareth Harold</OtherForenames>
<Surname>HORTON</Surname>
<ServiceAddress>
<Address>
<Premise>14</Premise>
<Street>COEDEN DAL</Street>
<PostTown>CARDIFF</PostTown>
<Country>GBR</Country>
<Postcode>CF23 7DH</Postcode>
</Address>
</ServiceAddress>
</Person>
</Secretary>
</Appointment>

<StatementOfCapital>
<Capital>
<TotalNumberOfIssuedShares>2</TotalNumberOfIssuedShares>
<ShareCurrency>GBP</ShareCurrency>
<TotalAggregateNominalValue>4.00</TotalAggregateNominalValue>
<Shares>
<ShareClass>ORD</ShareClass>
<PrescribedParticulars>One vote per share, with residual interest, Equal rights to dividends, No option to redeem etc ...........</PrescribedParticulars>
<NumShares>2</NumShares>
<AmountPaidDuePerShare>2.00</AmountPaidDuePerShare>
<AmountUnpaidPerShare>0</AmountUnpaidPerShare>
<AggregateNominalValue>4.00</AggregateNominalValue>
</Shares>
</Capital>
</StatementOfCapital>

<Subscribers>
<Person>
<Forename>PHIL</Forename>
<Surname>WILLIAMS</Surname>
</Person>
<Address>
<Premise>12</Premise>
<Street>COEDEN DAL</Street>
<Thoroughfare>PENTWYN</Thoroughfare>
<PostTown>CARDIFF</PostTown>
<County>SOUTH GLAMORGAN</County>
<Country>GBR</Country>
<Postcode>CF23 7DH</Postcode>
</Address>
<Authentication>
<PersonalAttribute>BIRTOWN</PersonalAttribute>
<PersonalData>MIL</PersonalData>
</Authentication>
<Authentication>
<PersonalAttribute>DAD</PersonalAttribute>
<PersonalData>FRE</PersonalData>
</Authentication>
<Authentication>
<PersonalAttribute>EYE</PersonalAttribute>
<PersonalData>BLU</PersonalData>
</Authentication>
<Shares>
<ShareClass>ORD</ShareClass>
<NumShares>1</NumShares>
<AmountPaidDuePerShare>2.00</AmountPaidDuePerShare>
<AmountUnpaidPerShare>0</AmountUnpaidPerShare>
<ShareCurrency>GBP</ShareCurrency>
<ShareValue>2.00</ShareValue>
</Shares>
</Subscribers>

<Subscribers>
<Corporate>
<Forename>CURTIS</Forename>
<Surname>STRANGE</Surname>
<CorporateName>Gogga Limited</CorporateName>
</Corporate>
<Address>
<Premise>12</Premise>
<Street>COEDEN DAL</Street>
<Thoroughfare>PENTWYN</Thoroughfare>
<PostTown>CARDIFF</PostTown>
<County>SOUTH GLAMORGAN</County>
<Country>GBR</Country>
<Postcode>CF29 7DH</Postcode>
</Address>
<Authentication>
<PersonalAttribute>BIRTOWN</PersonalAttribute>
<PersonalData>MIL</PersonalData>
</Authentication>
<Authentication>
<PersonalAttribute>DAD</PersonalAttribute>
<PersonalData>FRE</PersonalData>
</Authentication>
<Authentication>
<PersonalAttribute>EYE</PersonalAttribute>
<PersonalData>BLU</PersonalData>
</Authentication>
<Shares>
<ShareClass>ORD</ShareClass>
<NumShares>1</NumShares>
<AmountPaidDuePerShare>2.00</AmountPaidDuePerShare>
<AmountUnpaidPerShare>0</AmountUnpaidPerShare>
<ShareCurrency>GBP</ShareCurrency>
<ShareValue>2.00</ShareValue>
</Shares>
</Subscribers>


<Authoriser>
<Agent>
<Person>
<Forename>Mickey</Forename>
<Surname>Mouse</Surname>
</Person>

<Authentication>
<PersonalAttribute>BIRTOWN</PersonalAttribute>
<PersonalData>Car</PersonalData>
</Authentication>
<Authentication>
<PersonalAttribute>DAD</PersonalAttribute>
<PersonalData>Ric</PersonalData>
</Authentication>
<Authentication>
<PersonalAttribute>EYE</PersonalAttribute>
<PersonalData>Blu</PersonalData>
</Authentication>
<Address>
<Premise>19</Premise>
<Street>Winnipeg Drive</Street>
<PostTown>Cardiff</PostTown>
<Country>GB-WLS</Country>
<Postcode>CF23 6ET</Postcode>
</Address>
</Agent>
</Authoriser>



<SameDay>false</SameDay>
<SameName>false</SameName>
<NameAuthorisation>true</NameAuthorisation>

</CompanyIncorporation>
</Form>

</FormSubmission>
</Body>
</GovTalkMessage>';


$url = "http://ift.tt/1cNHAZT";

$ch = curl_init($url);
curl_setopt($ch, CURLOPT_MUTE, 1);
curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, true);
curl_setopt($ch, CURLOPT_SSL_VERIFYHOST, 2);
curl_setopt($ch, CURLOPT_POST, 1);
curl_setopt($ch, CURLOPT_HTTPHEADER, array('Content-Type: text/xml'));
curl_setopt($ch, CURLPROTO_HTTPS, 1);
curl_setopt($ch, CURLOPT_HEADER, 1);
curl_setopt($ch, CURLOPT_POSTFIELDS, "$xml");
curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);

$output = curl_exec($ch);
curl_close($ch);

print_r($output);


But it always return an xml conatains error as follows.



<GovTalkDetails>
<Keys/>
<GovTalkErrors>
<Error>
<RaisedBy>CompanyIncorporation</RaisedBy>
<Number>608</Number>
<Type>fatal</Type>
<Text>Not a HTTPS request [CompanyIncorporation]</Text>
<Location></Location>
</Error>
</GovTalkErrors>
</GovTalkDetails>

No comments:

Post a Comment