flibustenet / dpae

Envoi d'une DPAE vers l'Urssaf

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

DPAE not accepted

maxmg opened this issue · comments

First, thanks for sharing this sample.

Did you succeed to declare a DPAE with work contract values ? I am experiencing a KO on FR_Contract area:

Partiel body

<FR_Contract>
      <FR_Contract.StartContract.Date>2021-10-04</FR_Contract.StartContract.Date>
      <FR_Contract.StartContract.Time>09:30</FR_Contract.StartContract.Time>
      <FR_Contract.Nature.Code>CDI</FR_Contract.Nature.Code>
      <FR_Contract.HealthService.Text>175</FR_Contract.HealthService.Text>
      <FR_Contract.Creation.Date>2021-09-28</FR_Contract.Creation.Date>
      <FR_Contract.Creationtime.Text>13:48</FR_Contract.Creationtime.Text>
      <FR_Contract.Error1.Text>00</FR_Contract.Error1.Text>
      <FR_Contract.Error2.Text>99</FR_Contract.Error2.Text>
      <FR_Contract.Reference.Text>3L94V</FR_Contract.Reference.Text>
  </FR_Contract>

Response:

    <flux>
        <id>...</id>
        <retour>
            <publication>20210928134715</publication>
            <production>20210928134715</production>
            <nature>10</nature>
            <statut>OK</statut>
            <id>...</id>
            <url>...</url>
        </retour>
        <retour>
            <publication>20210928134716</publication>
            <production>20210928134716</production>
            <nature>11</nature>
            <statut>OK</statut>
            <id>...</id>
            <url>...</url>
        </retour>
        <retour>
            <publication>20210928135550</publication>
            <production>20210928015539</production>
            <nature>41</nature>
            <statut>KO</statut>
            <id>...</id>
            <url>...</url>
        </retour>
    </flux>
