Networking NVIDIA UFM Cable Validation Tool

Files Management APIs

Get Files

  • Description – get the files inside the specified folder if it is accessible via web.

  • Request URL – GET /cablevalidation/files_manager/<folder_name>/files?full_path=<true|false>

  • Paramsfull_path: if set to true the files will return with the absolute pathType - boolOptional - yes

  • Request Content Type – application/json

  • Status Codes200 – OK400 – BAD REQUEST404 – NOT FOUND

  • Response Data Example

    \[
        "/cable_bringup_root/data/uploads/topology/ptp/proton-ptp.xlsx",
        "/cable_bringup_root/data/uploads/topology/ptp/proton-ptp-2.xlsx"
    \]
    

Upload File

  • Description – Upload the provided file to the specified folder only if the folder is accessible via web.

  • Request URL – POST /cablevalidation/files_manager/{folder_name}/files

  • Request Content Type – application/json

  • Request Data Example

      ------WebKitFormBoundarybxAm2tY7u5Lrhs4q 
    Content-Disposition: form-data; name="file"; filename="dc_layout.csv" 
    Content-Type: text/csv
     ------WebKitFormBoundarybxAm2tY7u5Lrhs4q--
    
    
     

  • Status Codes

  • Response - 201: Created

Delete File

  • Description – delete the specified file if it is accessible via web.

  • Request URL – DELETE /cablevalidation/files_manager/<folder_name>/files/<file_name>

  • Request Content Type – application/json

  • Status Codes204 – NO CONTENT404 – NOT FOUND400 – BAD REQUEST

  • Response - NA


Last updated: