Predict
Used to send prediction request and get result-id as response.
POST
URL:{{base_url}}/api/{{version}}/model/:id/predict
Path Parameters
Request Body
200: OK Returns result_id. 400: Bad Request Message field can be used to identify the issue. 401: Unauthorized Invalid API key. 500: Internal Server Error
Copy {
"data" : {
"result_id" : "String"
} ,
"message" : "String" ,
"status" : 200
}
Copy {
"data" : {} ,
"message" : "String" ,
"status" : 400
}
Copy {
"data" : {} ,
"message" : "ERROR: Unauthorized" ,
"status" : 401
}
Used to get result of a particular prediction using result id.
GET
URL:{{base_url}}/api/{{version}}/model/result/:id
Path Parameters
200: OK Value of result field is a dictionary that contains prediction result. Structure of result dictionary may vary with different ml models. 400: Bad Request Message field can be used to identify the issue. 401: Unauthorized Invalid api key. 500: Internal Server Error 202: Accepted IN PROGRESS status indicates that the ml model is predicting the result. May take some time to produce the result. Try to call the API after some time to get the result. 204: No Content FAILED status indicates that the given prediction request is failed due to some reasons. Please contact Visualyze.AI for more information.
Copy {
"data" : {
"message" : "String" ,
"status" : "SUCCESS" ,
"result" : {}
} ,
"message" : "String" ,
"status" : 200
}
Copy {
"data" : {} ,
"message" : "String" ,
"status" : 400
}
Copy {
"data" : {} ,
"message" : "ERROR: Unauthorized" ,
"status" : 401
}
Copy {
"data" : {
"message" : "String" ,
"status" : "IN PROGRESS" ,
"result" : {}
} ,
"message" : "String" ,
"status" : 202
}
Copy {
"data" : {
"message" : "String" ,
"status" : "FAILED" ,
"result" : {}
} ,
"message" : "String" ,
"status" : 204
}
Model
Used to list available models.
GET
URL:{{base_url}}/api/{{version}}/model/view
200: OK Models field contains list of models. Each dictionary in the list is used to represent a unique ml model. Version details of pretrained models will be unavailable to the user. 401: Unauthorized Invalid API key. 400: Bad Request Message field can be used to identify the issue.
Copy {
"data" : {
"models" : []
} ,
"message" : "String" ,
"status" : 200
}
Copy {
"data" : {} ,
"message" : "ERROR: Unauthorized" ,
"status" : 401
}
Copy {
"data" : {} ,
"message" : "String" ,
"status" : 400
}
Used to get model details.
GET
URL:{{base_url}}/api/{{version}}/model/:id/view
Path Parameters
200: OK Model details dictionary will have the details of ml model. 401: Unauthorized Invalid API key. 500: Internal Server Error 400: Bad Request Message field can be used to identify the issue.
Copy {
"data" : {
"model_details" : {}
} ,
"message" : "String" ,
"status" : 200
}
Copy {
"data" : {} ,
"message" : "ERROR: Unauthorized" ,
"status" : 401
}
Copy {
"data" : {} ,
"message" : "String" ,
"status" : 400
}
Used to get version details of particular model.
GET
URL:{{base_url}}/api/{{version}}/model/:id/:version/info
Path Parameters
200: OK Info field contains version based details of a particular ml model. But we do not provide version details of PRETRINED ml models. You may get an empty dictionary in the case of PRETRINED models. 401: Unauthorized Invalid API key. 500: Internal Server Error 400: Bad Request Message field can be used to identify the issue.
Copy {
"data" : {
"info" : {}
} ,
"message" : "successfully retrieved details" ,
"status" : 200
}
Copy {
"data" : {} ,
"message" : "ERROR: Unauthorized" ,
"status" : 401
}
Copy {
"data" : {} ,
"message" : "String" ,
"status" : 400
}
Used to delete latest model version.
DELETE
URL:{{base_url}}/api/{{version}}/model/:id/delete
Path Parameters
200: OK Deleted the latest version of model. 401: Unauthorized Invalid API key. 500: Internal Server Error 400: Bad Request Message field can be used to identify the issue.
Copy {
"data" : {} ,
"message" : "deleted successfully" ,
"status" : 200
}
Copy {
"data" : {} ,
"message" : "ERROR: Unauthorized" ,
"status" : 401
}
Copy {
"data" : {} ,
"message" : "String" ,
"status" : 400
}
You cannot delete PRETRIAINED models using Delete API