Create¶
POST /api/v1/notes_v2/create
Overview¶
Create a new version note.
Body Parameters¶
| Parameter | Type | Required | Description |
|---|---|---|---|
| title | string | Y | Note title Allow empty: False |
| content | string | Y | Markdown content Allow empty: False |
| tags | array | Tag list Allow empty: False |
|
| tagKV | json | Key-value tags Allow empty: False |
|
| isPublic | int | Whether public, 1 for public, 0 for private, default 1 Allow empty: False |
|
| extend | json | Studio business extension field Allow empty: False |
Parameter Details¶
Use this API to create a new version note. The request body must at least include title and content, optionally include tags, tagKV, isPublic, and extend.
- Do not pass the note storage path, nor
noteUUID; readnoteUUIDfrom the response after successful creation. isPublicdefaults to public note if not passed; pass0for a private note.- After successful creation, use the
noteUUIDfrom the response for subsequent retrieval, modification, and deletion. - The
etagin the response can be used asifMatchfor the first edit or deletion.
Request Example¶
curl 'https://openapi.guance.com/api/v1/notes_v2/create' \
-H 'DF-API-KEY: <DF-API-KEY>' \
-H 'Content-Type: application/json;charset=UTF-8' \
--data-raw '{"title":"A","content":"# A","tags":["ops"],"tagKV":{"host":"127.0.0.1"}}'