Skip to main content

Documentation Index

Fetch the complete documentation index at: https://docs.orbit.devotel.io/llms.txt

Use this file to discover all available pages before exploring further.

CDP API

CDP endpoints exposed by the Devotel CPaaS API Base path: /api/v1/cdp/traits/auto-derive Endpoint count: 1

Auto-derive contact trait tags via LLM

POST /api/v1/cdp/traits/auto-derive
Reads the contact’s 30-day event mix + deterministic signals and asks the LLM to synthesise an open-ended kebab-case tag set (high-LTV, churn-risk, engaged-7d, …). The output REPLACES (not appends to) the persisted contact_scores.derived_trait_tags array. Pre-launch: synthesiser-only on-demand surface; segmentation-engine sync ships in a follow-up wave.
contact_id
string
required
Contact identifier. The handler reads the contact’s 30-day event mix + deterministic signals from the tenant schema before invoking the LLM.
max_tags
integer
Soft cap on the tags the LLM proposes. Server-side clamping prevents a chatty model from blowing the contact-detail panel layout.
cURL
curl -X POST "https://api.orbit.devotel.io/api/v1/cdp/traits/auto-derive" \
  -H "X-API-Key: dv_live_sk_your_key_here" \
  -H "Content-Type: application/json" \
  -d '{
  "contact_id": "string"
}'
Node.js
import { Orbit } from '@devotel/orbit-sdk'

const orbit = new Orbit({
  apiKey: process.env.ORBIT_API_KEY!,
})

const res = await fetch('https://api.orbit.devotel.io/api/v1/cdp/traits/auto-derive', {
  method: 'POST',
  headers: {
    'X-API-Key': process.env.ORBIT_API_KEY!,
    'Content-Type': 'application/json',
  },
  body: JSON.stringify({
  "contact_id": "string"
}),
})
console.log(await res.json())
Python
import os, requests

headers = {"X-API-Key": os.environ["ORBIT_API_KEY"]}
headers["Content-Type"] = "application/json"
r = requests.post("https://api.orbit.devotel.io/api/v1/cdp/traits/auto-derive", headers=headers, json={
  "contact_id": "string"
})
print(r.json())
Go
package main

import (
	"bytes"
	"net/http"
	"os"
)

func main() {
	req, _ := http.NewRequest("POST", "https://api.orbit.devotel.io/api/v1/cdp/traits/auto-derive", bytes.NewBuffer([]byte(`{
  "contact_id": "string"
}`)))
	req.Header.Set("X-API-Key", os.Getenv("ORBIT_API_KEY"))
	req.Header.Set("Content-Type", "application/json")
	http.DefaultClient.Do(req)
}
Ruby
require 'net/http'
require 'json'

uri = URI('https://api.orbit.devotel.io/api/v1/cdp/traits/auto-derive')
req = Net::HTTP::Post.new(uri)
req['X-API-Key'] = ENV['ORBIT_API_KEY']
req['Content-Type'] = 'application/json'
req.body = {
  "contact_id": "string"
}.to_json
res = Net::HTTP.start(uri.host, uri.port, use_ssl: true) { |h| h.request(req) }
puts res.body
PHP
<?php
$ch = curl_init('https://api.orbit.devotel.io/api/v1/cdp/traits/auto-derive');
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'POST');
curl_setopt($ch, CURLOPT_HTTPHEADER, [
  'X-API-Key: ' . getenv('ORBIT_API_KEY'),
  'Content-Type: application/json',
]);
curl_setopt($ch, CURLOPT_POSTFIELDS, <<<JSON
{
  "contact_id": "string"
}
JSON);
echo curl_exec($ch);