queryType: getSavedAnalyses*

The getSavedAnalyses queryType is passed to the API to get a list of analyses that have been run on your database in the past.

Note:

See Special Case APIs for more information.

The data returned will be basic information about the analysis. Each record will have a jobId that you can then pass to getSavedResults to get the results/data for that analysis.

Parameters

These parameters should be passed to the functionParameters object regardless of which method you choose to make an API request.

ParameterDescriptionTypeDefined Value SetValue Req'd
queryTypeMust equal "getSavedAnalyses".STRING"getSavedAnalyses"Y
analysisJobIdsAn array of strings representing analysis job ids. Pass the job id of a previous analysis to get back the results of just that analysis. Pass an empty array or omit the parameter to return all.ARRAY-N
analysisTypesAn array of queryTypes representing the saved analyses you want returned. Currently it must be “getOriginDestinationMatrix”, “getRouteAnalysis”, “getODSegmentAnalysis”, “getStopanalytics”, getVehicleDistanceTravelled”, “getDemandGeneration”, “getIdleMetrics”, ”getModeledVehicleDistanceTraveled”, "getDemandGenerationTimeSeries", "getFuelEconomyTimeSeries", "getIdleMetricsTimeSeries", "getModeledVehicleDistanceTraveledTimeSeries", "getObservedCountsTimeSeries", "getOriginDestinationMatrixTimeSeries", "getVehicleDistanceTraveledTimeSeries",or “getObservedCounts” . Pass an empty array or omit the parameter to return all typesARRAY“getOriginDestinationMatrix”, “getRouteAnalysis”, “getODSegmentAnalysis”, “getStopAnalytics”, "getVehicleDistanceTravelled”, “getDemandGeneration”, “getIdleMetrics”, "getModeledVehicleDistanceTraveled”,"getDemandGenerationTimeSeries", "getFuelEconomyTimeSeries", "getIdleMetricsTimeSeries", "getModeledVehicleDistanceTraveledTimeSeries", "getObservedCountsTimeSeries", "getOriginDestinationMatrixTimeSeries", "getVehicleDistanceTraveledTimeSeries", or “getObservedCounts”. N
createdByListAn array of userNames representing who ran the analysis originally. Pass an empty array or omit the parameter to return allARRAY-N
statusesAn array of values representing whether you want active (1), archived (0) or all analyses. Pass an empty array or omit the parameter to return all. Note that users have the ability to archive saved analyses in the UIARRAY0 or 1N

Responses

CodeTypeDescription
200JSONThe requested data.
401JSONOccurs for various unauthorized tasks, such as not providing credentials in your parameters.
500JSONOccurs if an internal server error occurs. Contact altitudesupport@geotab.com if this occurs.

Response Schema

AttributeDescriptionData TypeDefined Value Set
AnalysisNameThe name of the analysis. Defaults to date and userName, but can be changed via the UI.STRING-
AnalysisLabelsArray of strings representing analysis label names associated with the analysis.ARRAY-
AnalysisLabelIdsArray of strings representing analysis label ids associated with the analysis.ARRAY-
AnalysisMetadataAny additional metadata associated with this analysis, formatted as a JSON string.STRING-
AnalysisTypeThe queryType of the saved analysis.STRING-
CallSourceWhere the analysis was run from.STRING“API” or “Application”
CommentsAny comments added to the analysis via the UI.STRING-
CreatedByuserName of the person who ran the analysis.STRING-
CreatedTimestampTimestamp for when the analysis was created.TIMESTAMP-
DatabaseName of the database where the analysis was run.STRING-
JobIdThe unique id of the analysis. Can be passed to getSavedResults to get the results of the analysis.STRING-
ModifiedByThe userName of the person who last modified the analysis.STRING-
ModifiedTimestampTimestamp for when the analysis was modified.TIMESTAMP-
ParametersA JSON string of parameters that were used to generate the analysis.STRING-
Status1 for active analyses, 0 for archived analyses (can archive via the UI)INTEGER0- Active,1- Archived

Sample parameters

{
	"analysisTypes":[],
	"queryType":"getSavedAnalyses",
	"statuses":[1]

}