The workflow JSON
Copy or download the full n8n JSON below. Paste it into a new n8n workflow, add your credentials, activate. Full import guide →
{
"name": "Obatin \u2014 CRUD",
"nodes": [
{
"id": "9c96c00e-7e36-4afb-b1e1-f4b047445525",
"name": "Webhook",
"type": "n8n-nodes-base.webhook",
"typeVersion": 2,
"position": [
250,
300
],
"parameters": {
"httpMethod": "POST",
"path": "obatin-crud",
"responseMode": "lastNode",
"responseData": "all",
"options": {}
}
},
{
"id": "08ac367e-ac14-4303-af79-f15d5f6301e8",
"name": "Validate Token",
"type": "n8n-nodes-base.postgres",
"typeVersion": 2,
"position": [
550,
300
],
"parameters": {
"operation": "executeQuery",
"query": "SELECT value FROM settings WHERE key = 'token' LIMIT 1",
"additionalFields": {}
},
"credentials": {
"postgres": {
"name": "<your credential>"
}
}
},
{
"id": "3f72238c-27ed-44cf-b486-62b6afe9bbe9",
"name": "Route Action",
"type": "n8n-nodes-base.code",
"typeVersion": 2,
"position": [
850,
300
],
"parameters": {
"language": "python",
"code": "import json\nbody = items[0].json['body']\nauth = items[0].json['headers'].get('authorization', '').replace('Bearer ', '')\ndb_token = items[0].json['value']\nif auth != db_token:\n return [{'json': {'error': 'Unauthorized'}}]\naction = body.get('action', '')\nreturn [{'json': {'action': action, 'body': body, 'authorized': True}}]"
}
},
{
"id": "e8a7840b-6ee6-496a-9d17-fe8f9c0f5844",
"name": "Execute SQL",
"type": "n8n-nodes-base.postgres",
"typeVersion": 2,
"position": [
1150,
300
],
"parameters": {
"operation": "executeQuery",
"query": "={{ $json.body.query }}",
"additionalFields": {}
},
"credentials": {
"postgres": {
"name": "<your credential>"
}
}
},
{
"id": "28c74724-a1b1-4594-b328-094593a7a46f",
"name": "Response",
"type": "n8n-nodes-base.respondToWebhook",
"typeVersion": 2,
"position": [
1450,
300
],
"parameters": {
"respondWith": "json",
"responseBodyType": "json",
"responseBodyJson": "={{ $json }}"
}
}
],
"connections": {
"Webhook": {
"main": [
[
{
"node": "Validate Token",
"type": "main",
"index": 0
}
]
]
},
"Validate Token": {
"main": [
[
{
"node": "Route Action",
"type": "main",
"index": 0
}
]
]
},
"Route Action": {
"main": [
[
{
"node": "Execute SQL",
"type": "main",
"index": 0
}
]
]
},
"Execute SQL": {
"main": [
[
{
"node": "Response",
"type": "main",
"index": 0
}
]
]
}
},
"settings": {
"executionOrder": "v1"
},
"staticData": null,
"tags": []
}
Credentials you'll need
Each integration node will prompt for credentials when you import. We strip credential IDs before publishing — you'll add your own.
postgres
For the full experience including quality scoring and batch install features for each workflow upgrade to Pro
About this workflow
Obatin — CRUD. Uses postgres. Webhook trigger; 5 nodes.
Source: https://github.com/inurdiansyah/obatin/blob/5eb5909e7334010e997d8f28f5234bca23cdf0d9/n8n/obatin-crud.json — original creator credit. Request a take-down →
Related workflows
Workflows that share integrations, category, or trigger type with this one. All free to copy and import.
CMM. Uses httpRequest, postgres, redis. Webhook trigger; 90 nodes.
Scraping. Uses httpRequest, postgres, @apify/n8n-nodes-apify, respondToWebhook. Webhook trigger; 61 nodes.
Workflow B — AI Listing Engine. Uses httpRequest, postgres, errorTrigger. Webhook trigger; 47 nodes.