</retours>```
commented

Yes. Maybe try with time with seconds

 <FR_Contract>
                <FR_Contract.StartContract.Date>  2021-10-03  </FR_Contract.StartContract.Date>
                <FR_Contract.StartContract.Time>  12:44:54  </FR_Contract.StartContract.Time>
                <FR_Contract.EndContract.Date>  2021-10-03   </FR_Contract.EndContract.Date>
                <FR_Contract.Nature.Code>  CDD </FR_Contract.Nature.Code>
                <FR_Contract.HealthService.Text> 01 </FR_Contract.HealthService.Text>
</FR_Contract>

Thanks !

I did try again with seconds, here's is what I sent:

			<FR_Contract>
				<FR_Contract.StartContract.Date>2021-10-04</FR_Contract.StartContract.Date>
				<FR_Contract.EndContract.Date>2021-12-04</FR_Contract.EndContract.Date>
				<FR_Contract.StartContract.Time>09:30:00</FR_Contract.StartContract.Time>
				<FR_Contract.Nature.Code>CDD</FR_Contract.Nature.Code>
				<FR_Contract.HealthService.Text>175</FR_Contract.HealthService.Text>
			</FR_Contract>

and I received:

            <FR_Contract>
                <FR_Contract.StartContract.Date>2021-10-04</FR_Contract.StartContract.Date>
                <FR_Contract.StartContract.Time>09:30</FR_Contract.StartContract.Time>
                <FR_Contract.EndContract.Date>2021-12-04</FR_Contract.EndContract.Date>
                <FR_Contract.Nature.Code>CDD</FR_Contract.Nature.Code>
                <FR_Contract.HealthService.Text>175</FR_Contract.HealthService.Text>
                <FR_Contract.Creation.Date>2021-09-29</FR_Contract.Creation.Date>
                <FR_Contract.Creationtime.Text>12:06</FR_Contract.Creationtime.Text>
                <FR_Contract.Error1.Text>00</FR_Contract.Error1.Text>
                <FR_Contract.Error2.Text>99</FR_Contract.Error2.Text>
                <FR_Contract.Reference.Text>36MRD</FR_Contract.Reference.Text>
            </FR_Contract>

and, later, I asked for the "retours":

<retours>
    <flux>
        <id>...</id>
        <retour>
            <publication>20210929120000</publication>
            <production>20210929120000</production>
            <nature>10</nature>
            <statut>OK</statut>
            <id>...</id>
            <url>...</url>
        </retour>
        <retour>
            <publication>20210929120000</publication>
            <production>20210929120000</production>
            <nature>11</nature>
            <statut>OK</statut>
            <id>...</id>
            <url>...</url>
        </retour>
        <retour>
            <publication>20210929120000</publication>
            <production>20210929120000</production>
            <nature>41</nature>
            <statut>KO</statut>
            <id>...</id>
            <url>...</url>
        </retour>
    </flux>
</retours>

In last XML fragment, the nature 41 is KO. If I download the content of the url attached, the data seems OK though:

<FR_DuesGroup>
        <FR_Employer>
            <FR_EmployerIdentity>
                <rxorg:FR_Organization.SIRET.Identifier>00000000000000</rxorg:FR_Organization.SIRET.Identifier>
                <rxorg:FR_Organization.Designation.Text>SOCIETY</rxorg:FR_Organization.Designation.Text>
                <rxorg:FR_Organization.APE.Code>0000A</rxorg:FR_Organization.APE.Code>
            </FR_EmployerIdentity>
            <FR_Employer.URSSAF.Code>117</FR_Employer.URSSAF.Code>
            <FR_EmployerAddress>
                <rxpadr:FR_PostalAddress.StreetDesignation.Text>10, street x</rxpadr:FR_PostalAddress.StreetDesignation.Text>
                <rxpadr:FR_PostalAddress.Town.Text>YYY</rxpadr:FR_PostalAddress.Town.Text>
                <rxpadr:FR_PostalAddress.Postal.Code>00000</rxpadr:FR_PostalAddress.Postal.Code>
            </FR_EmployerAddress>
        </FR_Employer>
        <FR_EmployeeGroup>
            <FR_Employee>
                <FR_EmployeeIdentity>
                    <rxpers:FR_PersonIdentity.Surname.Text>XXXXXX</rxpers:FR_PersonIdentity.Surname.Text>
                    <rxpers:FR_PersonIdentity.ChristianName.Text>YYYYY</rxpers:FR_PersonIdentity.ChristianName.Text>
                    <rxpers:FR_PersonIdentity.Sex.Code>2</rxpers:FR_PersonIdentity.Sex.Code>
                    <rxpers:FR_NNI>
                        <rxpers:FR_NNI.NIR.Identifier>0000000000000</rxpers:FR_NNI.NIR.Identifier>
                    </rxpers:FR_NNI>
                    <rxpers:FR_Birth>
                        <rxpers:FR_Birth.Date>1990-01-01</rxpers:FR_Birth.Date>
                        <rxpers:FR_Birth.Town.Text>AAAAAA</rxpers:FR_Birth.Town.Text>
                    </rxpers:FR_Birth>
                </FR_EmployeeIdentity>
                <FR_EmployeeComplement>
                    <FR_EmployeeComplement.Birth_Department.Code>99</FR_EmployeeComplement.Birth_Department.Code>
                </FR_EmployeeComplement>
            </FR_Employee>
            <FR_Contract>
                <FR_Contract.StartContract.Date>2021-10-04</FR_Contract.StartContract.Date>
                <FR_Contract.StartContract.Time>09:30</FR_Contract.StartContract.Time>
                <FR_Contract.EndContract.Date>2021-12-04</FR_Contract.EndContract.Date>
                <FR_Contract.Nature.Code>CDD</FR_Contract.Nature.Code>
                <FR_Contract.HealthService.Text>175</FR_Contract.HealthService.Text>
                <FR_Contract.Creation.Date>2021-09-29</FR_Contract.Creation.Date>
                <FR_Contract.Creationtime.Text>12:06</FR_Contract.Creationtime.Text>
                <FR_Contract.Error1.Text>00</FR_Contract.Error1.Text>
                <FR_Contract.Error2.Text>99</FR_Contract.Error2.Text>
                <FR_Contract.Reference.Text>36MRD</FR_Contract.Reference.Text>
            </FR_Contract>
            <FR_Formalities>
                <FR_Formalities.CERTIF.Indicator>1</FR_Formalities.CERTIF.Indicator>
                <FR_Formalities.IMMA.Indicator>0</FR_Formalities.IMMA.Indicator>
                <FR_Formalities.MT.Indicator>1</FR_Formalities.MT.Indicator>
                <FR_Formalities.PMF5.Indicator>0</FR_Formalities.PMF5.Indicator>
            </FR_Formalities>
        </FR_EmployeeGroup>
    </FR_DuesGroup>

The seconds are erased in the response.
If I check the interface, the DPAE is invalid, and all the "Contract" data are not set. The "Employee" or "Employer" data are OK.

Thanks in advance for your time. I did not find any hint on the web, and I'm still waiting for a response of the URSSAF.

Salut @maxmg, j'ai la même erreur que toi Max, as-tu pu solutionner ton problème ?

commented

Je viens de mettre à jour le dépôt avec un petit bout de code exemple.