# Okf Graphql

> GraphQL connector that produces and ingests Open Knowledge Format (OKF) bundles from a GraphQL SDL document. Parses the schema into one concept per user-defined type (object/input/interface/enum/union) and per root operation (query/mutation/subscription field), links fields and operations to the types they reference as native relationship edges, and syncs descriptions back to a .okf-metadata.yaml…

- **Type:** Skill
- **Install:** `agentstack add skill-xsavikx-okf-skills-okf-graphql`
- **Verified:** Yes — security-reviewed for prompt injection and unsafe behavior
- **Seller:** [xSAVIKx](https://agentstack.voostack.com/s/xsavikx)
- **Installs:** 0
- **Category:** [Agent Skills](https://agentstack.voostack.com/c/agent-skills)
- **Latest version:** 0.1.0
- **License:** Apache-2.0
- **Upstream author:** [xSAVIKx](https://github.com/xSAVIKx)
- **Source:** https://github.com/xSAVIKx/okf-skills/tree/master/skills/okf-graphql
- **Website:** https://xsavikx.github.io/okf-skills/

## Install

```sh
agentstack add skill-xsavikx-okf-skills-okf-graphql
```

Requires the [AgentStack CLI](https://agentstack.voostack.com/docs/cli). Works with Claude Code, Cursor, and any MCP-compatible agent.

## About

# GraphQL OKF Connector

This skill provides a Go-based CLI tool to document a GraphQL schema (SDL) as an Open
Knowledge Format (OKF) bundle: one concept per user-defined type and per root
operation, with fields and operations linked to the types they reference. It needs
only the SDL file — no live server.

## When to Use

Use this skill when you need to:
1. Catalog a GraphQL API from its SDL — types under `types/`, queries under
   `queries/`, mutations under `mutations/` (subscriptions under `subscriptions/`).
2. Turn the type graph into a connected, browsable view — field→type and
   operation→type `references` edges render as typed edges in `okf-viz`.
3. Round-trip enriched descriptions back to a `.okf-metadata.yaml` sidecar.

## Setup

```bash
go install github.com/xSAVIKx/okf-skills/skills/okf-graphql@latest
# …or: cd skills/okf-graphql && go build -o okf-graphql .
```

## How to Use

### 1. Produce an OKF bundle

```bash
./okf-graphql produce --schema  --out 
```

- `--schema` (required): path to the GraphQL SDL document.
- `--out` (required): output OKF bundle directory.

Each object/input/interface type becomes `types/.md` with a `# Columns` field
table (`Name | Type | Required`); enums emit a `# Values` list; unions emit their
members. Each root field becomes an operation concept with its arguments and return
type. Fields/operations link to the types they reference under `# Relationships`.
Re-running preserves enriched descriptions.

### 2. Ingest / sync descriptions

```bash
./okf-graphql ingest --schema  --bundle  [--sync]
```

- Verifies each concept still exists in the schema (reports drift); the SDL is never
  modified.
- `--sync`: writes the bundle's descriptions to `.okf-metadata.yaml` next to the SDL.

### 3. Inspect the schema (self-description)

```bash
./okf-graphql schema
```

Prints the machine-readable JSON description used by `okf-mcp` to expose the skill.

## Source & license

This open-source skill is cataloged on AgentStack and links to its original source — we do not rehost the code.

- **Author:** [xSAVIKx](https://github.com/xSAVIKx)
- **Source:** [xSAVIKx/okf-skills](https://github.com/xSAVIKx/okf-skills)
- **License:** Apache-2.0
- **Homepage:** https://xsavikx.github.io/okf-skills/

Install and usage instructions live in the source repository linked above.

## Pricing

- **Free** — Free

## Security capabilities

Automated source analysis of v0.1.0 — what this tool can access:

- **Network access:** no
- **Filesystem access:** no
- **Shell / process execution:** no
- **Environment & secrets:** no
- **Dynamic code execution:** no

*"Yes" means the capability is present in the source — more access means more to trust, not that it is unsafe.*


## Versions

- **0.1.0** — security scan: passed — Imported from the upstream source.

## Links

- Listing page: https://agentstack.voostack.com/l/skill-xsavikx-okf-skills-okf-graphql
- Seller: https://agentstack.voostack.com/s/xsavikx
- Browse the marketplace: https://agentstack.voostack.com/browse

---
Listed on AgentStack — the marketplace for AI agent skills and MCP servers. Every listing is security-reviewed. Creators keep 70%.
