Catalog › Interpelări › GetDeclarationsDV
GetDeclarationsDV Interpelări
Interpelarea “GetDeclarationsDV” returnează lista declarațiilor vamale din Sistemul informațional al Serviciului Vamal pentru perioada indicată
SOAP · GetDeclarationsDV(From: Date, To: Date) : Declarations
Date de intrare — Request
| Câmp | Tip | Oblig. | Exemplu | Descriere |
|---|---|---|---|---|
| From | Date | Da | 2018-01-10 | Perioada (de la) |
| To | Date | Da | 2028-05-08 | Perioada (până la) |
Date de intrare — RequestHeaders
| Câmp | Tip | Oblig. | Exemplu | Descriere |
|---|---|---|---|---|
| CallingUser | string(13) | Da | Numărul de identificare (IDNP) al utilizatorului sau identificatorul (ID-ul) sistemului care procesează datele cu caracter personal | |
| CallingEntity | string(13) | Da | Numărul de identificare (IDNO) al persoanei juridice din care face parte utilizatorul care procesează datele cu caracter personal, sau care gestionează sistemul informațional | |
| CallBasis | string(256) | Da | Temeiul legal al apelului | |
| CallReason | string(512) | Da | Scopul legal al apelului |
Date de ieșire — Response
| Câmp | Tip | Oblig. | Exemplu | Descriere |
|---|---|---|---|---|
| Declarations | object | — | Date privind lista declarațiilor vamale | |
| · Declarations | array<object> | Da | Lista declarațiilor vamale/chitanțierelor din SI al Serviciului Vamal pentru perioada indicată | |
| ·· DeclarationId | string | Da | Notă internă | Numărul de sistem al declarației vamale/chitanțierului |
Exemple de apel SOAP
Apel reușit
Cerere validă cu RequestHeaders complete → date sample.
Cerere
curl -X POST https://mconnect.evisoft.com/ConsumerService.svc \
-H 'Content-Type: text/xml; charset=utf-8' \
-H 'SOAPAction: http://mconnect.gov.md/consumer/GetDeclarationsDV' \
--data '<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
<soap:Body>
<GetDeclarationsDV xmlns="http://mconnect.gov.md/consumer">
<Request>
<From>2018-01-10</From>
<To>2028-05-08</To>
</Request>
<RequestHeaders>
<CallingUser>2000000000001</CallingUser>
<CallingEntity>1002600024777</CallingEntity>
<CallBasis>Legea 133/2011 privind protecția datelor</CallBasis>
<CallReason>Prestare serviciu public</CallReason>
</RequestHeaders>
</GetDeclarationsDV>
</soap:Body>
</soap:Envelope>'
Răspuns
<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
<soap:Body>
<GetDeclarationsDVResponse xmlns="http://mconnect.gov.md/consumer">
<Response>
<Declarations>
<Declarations>
<DeclarationId>Valoare exemplu</DeclarationId>
</Declarations>
</Declarations>
</Response>
</GetDeclarationsDVResponse>
</soap:Body>
</soap:Envelope>
Eroare: lipsesc RequestHeaders
Fără CallingUser/CallingEntity → fault (headerele MConnect sunt obligatorii).
Cerere
curl -X POST https://mconnect.evisoft.com/ConsumerService.svc \
-H 'Content-Type: text/xml; charset=utf-8' \
-H 'SOAPAction: http://mconnect.gov.md/consumer/GetDeclarationsDV' \
--data '<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
<soap:Body>
<GetDeclarationsDV xmlns="http://mconnect.gov.md/consumer">
<Request>
<From>2017-10-01</From>
<To>2026-04-23</To>
</Request>
</GetDeclarationsDV>
</soap:Body>
</soap:Envelope>'
Răspuns (fault)
<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
<soap:Body>
<soap:Fault>
<faultcode>soap:Client</faultcode>
<faultstring>Missing RequestHeaders: CallingUser and CallingEntity are required by MConnect.</faultstring>
<detail>
<MConnectFault xmlns="http://mconnect.gov.md/consumer">
<Code>Client</Code>
<Message>Missing RequestHeaders: CallingUser and CallingEntity are required by MConnect.</Message>
</MConnectFault>
</detail>
</soap:Fault>
</soap:Body>
</soap:Envelope>