OTN API
Create notes from a script, CI job, or other tool — through a simple REST API.
Note: Since OTN works end-to-end encrypted, clients must perform encryption themselves before sending data to the API.
Endpoint
POST https://otn.see-sg.de/api/notes
Content-Type: application/jsonRequest body
{
"ciphertext": "<base64 of AES-256-GCM ciphertext+auth-tag>",
"iv": "<base64 of 12-byte IV>",
"keyHash": "<base64 of SHA-256(rawKey)>",
"isOneTime": true,
"expirationMinutes": null,
"creatorEmail": null
}Response
HTTP/1.1 201 Created
{
"success": true,
"uniqueId": "Ab3-fH7-zQ91",
"link": "https://otn.see-sg.de/n/Ab3-fH7-zQ91",
"expiresAt": null,
"isOneTime": true
}Fields
| field | type | |
|---|---|---|
ciphertext | string (base64) | Encrypted content (Base64), created with AES-256-GCM |
iv | string (base64, 12 B) | Initialization vector (Base64), 12 bytes |
keyHash | string (base64, 32 B) | SHA-256 hash of the key (Base64), stored by the server for verification |
isOneTime | boolean | If true, the note is deleted after first access |
expirationMinutes | number | Minutes until expiry (only when isOneTime=false) |
creatorEmail | string (optional) | Optional sender email (plaintext) |