Axuz Developers

POST /me/notes/renormalize

Reescreve `position` das notas vivas do caller em sequência 100, 200, 300… preservando a ordem corrente.

  • Access: Signed in
  • Service: https://api.axuz.net

Accepted authentication

  • sessionCookie — Sessão plena Axuz (cookie de sessão da casa). Sessão restrita é 403 enrollment_required.
  • bearerSession — JWT de acesso da sessão em `Authorization: Bearer`.
  • personalToken — Token pessoal (`axp_...`) criado em `POST /me/api-tokens`; escopo do próprio usuário.

Reescreve position das notas vivas do caller em sequência 100, 200, 300… preservando a ordem corrente.

Motivo: drag-and-drop com midpoints double converge — sem renormalize a precisão colapsa e insersões entre vizinhos deixam de funcionar.

Entradas: userID do JWT.

Retorno: 200 com {count:N}; 401 sem auth; 500 falha de DB.

Parameters

No parameters.

Request body

Corpo JSON. O schema detalhado deste endpoint ainda não está tipado na spec; veja a descrição da operação.

application/json

NameTypeRequiredDescription
(corpo)objectno
{}

Responses

200

TBD

401

Sem credencial valida

NameTypeRequiredDescription
errorstringyes

429

Limite de requisições excedido.

NameTypeRequiredDescription
errorstringyes

500

Falha de DB

NameTypeRequiredDescription
errorstringyes

Examples

"Try it" is turned off in this reference. Use the examples with your test credential.

curl

curl -sS -X POST 'https://api.axuz.net/me/notes/renormalize' \
  -H "Authorization: Bearer $AXUZ_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{}'

Node.js

const res = await fetch("https://api.axuz.net/me/notes/renormalize", {
  method: 'POST',
  headers: {
    Authorization: `Bearer ${process.env.AXUZ_TOKEN}`,
    'Content-Type': 'application/json',
  },
  body: JSON.stringify({}),
});
if (!res.ok) throw new Error(`HTTP ${res.status}: ${await res.text()}`);
console.log(await res.json());

Python

import os
import requests

res = requests.request(
    "POST",
    "https://api.axuz.net/me/notes/renormalize",
    headers={
        "Authorization": f"Bearer {os.environ['AXUZ_TOKEN']}",
    },
    json={},
    timeout=30,
)
res.raise_for_status()
print(res.json())