Pathfinder


Overview

The Pathfinder API finds paths (shortest, all, or up to N hops) between a source and a target object in the application graph.


URI

GET /rest/applications/{application}/graph/pathfinder

Path parameters

application (string)

The application name. The application name must be properly encoded if it is required. Character back-quote is not allowed.

Query parameters

source (string)

Required. The unique identifier (elementId) of the source object.

target (string)

Required. The unique identifier (elementId) of the target object.

hops (int)

Optional, default: 3. The maximum number of hops to traverse.

path (string)

Optional, default: shortest. The type of path to find.

  • shortest: Finds the shortest path between source and target.
  • nhops: Finds paths up to hops length.
  • expand: Find all the paths up to hops length.
calltype (string)

Optional, default: caller. Direction of the call graph to traverse.

  • caller: Traverse upstream (who calls/uses the object).
  • callee: Traverse downstream (who the object calls/uses).

Responses

application/json

A GraphDocument containing nodes and edges representing the paths found.

{
    "results": {
        "graph": {
            "nodes": [
                {
                    "id": "4:33cdac75-40b4-4b7c-939b-1a4f316defb4:171383",
                    "data": {
                        "AipId": "1595",
                        "DrillDown": "JOB.JCLDataSetKSDSVSAMFilesCobolBatchProgramJCLLibraries.JOBFUNC#",
                        "External": false,
                        "FullName": "[§{main_sources}§/Mainframe/JCL].JOBFUNC#.COBOL1",
                        "InternalType": "CAST_JCL_Step",
                        "Level": "JCL Job",
                        "Name": "COBOL1",
                        "Type": "JCL Step"
                    }
                },
                {
                    "id": "4:33cdac75-40b4-4b7c-939b-1a4f316defb4:172025",
                    "data": {
                        "AipId": "1810",
                        "Count": 3,
                        "DrillDown": "JOB.JCLDataSetKSDSVSAMFilesCobolBatchProgramJCLLibraries",
                        "External": false,
                        "FullName": "[§{main_sources}§/Mainframe/JCL].JOBFUNC#",
                        "InternalType": "CAST_JCL_CatalogedJob",
                        "Level": "JCL Job",
                        "Name": "JOBFUNC#",
                        "Type": "JCL Job"
                    }
                }
            ],
            "edges": [
                {
                    "id": "5:33cdac75-40b4-4b7c-939b-1a4f316defb4:1152942395327946745",
                    "source": "4:33cdac75-40b4-4b7c-939b-1a4f316defb4:172025",
                    "target": "4:33cdac75-40b4-4b7c-939b-1a4f316defb4:171383",
                    "type": "CALL"
                }
            ]
        },
        "documents": null
    }
}

JSON representation

Property Type Description
results.graph.nodes[].id string The unique identifier of the node.
results.graph.nodes[].data object properties of the node (Name, FullName, Type, etc.).
results.graph.edges[].id string The unique identifier of the edge.
results.graph.edges[].source string The ID of the source node for this edge.
results.graph.edges[].target string The ID of the target node for this edge.
results.graph.edges[].type string The type of the relationship (e.g., CALL, WRITE).
results.documents array List of associated documents (optional).