mirror of
https://github.com/qf3l3k/obsidian-data-fetcher.git
synced 2026-07-22 05:43:10 +00:00
No description
| src | ||
| .editorconfig | ||
| .eslintignore | ||
| .eslintrc | ||
| .gitignore | ||
| .npmrc | ||
| CHANGELOG.md | ||
| esbuild.config.mjs | ||
| LICENSE | ||
| main.ts | ||
| manifest.json | ||
| package-lock.json | ||
| package.json | ||
| README.md | ||
| styles.css | ||
| tsconfig.json | ||
| version-bump.mjs | ||
| versions.json | ||
Data Fetcher
A plugin for Obsidian that fetches data from external endpoints (REST, GraphQL, RPC, gRPC via proxy) and renders the results in notes.
Features
- Fetch from:
- REST APIs
- GraphQL endpoints
- RPC endpoints
- gRPC services via REST proxy
- Two query modes:
- Inline query definition in a
data-querycode block - Endpoint aliases configured in plugin settings
- Inline query definition in a
- Query result caching with configurable expiration
- Manual refresh, copy, and save-to-note actions
- Per-endpoint request headers for authentication and API keys
Installation
Community Plugins
- Open Obsidian Settings.
- Go to Community Plugins.
- Search for
Data Fetcher. - Install and enable.
Manual
- Download the latest release from the repository.
- Place the release files in your vault at
.obsidian/plugins/data-fetcher. - Enable the plugin in Obsidian settings.
Usage
1. Inline Query
{
"type": "rest",
"url": "https://api.example.com/data",
"method": "GET",
"headers": {
"Authorization": "Bearer your-token"
}
}
2. Endpoint Alias
- Configure an endpoint alias in plugin settings.
- Reference it in a note:
@my-api-alias
body: {"id":123}
3. Alias With Call-Site Variables
For GraphQL aliases, you can pass variables inline from the call location:
@github-api({"first": 5, "after": null})
You can also use the =@alias(...) variant:
=@github-api({"first": 5})
GraphQL Example
{
"type": "graphql",
"url": "https://api.spacex.land/graphql",
"query": "{ launchesPast(limit: 5) { mission_name launch_date_local } }",
"variables": {}
}
Configuration
Open Settings -> Data Fetcher to manage:
- Cache duration
- Endpoint aliases
- Endpoint headers
- Cache cleanup
Data Disclosure
This plugin communicates with external services and stores response data:
- Network usage: Sends HTTP(S) requests to endpoint URLs defined in notes or settings.
- External dependencies: Uses Obsidian's built-in
requestUrlAPI; no third-party analytics SDK is used. - Data sent: Request URL, method, headers, and optional body/query you configure.
- Data stored locally: Cached responses in vault folder
.data-fetcher-cacheand plugin settings in Obsidian plugin data. - Data shared externally: Only with endpoint services you explicitly configure.
Support
- Issues and feature requests: GitHub Issues
License
MIT