cURL
curl -X POST https://api.neuraldraft.io/v1/tags \
-H "Authorization: Bearer ndsk_live_yourkey" \
-H "Content-Type: application/json" \
-d '{"name":"breathwork"}'await nd.tags.create({ name: "breathwork" });
requests.post("https://api.neuraldraft.io/v1/tags",
headers={"Authorization": f"Bearer {key}"}, json={"name":"breathwork"})
<?php
$client->post('tags', [
'headers' => ['Authorization' => 'Bearer '.$key],
'json' => ['name' => 'breathwork'],
]);
{
"id": 21,
"name": "breathwork",
"slug": "breathwork"
}{
"type": "https://api.neuraldraft.io/errors/unauthorized",
"title": "Unauthorized",
"status": 401,
"detail": "API key missing or invalid.",
"code": "unauthorized",
"instance": "req_2Nh4PqRsTuVw"
}{
"type": "https://api.neuraldraft.io/errors/conflict",
"title": "Conflict",
"status": 409,
"detail": "A resource with this slug already exists.",
"code": "conflict",
"instance": "req_2Nh4PqRsTuVw"
}Blog
Create a tag
POST
/
tags
cURL
curl -X POST https://api.neuraldraft.io/v1/tags \
-H "Authorization: Bearer ndsk_live_yourkey" \
-H "Content-Type: application/json" \
-d '{"name":"breathwork"}'await nd.tags.create({ name: "breathwork" });
requests.post("https://api.neuraldraft.io/v1/tags",
headers={"Authorization": f"Bearer {key}"}, json={"name":"breathwork"})
<?php
$client->post('tags', [
'headers' => ['Authorization' => 'Bearer '.$key],
'json' => ['name' => 'breathwork'],
]);
{
"id": 21,
"name": "breathwork",
"slug": "breathwork"
}{
"type": "https://api.neuraldraft.io/errors/unauthorized",
"title": "Unauthorized",
"status": 401,
"detail": "API key missing or invalid.",
"code": "unauthorized",
"instance": "req_2Nh4PqRsTuVw"
}{
"type": "https://api.neuraldraft.io/errors/conflict",
"title": "Conflict",
"status": 409,
"detail": "A resource with this slug already exists.",
"code": "conflict",
"instance": "req_2Nh4PqRsTuVw"
}Authorizations
Project API key. Pass as Authorization: Bearer ndsk_live_.... Manage
keys via /projects/me/api-keys. Test-mode keys use
the ndsk_test_ prefix.
Body
application/json
Example:
"breathwork"