Chilkat Online Tools

SQL Server / EDS API / Dokuments "PVN atmaksas pieteikums".

Back to Collection Items

-- Important: See this note about string length limitations for strings returned by sp_OAMethod calls.
--
CREATE PROCEDURE ChilkatSample
AS
BEGIN
    DECLARE @hr int
    -- Important: Do not use nvarchar(max).  See the warning about using nvarchar(max).
    DECLARE @sTmp0 nvarchar(4000)
    -- This example assumes the Chilkat API to have been previously unlocked.
    -- See Global Unlock Sample for sample code.

    DECLARE @http int
    -- Use "Chilkat_9_5_0.Http" for versions of Chilkat < 10.0.0
    EXEC @hr = sp_OACreate 'Chilkat.Http', @http OUT
    IF @hr <> 0
    BEGIN
        PRINT 'Failed to create ActiveX component'
        RETURN
    END

    DECLARE @success int

    EXEC sp_OAMethod @http, 'SetRequestHeader', NULL, 'Accept', 'application/json'

    DECLARE @sbResponseBody int
    -- Use "Chilkat_9_5_0.StringBuilder" for versions of Chilkat < 10.0.0
    EXEC @hr = sp_OACreate 'Chilkat.StringBuilder', @sbResponseBody OUT

    EXEC sp_OAMethod @http, 'QuickGetSb', @success OUT, 'https://eds.vid.gov.lv/api/doc/pvnav2/:id', @sbResponseBody
    IF @success = 0
      BEGIN
        EXEC sp_OAGetProperty @http, 'LastErrorText', @sTmp0 OUT
        PRINT @sTmp0
        EXEC @hr = sp_OADestroy @http
        EXEC @hr = sp_OADestroy @sbResponseBody
        RETURN
      END

    DECLARE @jResp int
    -- Use "Chilkat_9_5_0.JsonObject" for versions of Chilkat < 10.0.0
    EXEC @hr = sp_OACreate 'Chilkat.JsonObject', @jResp OUT

    EXEC sp_OAMethod @jResp, 'LoadSb', @success OUT, @sbResponseBody
    EXEC sp_OASetProperty @jResp, 'EmitCompact', 0


    PRINT 'Response Body:'
    EXEC sp_OAMethod @jResp, 'Emit', @sTmp0 OUT
    PRINT @sTmp0

    DECLARE @respStatusCode int
    EXEC sp_OAGetProperty @http, 'LastStatus', @respStatusCode OUT

    PRINT 'Response Status Code = ' + @respStatusCode
    IF @respStatusCode >= 400
      BEGIN

        PRINT 'Response Header:'
        EXEC sp_OAGetProperty @http, 'LastHeader', @sTmp0 OUT
        PRINT @sTmp0

        PRINT 'Failed.'
        EXEC @hr = sp_OADestroy @http
        EXEC @hr = sp_OADestroy @sbResponseBody
        EXEC @hr = sp_OADestroy @jResp
        RETURN
      END

    -- Sample JSON response:
    -- (Sample code for parsing the JSON response is shown below)

    -- {
    --   "NmrKods": "anim velit tempor ullamco",
    --   "Talrunis": "4",
    --   "Sagatavotajs": "aliqua magna",
    --   "ApplicationReference": {
    --     "RefundingCountryCode": "anim ad magna",
    --     "ReferenceNumber": "proident",
    --     "Version": "irure commodo"
    --   },
    --   "Applicant": {
    --     "Name": {
    --       "NameFree": {
    --         "value": "<Error: Too many levels of nesting to fake this schema>"
    --       }
    --     },
    --     "AddressFree": "sunt",
    --     "TelephoneNumber": "minim magna dolore",
    --     "CountryCode": "ad aute laborum",
    --     "EUTraderID": {
    --       "CodeTypeValue": {
    --         "value": "<Error: Too many levels of nesting to fake this schema>"
    --       },
    --       "Code": {
    --         "value": "<Error: Too many levels of nesting to fake this schema>"
    --       },
    --       "IssuedBy": {
    --         "value": "<Error: Too many levels of nesting to fake this schema>"
    --       }
    --     },
    --     "EmailAddress": "quis"
    --   },
    --   "Representative": {
    --     "AddressFree": "deserunt",
    --     "CountryCode": "in anim",
    --     "EmailAddress": "",
    --     "Name": {
    --       "NameFree": {
    --         "value": "<Error: Too many levels of nesting to fake this schema>"
    --       }
    --     },
    --     "TelephoneNumber": "\r6",
    --     "RepresentativeID": {
    --       "CodeTypeValue": {
    --         "value": "<Error: Too many levels of nesting to fake this schema>"
    --       },
    --       "Code": {
    --         "value": "<Error: Too many levels of nesting to fake this schema>"
    --       },
    --       "IssuedBy": {
    --         "value": "<Error: Too many levels of nesting to fake this schema>"
    --       }
    --     }
    --   },
    --   "RefundPeriod": {
    --     "StartDate": "2000-01-31T00:00:00",
    --     "EndDate": "2000-01-31T00:00:00"
    --   },
    --   "BusinessDescription": {
    --     "BusinessActivity": "cupidatat deserunt veniam"
    --   },
    --   "DetailedBankAccount": {
    --     "OwnerName": "-r4AJzac",
    --     "OwnerType": "magna consectetur sint",
    --     "IBAN": "FR76IV05EPC,RNHM8MENESST",
    --     "BIC": "CNWONQML",
    --     "Currency": "Duis veniam"
    --   },
    --   "ImportInformation": [
    --     {
    --       "IssuingDate": "2000-01-31T00:00:00",
    --       "SupplierName": "sunt dolor dolor",
    --       "SupplierAddressFree": "dolore",
    --       "SupplierCountryCode": "est dolore dolor",
    --       "Currency": "ea elit nulla velit",
    --       "TaxableAmount": -88820603.7288061,
    --       "VatAmount": 71318677.0492571,
    --       "ReferenceNumber": "eu aliqua nulla",
    --       "ReferenceInformation": "exercitation laborum",
    --       "SupplierTelephoneNumber": "3 ",
    --       "GoodsDescriptionFreeText": "ani",
    --       "GoodsDescriptionFreeTextLang": "ut nostrud ex officia",
    --       "GoodsDescriptionCodes": "in L",
    --       "ProRataRate": 37125738.782556444
    --     },
    --     {
    --       "IssuingDate": "2000-01-31T00:00:00",
    --       "SupplierName": "in non culpa",
    --       "SupplierAddressFree": "sit off",
    --       "SupplierCountryCode": "qui dolore",
    --       "Currency": "in eiusmod in anim",
    --       "TaxableAmount": 50542638.62150416,
    --       "VatAmount": -84461612.01044232,
    --       "ReferenceNumber": "irure ",
    --       "ReferenceInformation": "reprehenderit et voluptate",
    --       "SupplierTelephoneNumber": "\t   ",
    --       "GoodsDescriptionFreeText": "laboris dolor",
    --       "GoodsDescriptionFreeTextLang": "ipsum commodo",
    --       "GoodsDescriptionCodes": "culpa mollit dolor",
    --       "ProRataRate": -64717664.86095043
    --     }
    --   ],
    --   "PurchaseInformation": [
    --     {
    --       "IssuingDate": "2000-01-31T00:00:00",
    --       "SupplierName": "ut cillum velit dolore fugiat",
    --       "SupplierAddressFree": "aliquip",
    --       "SupplierCountryCode": "sed aliquip adipisicing",
    --       "Currency": "anim labore consequat",
    --       "TaxableAmount": 12481268.563475162,
    --       "VatAmount": 31338286.233541623,
    --       "ReferenceNumber": "tempor exercita",
    --       "EuTraderIdIssuedBy": "ut ea ullamco laboris",
    --       "SimplifiedInvoice": true,
    --       "SupplierTelephoneNumber": "  \u000b 9 4  7",
    --       "EuTraderId": "mini",
    --       "EuTraderIdType": "deserunt sunt aliqua",
    --       "GoodsDescriptionFreeText": "commodo Lorem",
    --       "GoodsDescriptionFreeTextLang": "exercitation sunt voluptate",
    --       "GoodsDescriptionCodes": "Excepteur consequat et ut",
    --       "ProRataRate": -73370109.27853811
    --     },
    --     {
    --       "IssuingDate": "2000-01-31T00:00:00",
    --       "SupplierName": "sed in ut",
    --       "SupplierAddressFree": "quis voluptate",
    --       "SupplierCountryCode": "labore cillum occaecat",
    --       "Currency": "et elit magna",
    --       "TaxableAmount": 40216004.607723564,
    --       "VatAmount": 29872509.991602138,
    --       "ReferenceNumber": "et Lo",
    --       "EuTraderIdIssuedBy": "labore incididunt",
    --       "SimplifiedInvoice": false,
    --       "SupplierTelephoneNumber": "8 ",
    --       "EuTraderId": "dolor ipsum in dolor",
    --       "EuTraderIdType": "consectetur Ut Lorem",
    --       "GoodsDescriptionFreeText": "Ut sed veniam nost",
    --       "GoodsDescriptionFreeTextLang": "fug",
    --       "GoodsDescriptionCodes": "ex",
    --       "ProRataRate": -4523238.601603329
    --     }
    --   ],
    --   "DocumentCopy": [
    --     {
    --       "FileType": "dolor sit eiusmod",
    --       "FileName": "sunt adipisicing",
    --       "FileDescription": "aute qui",
    --       "FileContent": "dolor officia"
    --     },
    --     {
    --       "FileType": "magna eu deserunt qui",
    --       "FileName": "pariatur",
    --       "FileDescription": "nisi",
    --       "FileContent": "in eiusmod dolor enim"
    --     }
    --   ],
    --   "Accepted": true,
    --   "Id": -56268983,
    --   "UID": "nulla ut",
    --   "Precizejums": true,
    --   "PrecizejamaisDokuments": 5162629,
    --   "PrecizejumaPamatojums": "cupidatat dolor velit nulla"
    -- }

    -- Sample code for parsing the JSON response...
    -- Use this online tool to generate parsing code from sample JSON: Generate JSON Parsing Code

    DECLARE @IssuingDate nvarchar(4000)

    DECLARE @SupplierName nvarchar(4000)

    DECLARE @SupplierAddressFree nvarchar(4000)

    DECLARE @SupplierCountryCode nvarchar(4000)

    DECLARE @TaxableAmount nvarchar(4000)

    DECLARE @VatAmount nvarchar(4000)

    DECLARE @ReferenceInformation nvarchar(4000)

    DECLARE @SupplierTelephoneNumber nvarchar(4000)

    DECLARE @GoodsDescriptionFreeText nvarchar(4000)

    DECLARE @GoodsDescriptionFreeTextLang nvarchar(4000)

    DECLARE @GoodsDescriptionCodes nvarchar(4000)

    DECLARE @ProRataRate nvarchar(4000)

    DECLARE @EuTraderIdIssuedBy nvarchar(4000)

    DECLARE @SimplifiedInvoice int

    DECLARE @EuTraderId nvarchar(4000)

    DECLARE @EuTraderIdType nvarchar(4000)

    DECLARE @FileType nvarchar(4000)

    DECLARE @FileName nvarchar(4000)

    DECLARE @FileDescription nvarchar(4000)

    DECLARE @FileContent nvarchar(4000)

    DECLARE @NmrKods nvarchar(4000)
    EXEC sp_OAMethod @jResp, 'StringOf', @NmrKods OUT, 'NmrKods'
    DECLARE @Talrunis nvarchar(4000)
    EXEC sp_OAMethod @jResp, 'StringOf', @Talrunis OUT, 'Talrunis'
    DECLARE @Sagatavotajs nvarchar(4000)
    EXEC sp_OAMethod @jResp, 'StringOf', @Sagatavotajs OUT, 'Sagatavotajs'
    DECLARE @RefundingCountryCode nvarchar(4000)
    EXEC sp_OAMethod @jResp, 'StringOf', @RefundingCountryCode OUT, 'ApplicationReference.RefundingCountryCode'
    DECLARE @ReferenceNumber nvarchar(4000)
    EXEC sp_OAMethod @jResp, 'StringOf', @ReferenceNumber OUT, 'ApplicationReference.ReferenceNumber'
    DECLARE @Version nvarchar(4000)
    EXEC sp_OAMethod @jResp, 'StringOf', @Version OUT, 'ApplicationReference.Version'
    DECLARE @Value nvarchar(4000)
    EXEC sp_OAMethod @jResp, 'StringOf', @Value OUT, 'Applicant.Name.NameFree.value'
    DECLARE @AddressFree nvarchar(4000)
    EXEC sp_OAMethod @jResp, 'StringOf', @AddressFree OUT, 'Applicant.AddressFree'
    DECLARE @TelephoneNumber nvarchar(4000)
    EXEC sp_OAMethod @jResp, 'StringOf', @TelephoneNumber OUT, 'Applicant.TelephoneNumber'
    DECLARE @CountryCode nvarchar(4000)
    EXEC sp_OAMethod @jResp, 'StringOf', @CountryCode OUT, 'Applicant.CountryCode'
    DECLARE @CodeTypeValueValue nvarchar(4000)
    EXEC sp_OAMethod @jResp, 'StringOf', @CodeTypeValueValue OUT, 'Applicant.EUTraderID.CodeTypeValue.value'
    DECLARE @CodeValue nvarchar(4000)
    EXEC sp_OAMethod @jResp, 'StringOf', @CodeValue OUT, 'Applicant.EUTraderID.Code.value'
    DECLARE @IssuedByValue nvarchar(4000)
    EXEC sp_OAMethod @jResp, 'StringOf', @IssuedByValue OUT, 'Applicant.EUTraderID.IssuedBy.value'
    DECLARE @EmailAddress nvarchar(4000)
    EXEC sp_OAMethod @jResp, 'StringOf', @EmailAddress OUT, 'Applicant.EmailAddress'
    DECLARE @RepresentativeAddressFree nvarchar(4000)
    EXEC sp_OAMethod @jResp, 'StringOf', @RepresentativeAddressFree OUT, 'Representative.AddressFree'
    DECLARE @RepresentativeCountryCode nvarchar(4000)
    EXEC sp_OAMethod @jResp, 'StringOf', @RepresentativeCountryCode OUT, 'Representative.CountryCode'
    DECLARE @RepresentativeEmailAddress nvarchar(4000)
    EXEC sp_OAMethod @jResp, 'StringOf', @RepresentativeEmailAddress OUT, 'Representative.EmailAddress'
    DECLARE @NameFreeValue nvarchar(4000)
    EXEC sp_OAMethod @jResp, 'StringOf', @NameFreeValue OUT, 'Representative.Name.NameFree.value'
    DECLARE @RepresentativeTelephoneNumber nvarchar(4000)
    EXEC sp_OAMethod @jResp, 'StringOf', @RepresentativeTelephoneNumber OUT, 'Representative.TelephoneNumber'
    EXEC sp_OAMethod @jResp, 'StringOf', @CodeTypeValueValue OUT, 'Representative.RepresentativeID.CodeTypeValue.value'
    EXEC sp_OAMethod @jResp, 'StringOf', @CodeValue OUT, 'Representative.RepresentativeID.Code.value'
    EXEC sp_OAMethod @jResp, 'StringOf', @IssuedByValue OUT, 'Representative.RepresentativeID.IssuedBy.value'
    DECLARE @StartDate nvarchar(4000)
    EXEC sp_OAMethod @jResp, 'StringOf', @StartDate OUT, 'RefundPeriod.StartDate'
    DECLARE @EndDate nvarchar(4000)
    EXEC sp_OAMethod @jResp, 'StringOf', @EndDate OUT, 'RefundPeriod.EndDate'
    DECLARE @BusinessActivity nvarchar(4000)
    EXEC sp_OAMethod @jResp, 'StringOf', @BusinessActivity OUT, 'BusinessDescription.BusinessActivity'
    DECLARE @OwnerName nvarchar(4000)
    EXEC sp_OAMethod @jResp, 'StringOf', @OwnerName OUT, 'DetailedBankAccount.OwnerName'
    DECLARE @OwnerType nvarchar(4000)
    EXEC sp_OAMethod @jResp, 'StringOf', @OwnerType OUT, 'DetailedBankAccount.OwnerType'
    DECLARE @IBAN nvarchar(4000)
    EXEC sp_OAMethod @jResp, 'StringOf', @IBAN OUT, 'DetailedBankAccount.IBAN'
    DECLARE @BIC nvarchar(4000)
    EXEC sp_OAMethod @jResp, 'StringOf', @BIC OUT, 'DetailedBankAccount.BIC'
    DECLARE @v_Currency nvarchar(4000)
    EXEC sp_OAMethod @jResp, 'StringOf', @v_Currency OUT, 'DetailedBankAccount.Currency'
    DECLARE @Accepted int
    EXEC sp_OAMethod @jResp, 'BoolOf', @Accepted OUT, 'Accepted'
    DECLARE @Id int
    EXEC sp_OAMethod @jResp, 'IntOf', @Id OUT, 'Id'
    DECLARE @UID nvarchar(4000)
    EXEC sp_OAMethod @jResp, 'StringOf', @UID OUT, 'UID'
    DECLARE @Precizejums int
    EXEC sp_OAMethod @jResp, 'BoolOf', @Precizejums OUT, 'Precizejums'
    DECLARE @PrecizejamaisDokuments int
    EXEC sp_OAMethod @jResp, 'IntOf', @PrecizejamaisDokuments OUT, 'PrecizejamaisDokuments'
    DECLARE @PrecizejumaPamatojums nvarchar(4000)
    EXEC sp_OAMethod @jResp, 'StringOf', @PrecizejumaPamatojums OUT, 'PrecizejumaPamatojums'
    DECLARE @i int
    SELECT @i = 0
    DECLARE @count_i int
    EXEC sp_OAMethod @jResp, 'SizeOfArray', @count_i OUT, 'ImportInformation'
    WHILE @i < @count_i
      BEGIN
        EXEC sp_OASetProperty @jResp, 'I', @i
        EXEC sp_OAMethod @jResp, 'StringOf', @IssuingDate OUT, 'ImportInformation[i].IssuingDate'
        EXEC sp_OAMethod @jResp, 'StringOf', @SupplierName OUT, 'ImportInformation[i].SupplierName'
        EXEC sp_OAMethod @jResp, 'StringOf', @SupplierAddressFree OUT, 'ImportInformation[i].SupplierAddressFree'
        EXEC sp_OAMethod @jResp, 'StringOf', @SupplierCountryCode OUT, 'ImportInformation[i].SupplierCountryCode'
        EXEC sp_OAMethod @jResp, 'StringOf', @v_Currency OUT, 'ImportInformation[i].Currency'
        EXEC sp_OAMethod @jResp, 'StringOf', @TaxableAmount OUT, 'ImportInformation[i].TaxableAmount'
        EXEC sp_OAMethod @jResp, 'StringOf', @VatAmount OUT, 'ImportInformation[i].VatAmount'
        EXEC sp_OAMethod @jResp, 'StringOf', @ReferenceNumber OUT, 'ImportInformation[i].ReferenceNumber'
        EXEC sp_OAMethod @jResp, 'StringOf', @ReferenceInformation OUT, 'ImportInformation[i].ReferenceInformation'
        EXEC sp_OAMethod @jResp, 'StringOf', @SupplierTelephoneNumber OUT, 'ImportInformation[i].SupplierTelephoneNumber'
        EXEC sp_OAMethod @jResp, 'StringOf', @GoodsDescriptionFreeText OUT, 'ImportInformation[i].GoodsDescriptionFreeText'
        EXEC sp_OAMethod @jResp, 'StringOf', @GoodsDescriptionFreeTextLang OUT, 'ImportInformation[i].GoodsDescriptionFreeTextLang'
        EXEC sp_OAMethod @jResp, 'StringOf', @GoodsDescriptionCodes OUT, 'ImportInformation[i].GoodsDescriptionCodes'
        EXEC sp_OAMethod @jResp, 'StringOf', @ProRataRate OUT, 'ImportInformation[i].ProRataRate'
        SELECT @i = @i + 1
      END
    SELECT @i = 0
    EXEC sp_OAMethod @jResp, 'SizeOfArray', @count_i OUT, 'PurchaseInformation'
    WHILE @i < @count_i
      BEGIN
        EXEC sp_OASetProperty @jResp, 'I', @i
        EXEC sp_OAMethod @jResp, 'StringOf', @IssuingDate OUT, 'PurchaseInformation[i].IssuingDate'
        EXEC sp_OAMethod @jResp, 'StringOf', @SupplierName OUT, 'PurchaseInformation[i].SupplierName'
        EXEC sp_OAMethod @jResp, 'StringOf', @SupplierAddressFree OUT, 'PurchaseInformation[i].SupplierAddressFree'
        EXEC sp_OAMethod @jResp, 'StringOf', @SupplierCountryCode OUT, 'PurchaseInformation[i].SupplierCountryCode'
        EXEC sp_OAMethod @jResp, 'StringOf', @v_Currency OUT, 'PurchaseInformation[i].Currency'
        EXEC sp_OAMethod @jResp, 'StringOf', @TaxableAmount OUT, 'PurchaseInformation[i].TaxableAmount'
        EXEC sp_OAMethod @jResp, 'StringOf', @VatAmount OUT, 'PurchaseInformation[i].VatAmount'
        EXEC sp_OAMethod @jResp, 'StringOf', @ReferenceNumber OUT, 'PurchaseInformation[i].ReferenceNumber'
        EXEC sp_OAMethod @jResp, 'StringOf', @EuTraderIdIssuedBy OUT, 'PurchaseInformation[i].EuTraderIdIssuedBy'
        EXEC sp_OAMethod @jResp, 'BoolOf', @SimplifiedInvoice OUT, 'PurchaseInformation[i].SimplifiedInvoice'
        EXEC sp_OAMethod @jResp, 'StringOf', @SupplierTelephoneNumber OUT, 'PurchaseInformation[i].SupplierTelephoneNumber'
        EXEC sp_OAMethod @jResp, 'StringOf', @EuTraderId OUT, 'PurchaseInformation[i].EuTraderId'
        EXEC sp_OAMethod @jResp, 'StringOf', @EuTraderIdType OUT, 'PurchaseInformation[i].EuTraderIdType'
        EXEC sp_OAMethod @jResp, 'StringOf', @GoodsDescriptionFreeText OUT, 'PurchaseInformation[i].GoodsDescriptionFreeText'
        EXEC sp_OAMethod @jResp, 'StringOf', @GoodsDescriptionFreeTextLang OUT, 'PurchaseInformation[i].GoodsDescriptionFreeTextLang'
        EXEC sp_OAMethod @jResp, 'StringOf', @GoodsDescriptionCodes OUT, 'PurchaseInformation[i].GoodsDescriptionCodes'
        EXEC sp_OAMethod @jResp, 'StringOf', @ProRataRate OUT, 'PurchaseInformation[i].ProRataRate'
        SELECT @i = @i + 1
      END
    SELECT @i = 0
    EXEC sp_OAMethod @jResp, 'SizeOfArray', @count_i OUT, 'DocumentCopy'
    WHILE @i < @count_i
      BEGIN
        EXEC sp_OASetProperty @jResp, 'I', @i
        EXEC sp_OAMethod @jResp, 'StringOf', @FileType OUT, 'DocumentCopy[i].FileType'
        EXEC sp_OAMethod @jResp, 'StringOf', @FileName OUT, 'DocumentCopy[i].FileName'
        EXEC sp_OAMethod @jResp, 'StringOf', @FileDescription OUT, 'DocumentCopy[i].FileDescription'
        EXEC sp_OAMethod @jResp, 'StringOf', @FileContent OUT, 'DocumentCopy[i].FileContent'
        SELECT @i = @i + 1
      END

    EXEC @hr = sp_OADestroy @http
    EXEC @hr = sp_OADestroy @sbResponseBody
    EXEC @hr = sp_OADestroy @jResp


