# Risk Graph Dependencies API

> Risk Graph Dependencies API is a paid API for AI agents from risk-graph-gx7v4.ondigitalocean.app, paid per call via x402, $1/call, status unknown (last checked 2026-09-15).

Returns the direct (1-hop) neighbors and edge types for a given pool node in a DeFi risk knowledge graph

## Facts

- Endpoint: GET https://risk-graph-gx7v4.ondigitalocean.app/api/v1/agent/dependencies
- Price: $1/call
- Payment: x402
- Status: unknown
- Last checked: 2026-09-15
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/risk-graph-gx7v4-ondigitalocean-app-a2dddd97
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_UGaFcSb3-TZcz0Y-mTJuC

Status and success rate cover calls made through Zero and Zero's own probes. Third-party monitors may report differently.

## How to call it through Zero

Zero handles the 402 payment challenge and records the run. With the Zero CLI installed (`npm i -g @zeroxyz/cli`):

```sh
zero fetch --capability risk-graph-gx7v4-ondigitalocean-app-a2dddd97
```

Example prompt: Show me the immediate dependencies and edge relationships for pool node 'aave-v3-usdc-mainnet' in the risk graph — I want to see what assets, protocols, and chains it's directly connected to and what kind of edges link them.

## When to prefer this

Use this endpoint when you need to understand the immediate structural dependencies of a specific pool node — which assets back it, which protocols it allocates to, and what edge types define those relationships. Prefer this over the full recursive breakdown when you only need one hop of context and want lower cost and faster response. Use after looking up the nodeId via the discovery/search endpoint.

## Known failure modes

- Missing or invalid nodeId returns a 400 or empty result
- Unknown nodeId returns an empty neighbors and edges array
- Payment not included or insufficient ($1 USDC) results in 402 Payment Required
- Node exists but has no outgoing edges returns empty arrays
- Rate limiting or service unavailability returns 5xx error

## How this service works

Direct (1-hop) dependencies of a pool — immediate neighbors + edge types

## Output

Returns two arrays: 'neighbors' (each with a stable node ID, PascalCase labels like Pool/Asset/Protocol/Chain, and a property bag including _riskTier A–F) and 'edges' (each with source/target IDs, an edge type label like ALLOCATES or IS_COLLATERALIZED_BY, and additional properties). This gives a complete picture of the pool's direct graph neighborhood.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "$schema": "https://json-schema.org/draft/2020-12/schema",
 "required": [
  "input"
 ],
 "properties": {
  "input": {
   "type": "object",
   "required": [
    "type",
    "method"
   ],
   "properties": {
    "type": {
     "type": "string",
     "const": "http"
    },
    "method": {
     "enum": [
      "GET"
     ],
     "type": "string"
    },
    "queryParams": {
     "type": "object",
     "required": [
      "nodeId"
     ],
     "properties": {
      "nodeId": {
       "type": "string",
       "description": "Pool node id to fetch direct (1-hop) dependencies for."
      }
     }
    }
   },
   "additionalProperties": false
  },
  "output": {
   "type": "object",
   "required": [
    "type"
   ],
   "properties": {
    "type": {
     "type": "string"
    },
    "example": {
     "type": "object",
     "required": [
      "edges",
      "neighbors"
     ],
     "properties": {
      "edges": {
       "type": "array",
       "items": {
        "type": "object",
        "required": [
         "type",
         "sourceId",
         "targetId",
         "properties"
        ],
        "properties": {
         "type": {
          "type": "string",
          "description": "Edge label (e.g. \"ALLOCATES\", \"IS_COLLATERALIZED_BY\", \"BACKED_BY\")."
         },
         "sourceId": {
          "type": "string"
         },
         "targetId": {
          "type": "string"
         },
         "properties": {
          "type": "object",
          "additionalProperties": true
         }
        }
       }
      },
      "neighbors": {
       "type": "array",
       "items": {
        "type": "object",
        "required": [
         "id",
         "labels",
         "properties"
        ],
        "properties": {
         "id": {
          "type": "string",
          "description": "Stable node identifier — `nodeId` everywhere else in the API."
         },
         "labels": {
          "type": "array",
          "items": {
           "type": "string"
          },
          "description": "PascalCase Neo4j labels (e.g. \"Pool\", \"Asset\", \"Protocol\", \"Chain\")."
         },
         "properties": {
          "type": "object",
          "description": "Per-label property bag — see /agent/schema for the canonical keys. Risk is exposed as `_riskTier` (A–F) only. May also carry `tvlUsd` (canonical $ size), `riskBreakdown` (on /node — an array of {question, answer} explaining the grade, no numbers), and `lastUpdatedAt` (on /dependencies — IS
… (truncated)
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/risk-graph-gx7v4-ondigitalocean-app-a2dddd97/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from risk-graph-gx7v4.ondigitalocean.app](https://www.zero.xyz/host/risk-graph-gx7v4.ondigitalocean.app/llms.txt)
