Command Palette

Search for a command to run...

UnylyUnyly
Back to skills

using-obsidian-api

FreeNo executable scriptsNot checked

This rule provides instruction for interacting with the Obsidian API

aitorllj93by aitorllj93★ 161 GitHub stars

About this skill

Obsidian Bases API

Main types

  • BasesEntry: Represents a note/entry with properties
  • BasesViewConfig: View configuration (user options)
  • BasesPropertyId: Property identifier (string)
  • App: Obsidian application instance
  • TFile: Obsidian file

Data access

// Get property value
const value = entry.getValue(propertyId);

// Get property display name
const displayName = config.getDisplayName(propertyId);

// Get image (resolves internal and external paths)
import { getResourcePath } from "@/lib/obsidian/link";
const imageSrc = getResourcePath(app, imageUrl, entry.file.path);

Context

The Obsidian context exposes shared Obsidian variables.

const { app, component, containerEl, isEmbedded } = useObsidian();

Available hooks

Define and use reusable hooks to wrap Obsidian features in src/hooks to simplify the workflow and increase reusability

// Get config value with default
const layout = useConfigValue<"vertical" | "horizontal">("layout", "vertical");

// Get entry data
const entry = useEntry(entryId);

// Get entry property
const property = useEntryProperty(entryId, propertyId);

// Get entry title
const title = useEntryTitle(entryId);

// Handler to open entry
const handleOpen = useEntryOpen(entryId);

// Handler for hover with preview
const handleHover = useEntryHover(entryId, linkRef);

Install using-obsidian-api in Claude Code & Claude Desktop

Sign up to install this skill

Create a free account to reveal the install command and save the skill to your library.

  • Reveal the one-line install command
  • Save skills to your synced library
  • Get notified when skills update
Sign up freeI already have an account

Allowed tools

Tools this skill is permitted to call.

No restriction — this skill can use any tool.

FAQ

What does the using-obsidian-api skill do?

This rule provides instruction for interacting with the Obsidian API

How do I install the using-obsidian-api skill?

Copy the skill folder into ~/.claude/skills (the Claude Code tab above does this in one command), or install it as a plugin.

Does the using-obsidian-api skill run scripts?

No, this skill is instructions only (SKILL.md) with no executable scripts.

Related skills

Compare using-obsidian-api with