Browse the API reference

Block Source Graph

post/extensions/roboledger/{graph_id}/operations/block-source-graph

Part of Extensions: RoboLedger.

Bars a graph from sharing reports into this one. Subsequent share-report calls naming this graph fail for this target with an explicit error — blocked senders are told, not silently dropped. Idempotent: re-blocking preserves the original blocked_at. Set purge to also delete every report already shared in from that source, along with its fact sets and facts; reports this graph authored are never touched.

Idempotency: supply an Idempotency-Key header to make safe retries; replays within 24 hours return the same envelope. Reusing the key with a different body returns HTTP 409 Conflict.

Authentication

Authenticate in any one of these ways — not all of them:

  • API key in the X-API-Key header.
  • Bearer token in the Authorization header.

Path parameters

NameTypeDescription
graph_idrequiredstringGraph Id

Header parameters

NameTypeDescription
Idempotency-KeyoptionalstringIdempotency-Key

Request body

Required, application/json.

FieldTypeDescription
source_graph_idrequiredstring

Graph ID to block. Read it off the `source_graph_id` provenance field of a report that was shared to you.

reasonoptionalstring

Free-form note for your own records. Never disclosed to the sender.

purgeoptionalboolean

Also delete every report already shared in from this source, with their fact sets and facts. Reports you authored are never touched.

Default: false

Example request

curl
curl -X POST "https://api.robosystems.ai/extensions/roboledger/{graph_id}/operations/block-source-graph" \
  -H "X-API-Key: $ROBOSYSTEMS_API_KEY" \
  -H "Idempotency-Key: <Idempotency-Key>" \
  -H "Content-Type: application/json" \
  -d '{
  "source_graph_id": "kg1a2b3c4d5e6f7a8b9c"
}'

Responses

200 Successful Response

FieldTypeDescription
operationrequiredstring

Kebab-case operation name

operationIdrequiredstring

op_-prefixed ULID for audit and SSE correlation

statusrequiredstring

Operation lifecycle state

One of: completed, pending, failed

resultoptionalBlockSourceGraphResult

Command-specific result payload

BlockSourceGraphResult fields
FieldTypeDescription
blockrequiredBlockedSourceGraphResponse

The block record.

BlockedSourceGraphResponse fields
FieldTypeDescription
idrequiredstring

Block row identifier (ULID).

source_graph_idrequiredstring

The blocked sender's graph ID.

source_graph_nameoptionalstring

Display name of the blocked graph (if known).

blocked_byrequiredstring

User ID that created the block.

blocked_atrequiredstring (date-time)

When the block was created.

reasonoptionalstring

Recipient's own note, if given.

already_blockedoptionalboolean

True when the source was already blocked and this call was a no-op apart from any purge.

Default: false

purged_report_countoptionalinteger

Number of previously-shared reports deleted from this graph. Zero unless `purge` was set.

Default: 0

purged_report_idsoptionalstring[]

Ids of the previously-shared reports deleted from this graph. Empty unless `purge` was set.

atrequiredstring

ISO-8601 UTC timestamp

createdByoptionalstring

User ID that initiated the operation (null for legacy callers)

idempotentReplayoptionalboolean

True when this envelope came from the idempotency cache — the underlying command did not execute again. False on fresh executions.

Default: false

StatusMeaning
400Invalid request
401Authentication required
403Access denied
404Resource not found
409Idempotency-Key conflict — key reused with different body
422Validation error
429Rate limit exceeded
500Internal server error