Expand Minimize Picture-in-picture Power Device Status Voice Recognition Skip Back Skip Forward Minus Plus Play Search
Internet Explorer alert
This browser is not recommended for use with smartdevicelink.com, and may not function properly. Upgrade to a different browser to guarantee support of all features.
close alert
To Top Created with Sketch. To Top
To Bottom Created with Sketch. To Bottom
HMI Documentation
GetFilePath

GetFilePath

Type
Request
Sender
SDL
Purpose
Retrieve a file path from the HMI App Service Provider (ASP)

Request

Parameters

Name Type Mandatory Additional
fileName String true maxlength: 255
fileType Common.FileType false
appServiceId String false

Response

Parameters

Name Type Mandatory Additional
filePath String false
fileType Common.FileType false

Sequence Diagrams

JSON Message Examples

Example Request

{
  "id": 34,
  "jsonrpc": "2.0",
  "method": "BasicCommunication.GetFilePath",
  "params": {
    "appServiceId": "d712bcaced1260e90f1acf95522dc0ef763bc72f234bcf7672cd7e23801cf150",
    "fileName": "somefile.json",
    "fileType": "JSON"
  }
}

Example Response

{
    "id": 34,
    "jsonrpc": "2.0",
    "result": {
        "method": "BasicCommunication.GetFilePath",
        "code": 0,
        "fileType": "JSON",
        "filePath": "/home/user/HMI/somefile.json"
    }
}

Example Error

{
  "id" : 34,
  "jsonrpc" : "2.0",
  "error" : {
    "code" : 27,
    "message" : "File not found",
    "data" : {
      "method" : "BasicCommunication.GetFilePath"
    }
  }
}
View on GitHub.com
Previous Section Next Section