skills/konecty-create/SKILL.md
Creates records in any Konecty module via POST /rest/data/:document. Guides through the full pre-creation workflow: discovering fields and types with konecty-modules, resolving lookup _ids with the built-in lookup command, checking picklist options, validating required fields, and submitting the payload. Use when the user wants to create a new record, insert data, send a message, add an activity, register a contact, create an opportunity, or create any document in Konecty. Requires an active konecty-session (KONECTY_URL and KONECTY_TOKEN in ~/.konecty/.env or ~/.konecty/credentials).
npx skillsauth add konecty/skills konecty-createInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
Create records in any Konecty module following a discover → validate → create workflow.
~/.konecty/.env or ~/.konecty/credentials.POST /rest/data/:document
Body: flat JSON object with field names as keys
Response: { "success": true, "data": [{ created record }] }
{ "success": false, "errors": [{ "message": "..." }] }
HTTP status is always 200. Success/failure is in the success field.
python3 skills/konecty-modules/scripts/modules.py fields "<Module>"
Note the fields you need: their name (for the payload key), type (determines payload format), picklist options, and lookup target document.
For every lookup or inheritLookup field you want to set, find the target record's _id:
# By numeric code
python3 skills/konecty-create/scripts/create.py lookup Contact 16503
# By name / free text
python3 skills/konecty-create/scripts/create.py lookup Campaign "Black Friday"
Output shows _id and display fields. Use { "_id": "..." } in the payload.
The options: column in konecty-modules fields shows valid keys. Use exactly those strings as values.
python3 skills/konecty-create/scripts/create.py create <Document> --data '<JSON>'
If the API returns "Field X is required", add the missing field and retry.
# Step 1: discover Message fields
python3 skills/konecty-modules/scripts/modules.py fields "Message"
# Step 2: find contact _id by code
python3 skills/konecty-create/scripts/create.py lookup Contact 16503
# Step 3: create the message
python3 skills/konecty-create/scripts/create.py create Message --data '{
"subject": "Bem-vindo ao Konecty!",
"body": "<p>Olá! Seja muito bem-vindo(a). Estamos felizes em tê-lo(a) conosco.</p>",
"contact": { "_id": "JeSqMH6mkP5f233Rp" },
"status": "Nova",
"type": "Email"
}'
python3 skills/konecty-create/scripts/create.py create Contact --data '{
"name": { "first": "Maria", "last": "Silva" },
"type": ["client"],
"email": [{ "address": "[email protected]" }]
}'
# Find contact _id first
python3 skills/konecty-create/scripts/create.py lookup Contact 16503
python3 skills/konecty-create/scripts/create.py create Activity --data '{
"subject": "Ligação de boas-vindas",
"status": "Realizado",
"type": "Ligação",
"contact": { "_id": "JeSqMH6mkP5f233Rp" }
}'
| Type | Send as |
|------|---------|
| text / richText | "string" — richText accepts HTML |
| number / percentage | 123 or 12.5 |
| boolean | true / false |
| date | "2026-03-16" |
| dateTime | "2026-03-16T14:00:00.000Z" |
| picklist (single) | "option_key" |
| picklist (multi) | ["key1", "key2"] |
| lookup / inheritLookup | { "_id": "record-id" } — use create.py lookup to find it |
| email | { "address": "[email protected]" } |
| phone | { "countryCode": 55, "phoneNumber": "5511999999999" } |
| personName | { "first": "João", "last": "Silva" } |
| money | { "currency": "BRL", "value": 100.0 } |
| autoNumber | do not send — auto-generated |
For full details and edge cases, see references/field-types.md.
null and "" in payload are stripped — equivalent to not sending the field.konecty-modules fields.{ "_id": "..." }. The server fetches the description fields automatically."Field X is required" tells you exactly what to add.autoNumber fields (code) are never sent — generated server-side._id is never sent — generated server-side.See scripts/create.py. Stdlib only.
create.py create <Document> --data '<JSON>' # create a record
create.py lookup <Document> <term> # find _id by code or text
All subcommands accept --host and --token to override credentials.
data-ai
Replace with description of the skill and when the agent should use it.
tools
Upload, list, and delete files in Konecty document fields via the file API. Use this skill whenever the user wants to attach a file to a Konecty record, upload a photo/image to a contact or product, add a PDF or document to an opportunity, send a curriculum to a candidate, manage gallery images for a development or promotion, or attach any binary file to any Konecty module field. Also triggers when the user says 'upload', 'anexar', 'enviar arquivo', 'adicionar imagem', 'attach file', or refers to file-type fields in any document. Automatically reads field constraints (accepted extensions, max size, max file count) from metadata before uploading to catch errors early. Requires an active konecty-session (KONECTY_URL and KONECTY_TOKEN in ~/.konecty/.env or ~/.konecty/credentials).
documentation
Updates records in any Konecty module via PUT /rest/data/:document. Enforces the mandatory pre-update fetch workflow: always fetch the current record first to obtain its _updatedAt (optimistic locking guard), then PUT with ids=[{_id, _updatedAt}] and data={changed fields}. Use when the user wants to update, edit, change, or modify any record in Konecty. Requires an active konecty-session. Use konecty-modules to discover field names and types before updating.
development
Opens a Konecty session via OTP login (request OTP, then verify OTP) and persists the access token in .env or ~/.konecty/credentials for use by other skills. Use when the user wants to log in to Konecty with OTP, store credentials, set up KONECTY_TOKEN, or establish a session so other Konecty skills can call the API. Only works when the namespace has OTP enabled (email or WhatsApp).