run_sparql_query
Run read-only SPARQL SELECT or ASK queries against the CRM knowledge graph for custom joins, aggregations, and filters. Use when account/contact tools cannot answer.
Instructions
Run a read-only SPARQL SELECT or ASK query directly against the knowledge graph.
Use this for questions the higher-level account/contact tools can't answer,
e.g. joins, aggregations, or custom filters. The graph uses the crm:
prefix (http://example.org/crm#) for all classes and properties — call
get_graph_schema() first to see available classes and properties.
Only SELECT and ASK queries are permitted; INSERT/DELETE/DROP/LOAD/CREATE
are rejected. PREFIX crm: <http://example.org/crm#> is available
automatically but may also be declared explicitly.
Args: query: The SPARQL query text, e.g. "SELECT ?name ?arrUsd WHERE { ?a a crm:Account ; crm:name ?name ; crm:arrUsd ?arrUsd . } ORDER BY DESC(?arrUsd) LIMIT 5"
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| query | Yes |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |