Skip to content
Back to skills

Frappe Integrations

ASecurity

Frappe/ERPNext REST API, whitelisted endpoints for external use, webhooks, OAuth, calling external APIs, and Data Import. Use when integrating Frappe with another system in either direction.

  • 10 stars
  • 0 votes
  • 0 copies
  • 0 views
  • Added November 24, 2026
ai-agentspythongoapi

Works with

  • cli
  • api

Security analysis

A100/100

Scanned November 24, 2026

npx -y skills add irfanzahoor/frappe_core_skills --skill frappe-integrations --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Frappe Integrations?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for Frappe Integrations
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/irfanzahoor-frappe-integrations/badge)](https://www.skillsdirectory.com/skills/irfanzahoor-frappe-integrations)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
---
name: frappe-integrations
description: Frappe/ERPNext REST API, whitelisted endpoints for external use, webhooks, OAuth, calling external APIs, and Data Import. Use when integrating Frappe with another system in either direction.
---

# Frappe Integrations

## Inbound (others call Frappe)
- REST: `/api/resource/<DocType>[/<name>]` (CRUD), `/api/method/<dotted.path>` (whitelisted).
  v15+: `/api/v2/document/...` and `/api/v2/method/...` are also available.
- Auth: `Authorization: token <api_key>:<api_secret>`, or OAuth `Bearer <token>`. Send `Accept: application/json`.
- Create a **dedicated API user** with minimal roles. Never use Administrator keys.
- Whitelisted endpoints:
  ```python
  @frappe.whitelist(methods=["POST"])
  def create_order(customer: str, items: list | str):
      frappe.has_permission("Sales Order", "create", throw=True)
      items = frappe.parse_json(items)
      ...
  ```
  Validate input, check permissions, paginate lists, use POST for state changes.
  Never use `allow_guest=True` on anything that writes. Rate-limit guest endpoints (`@frappe.rate_limit`).

## Outbound (Frappe calls others)
- Never call external APIs in `validate` / `before_save`. Use `on_update` / `on_submit` + `frappe.enqueue`.
- Always set a timeout (`requests.post(url, json=..., timeout=30)`), wrap in try/except, and `frappe.log_error`.
- Credentials go in a Settings Single DocType with a **Password** field (`doc.get_password("api_key")`)
  or in `frappe.conf`. Never hardcode, and never send secrets to JS.
- Retry with backoff. Make calls idempotent (store the external id on the doc).

## Webhooks
- **Webhook** DocType: doc event -> URL, JSON body with Jinja (`{{ doc.name }}`, `{{ doc.items | tojson }}`).
- Set a **Webhook Secret** in production. Receivers verify the `X-Frappe-Webhook-Signature` HMAC-SHA256.
- Incoming webhooks: whitelisted method, verify the signature/token first, then enqueue the processing.

## OAuth
- Frappe as provider: OAuth Client DocType. Use HTTPS only.
- Connected App + Token Cache for third-party OAuth. Handle token expiry and refresh.
  For Google use `access_type=offline`.

## Data Import
- Download the template from Data Import (exact column names). Test 5-10 rows first, then batches of 5,000 or fewer.
- Check the Import Log for row errors. For huge or scripted loads use a patch / `bench execute` with bulk inserts.

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

View all in ai-agents →

Comments

Loading comments…

Newsletter

Get the weekly list of safe new skills, and the ones we pulled.