How do I know through DSS download file size?


How do I know through DataScope download file size?

I downloaded several files through the REST API and want to know for sure that the file size on the Refinitiv server exactly matches the file size that I downloaded.
How do I do that?


Please provide a step-by-step description of how to recognize file size through DataScope


I am interested in how I can check that the size of the downloaded file on my computer is equal to the size of the file located on the Refinitiv server

I wonder if there's a way to track the size of the files on the Refinitiv server that are being prepared for download on my computer?

Best Answer

  • zoya faberov
    zoya faberov ✭✭✭✭✭
    Answer ✓

    Hello @mohamed.hisham,

    Once your job is completed, you can request the extraction details, including file size, via ExtractionFileId. Please note that this ID is different from accepted JobId:

    {{protocol}}{{host}}{{api}}Extractions/ExtractedFiles('{{extractedDataFileId}}')

    An example of a result obtained:

    {
        "@odata.context": "https://hosted.datascopeapi.reuters.com/RestApi/v1/$metadata#ExtractedFiles/$entity",
        "ExtractedFileId": "VjF8MHgwNzgzODFhOWQ3NTc2ZWFhfA",
        "ReportExtractionId": "2000000246945099",
        "ScheduleId": "0x078385142e576ebe",
        "FileType": "Note",
        "ExtractedFileName": "_OnD_0x078385142e576ebe.csv.gz.notes.txt",
        "LastWriteTimeUtc": "2021-04-12T15:04:25.090Z",
        "ContentsExists": true,
        "Size": 1246,
        "ReceivedDateUtc": "2021-04-12T15:04:25.090Z"
    }

    As this id does not come back in notes or Job status check (this info only becomes available once the extraction is completed), or as an alternative approach, you can request all the extracted files information, and search the result by the jobId.

    {{protocol}}{{host}}{{api}}Extractions/ExtractedFiles

    For example:

    {
        "@odata.context": "https://hosted.datascopeapi.reuters.com/RestApi/v1/$metadata#ExtractedFiles",
        "value": [
            {
                "ExtractedFileId": "VjF8MHgwNzgzODFhOWQ3NTc2ZWFhfA",
                "ReportExtractionId": "2000000246945099",
                "ScheduleId": "0x078385142e576ebe",
                "FileType": "Note",
                "ExtractedFileName": "_OnD_0x078385142e576ebe.csv.gz.notes.txt",
                "LastWriteTimeUtc": "2021-04-12T15:04:25.090Z",
                "ContentsExists": true,
                "Size": 1246,
                "ReceivedDateUtc": "2021-04-12T15:04:25.090Z"
            },
    ...

    Please review the complete spec via DSS API Reference Tree


Welcome!

It looks like you're new here. Sign in or register to get started.

Welcome!

It looks like you're new here. Sign in or register to get started.