Skip to main content
Committed ⭐️⭐️⭐️
August 21, 2026
Question

Retrieve files through routines

  • August 21, 2026
  • 4 replies
  • 57 views

Hi,

When working with an API it is possible to retrieve data as e.g. a json-file. Currently, the routines does not support this. Would it be possible for the routine to accept json-format (or other file formats) in the output? The image show that the routine fetches the data, but the string does not support it. 

 

 

    4 replies

    ipolomanyi
    Practitioner ⭐️⭐️⭐️
    Practitioner ⭐️⭐️⭐️
    August 21, 2026

    Hi,

    the supported types are STRING. DOUBLE, STRING_ARRAY and DOUBLE_ARRAY.
    By the look of the JSON supplied you should be able to split the payload into two arrays: STRING_ARRAY for property names and DOUBLE_ARRAY for their values, which would work similar to a map[STRING, DOUBLE].

    What’s kind of connector are you using?

    MartheAuthor
    Committed ⭐️⭐️⭐️
    August 24, 2026

    Hi,

    The connector is for WhitsonPVT.

    The table I’m trying to retrieve is larger than the output showed in the status message (see image below). The component names vary between fluid models, so I would prefer to have a routine that just fetches the whole table, which is available through the API. Is retrieving files a feature that is planned for the simulator routines? 

     

    ipolomanyi
    Practitioner ⭐️⭐️⭐️
    Practitioner ⭐️⭐️⭐️
    August 24, 2026

     The component names vary between fluid models, so I would prefer to have a routine that just fetches the whole table

     

     

    The routines were designed to be model-specific, so the API was not planned to work in a “fetch-everything”  mode. I believe WhitsonPVT should be adjusted, so it allows reading the tabular data as 2d arrays if it’s the use-case, although I don’t think it’s going to be a nice UX / scalable design.

    @navin.r can maybe clarify more about plans.

    Seasoned ⭐️⭐️
    August 24, 2026

    @ipolomanyi ,
    Can we add more supported types to the Routines GET?
    The output file can be anything: xlsx, msf, prp … - as on the picture below.
    I do not expect the Routine to be able to visualize this file, I just expect the Routine to be able to download this file from the server (Whitson server in this case), such that the CDF user can also get it and download it to his machine.
    Possible?