END
GO

Curl Command

curl -X GET
	-H "Accept: application/json"
https://eds.vid.gov.lv/api/doc/pvnav2/:id

Postman Collection Item JSON

{
  "name": "Dokuments \"PVN atmaksas pieteikums\".",
  "request": {
    "method": "GET",
    "header": [
      {
        "key": "Accept",
        "value": "application/json"
      }
    ],
    "url": {
      "raw": "{{baseUrl}}/api/doc/pvnav2/:id",
      "host": [
        "{{baseUrl}}"
      ],
      "path": [
        "api",
        "doc",
        "pvnav2",
        ":id"
      ],
      "variable": [
        {
          "key": "id",
          "value": "25210683",
          "description": "(Required) Dokumenta id."
        }
      ]
    }
  },
  "response": [
    {
      "name": "OK",
      "originalRequest": {
        "method": "GET",
        "header": [
        ],
        "url": {
          "raw": "{{baseUrl}}/api/doc/pvnav2/:id",
          "host": [
            "{{baseUrl}}"
          ],
          "path": [
            "api",
            "doc",
            "pvnav2",
            ":id"
          ],
          "variable": [
            {
              "key": "id",
              "value": "25210683",
              "description": "(Required) Dokumenta id."
            }
          ]
        }
      },
      "status": "OK",
      "code": 200,
      "_postman_previewlanguage": "json",
      "header": [
        {
          "key": "Content-Type",
          "value": "application/json"
        }
      ],
      "cookie": [
      ],
      "body": "{\n  \"NmrKods\": \"anim velit tempor ullamco\",\n  \"Talrunis\": \"4\",\n  \"Sagatavotajs\": \"aliqua magna\",\n  \"ApplicationReference\": {\n    \"RefundingCountryCode\": \"anim ad magna\",\n    \"ReferenceNumber\": \"proident\",\n    \"Version\": \"irure commodo\"\n  },\n  \"Applicant\": {\n    \"Name\": {\n      \"NameFree\": {\n        \"value\": \"<Error: Too many levels of nesting to fake this schema>\"\n      }\n    },\n    \"AddressFree\": \"sunt\",\n    \"TelephoneNumber\": \"minim magna dolore\",\n    \"CountryCode\": \"ad aute laborum\",\n    \"EUTraderID\": {\n      \"CodeTypeValue\": {\n        \"value\": \"<Error: Too many levels of nesting to fake this schema>\"\n      },\n      \"Code\": {\n        \"value\": \"<Error: Too many levels of nesting to fake this schema>\"\n      },\n      \"IssuedBy\": {\n        \"value\": \"<Error: Too many levels of nesting to fake this schema>\"\n      }\n    },\n    \"EmailAddress\": \"quis\"\n  },\n  \"Representative\": {\n    \"AddressFree\": \"deserunt\",\n    \"CountryCode\": \"in anim\",\n    \"EmailAddress\": \"\",\n    \"Name\": {\n      \"NameFree\": {\n        \"value\": \"<Error: Too many levels of nesting to fake this schema>\"\n      }\n    },\n    \"TelephoneNumber\": \"\\r6\",\n    \"RepresentativeID\": {\n      \"CodeTypeValue\": {\n        \"value\": \"<Error: Too many levels of nesting to fake this schema>\"\n      },\n      \"Code\": {\n        \"value\": \"<Error: Too many levels of nesting to fake this schema>\"\n      },\n      \"IssuedBy\": {\n        \"value\": \"<Error: Too many levels of nesting to fake this schema>\"\n      }\n    }\n  },\n  \"RefundPeriod\": {\n    \"StartDate\": \"2000-01-31T00:00:00\",\n    \"EndDate\": \"2000-01-31T00:00:00\"\n  },\n  \"BusinessDescription\": {\n    \"BusinessActivity\": \"cupidatat deserunt veniam\"\n  },\n  \"DetailedBankAccount\": {\n    \"OwnerName\": \"-r4AJzac\",\n    \"OwnerType\": \"magna consectetur sint\",\n    \"IBAN\": \"FR76IV05EPC,RNHM8MENESST\",\n    \"BIC\": \"CNWONQML\",\n    \"Currency\": \"Duis veniam\"\n  },\n  \"ImportInformation\": [\n    {\n      \"IssuingDate\": \"2000-01-31T00:00:00\",\n      \"SupplierName\": \"sunt dolor dolor\",\n      \"SupplierAddressFree\": \"dolore\",\n      \"SupplierCountryCode\": \"est dolore dolor\",\n      \"Currency\": \"ea elit nulla velit\",\n      \"TaxableAmount\": -88820603.7288061,\n      \"VatAmount\": 71318677.0492571,\n      \"ReferenceNumber\": \"eu aliqua nulla\",\n      \"ReferenceInformation\": \"exercitation laborum\",\n      \"SupplierTelephoneNumber\": \"3 \",\n      \"GoodsDescriptionFreeText\": \"ani\",\n      \"GoodsDescriptionFreeTextLang\": \"ut nostrud ex officia\",\n      \"GoodsDescriptionCodes\": \"in L\",\n      \"ProRataRate\": 37125738.782556444\n    },\n    {\n      \"IssuingDate\": \"2000-01-31T00:00:00\",\n      \"SupplierName\": \"in non culpa\",\n      \"SupplierAddressFree\": \"sit off\",\n      \"SupplierCountryCode\": \"qui dolore\",\n      \"Currency\": \"in eiusmod in anim\",\n      \"TaxableAmount\": 50542638.62150416,\n      \"VatAmount\": -84461612.01044232,\n      \"ReferenceNumber\": \"irure \",\n      \"ReferenceInformation\": \"reprehenderit et voluptate\",\n      \"SupplierTelephoneNumber\": \"\\t   \",\n      \"GoodsDescriptionFreeText\": \"laboris dolor\",\n      \"GoodsDescriptionFreeTextLang\": \"ipsum commodo\",\n      \"GoodsDescriptionCodes\": \"culpa mollit dolor\",\n      \"ProRataRate\": -64717664.86095043\n    }\n  ],\n  \"PurchaseInformation\": [\n    {\n      \"IssuingDate\": \"2000-01-31T00:00:00\",\n      \"SupplierName\": \"ut cillum velit dolore fugiat\",\n      \"SupplierAddressFree\": \"aliquip\",\n      \"SupplierCountryCode\": \"sed aliquip adipisicing\",\n      \"Currency\": \"anim labore consequat\",\n      \"TaxableAmount\": 12481268.563475162,\n      \"VatAmount\": 31338286.233541623,\n      \"ReferenceNumber\": \"tempor exercita\",\n      \"EuTraderIdIssuedBy\": \"ut ea ullamco laboris\",\n      \"SimplifiedInvoice\": true,\n      \"SupplierTelephoneNumber\": \"  \\u000b 9 4  7\",\n      \"EuTraderId\": \"mini\",\n      \"EuTraderIdType\": \"deserunt sunt aliqua\",\n      \"GoodsDescriptionFreeText\": \"commodo Lorem\",\n      \"GoodsDescriptionFreeTextLang\": \"exercitation sunt voluptate\",\n      \"GoodsDescriptionCodes\": \"Excepteur consequat et ut\",\n      \"ProRataRate\": -73370109.27853811\n    },\n    {\n      \"IssuingDate\": \"2000-01-31T00:00:00\",\n      \"SupplierName\": \"sed in ut\",\n      \"SupplierAddressFree\": \"quis voluptate\",\n      \"SupplierCountryCode\": \"labore cillum occaecat\",\n      \"Currency\": \"et elit magna\",\n      \"TaxableAmount\": 40216004.607723564,\n      \"VatAmount\": 29872509.991602138,\n      \"ReferenceNumber\": \"et Lo\",\n      \"EuTraderIdIssuedBy\": \"labore incididunt\",\n      \"SimplifiedInvoice\": false,\n      \"SupplierTelephoneNumber\": \"8 \",\n      \"EuTraderId\": \"dolor ipsum in dolor\",\n      \"EuTraderIdType\": \"consectetur Ut Lorem\",\n      \"GoodsDescriptionFreeText\": \"Ut sed veniam nost\",\n      \"GoodsDescriptionFreeTextLang\": \"fug\",\n      \"GoodsDescriptionCodes\": \"ex\",\n      \"ProRataRate\": -4523238.601603329\n    }\n  ],\n  \"DocumentCopy\": [\n    {\n      \"FileType\": \"dolor sit eiusmod\",\n      \"FileName\": \"sunt adipisicing\",\n      \"FileDescription\": \"aute qui\",\n      \"FileContent\": \"dolor officia\"\n    },\n    {\n      \"FileType\": \"magna eu deserunt qui\",\n      \"FileName\": \"pariatur\",\n      \"FileDescription\": \"nisi\",\n      \"FileContent\": \"in eiusmod dolor enim\"\n    }\n  ],\n  \"Accepted\": true,\n  \"Id\": -56268983,\n  \"UID\": \"nulla ut\",\n  \"Precizejums\": true,\n  \"PrecizejamaisDokuments\": 5162629,\n  \"PrecizejumaPamatojums\": \"cupidatat dolor velit nulla\"\n}"
    },
    {
      "name": "Lietotājs nav autentificēts.",
      "originalRequest": {
        "method": "GET",
        "header": [
        ],
        "url": {
          "raw": "{{baseUrl}}/api/doc/pvnav2/:id",
          "host": [
            "{{baseUrl}}"
          ],
          "path": [
            "api",
            "doc",
            "pvnav2",
            ":id"
          ],
          "variable": [
            {
              "key": "id",
              "value": "25210683",
              "description": "(Required) Dokumenta id."
            }
          ]
        }
      },
      "status": "Unauthorized",
      "code": 401,
      "_postman_previewlanguage": "text",
      "header": [
        {
          "key": "Content-Type",
          "value": "text/plain"
        }
      ],
      "cookie": [
      ],
      "body": ""
    },
    {
      "name": "Dokuments neeksistē vai lietotājam nav tiesību.",
      "originalRequest": {
        "method": "GET",
        "header": [
        ],
        "url": {
          "raw": "{{baseUrl}}/api/doc/pvnav2/:id",
          "host": [
            "{{baseUrl}}"
          ],
          "path": [
            "api",
            "doc",
            "pvnav2",
            ":id"
          ],
          "variable": [
            {
              "key": "id",
              "value": "25210683",
              "description": "(Required) Dokumenta id."
            }
          ]
        }
      },
      "status": "Forbidden",
      "code": 403,
      "_postman_previewlanguage": "text",
      "header": [
        {
          "key": "Content-Type",
          "value": "text/plain"
        }
      ],
      "cookie": [
      ],
      "body": ""
    },
    {
      "name": "Pārsniegts izsaukumu skaita ierobežojums.",
      "originalRequest": {
        "method": "GET",
        "header": [
        ],
        "url": {
          "raw": "{{baseUrl}}/api/doc/pvnav2/:id",
          "host": [
            "{{baseUrl}}"
          ],
          "path": [
            "api",
            "doc",
            "pvnav2",
            ":id"
          ],
          "variable": [
            {
              "key": "id",
              "value": "25210683",
              "description": "(Required) Dokumenta id."
            }
          ]
        }
      },
      "status": "Too Many Requests",
      "code": 429,
      "_postman_previewlanguage": "text",
      "header": [
        {
          "key": "Content-Type",
          "value": "text/plain"
        }
      ],
      "cookie": [
      ],
      "body": ""
    }
  ]
}