Create tag
curl -X POST "/api/v1/tags" \
-H "Content-Type: application/json" \
-H "Authorization: Bearer YOUR_API_TOKEN (API key (ixk_...))" \
-d '{
"name": "John Doe",
"color": "example_string"
}'
import requests
import json
url = "/api/v1/tags"
headers = {
"Content-Type": "application/json",
"Authorization": "Bearer YOUR_API_TOKEN (API key (ixk_...))"
}
data = {
"name": "John Doe",
"color": "example_string"
}
response = requests.post(url, headers=headers, json=data)
print(response.json())
const response = await fetch("/api/v1/tags", {
method: "POST",
headers: {
"Content-Type": "application/json",
"Authorization": "Bearer YOUR_API_TOKEN (API key (ixk_...))"
},
body: JSON.stringify({
"name": "John Doe",
"color": "example_string"
})
});
const data = await response.json();
console.log(data);
package main
import (
"fmt"
"net/http"
"bytes"
"encoding/json"
)
func main() {
data := []byte(`{
"name": "John Doe",
"color": "example_string"
}`)
req, err := http.NewRequest("POST", "/api/v1/tags", bytes.NewBuffer(data))
if err != nil {
panic(err)
}
req.Header.Set("Content-Type", "application/json")
req.Header.Set("Authorization", "Bearer YOUR_API_TOKEN (API key (ixk_...))")
client := &http.Client{}
resp, err := client.Do(req)
if err != nil {
panic(err)
}
defer resp.Body.Close()
fmt.Println("Response Status:", resp.Status)
}
require 'net/http'
require 'json'
uri = URI('/api/v1/tags')
http = Net::HTTP.new(uri.host, uri.port)
http.use_ssl = true
request = Net::HTTP::Post.new(uri)
request['Content-Type'] = 'application/json'
request['Authorization'] = 'Bearer YOUR_API_TOKEN (API key (ixk_...))'
request.body = '{
"name": "John Doe",
"color": "example_string"
}'
response = http.request(request)
puts response.body
{
"data": {
"id": "123e4567-e89b-12d3-a456-426614174000",
"name": "John Doe",
"color": "example_string"
}
}
{
"error": "Conflict",
"message": "The request conflicts with the current state of the resource",
"code": 409,
"details": "Resource already exists"
}
POST
/tags
POST
Bearer Token (API key (ixk_...))
Bearer Tokenstring
RequiredAPI key from Settings → API. Pass as Authorization: Bearer <key>
API key from Settings → API. Pass as Authorization: Bearer <key>
Content-Typestring
RequiredThe media type of the request body
Options: application/json
Request Preview
Response
Response will appear here after sending the request
Authentication
header
Authorizationstring
RequiredBearer token (API key (ixk_...)). API key from Settings → API. Pass as Authorization: Bearer <key>
Responses
dataobject
idstring
namestring
colorstring
Duplicate name
Was this page helpful?
Last updated 3 weeks ago
Built with Documentation.AI