POST
/
v1
/
embeddings
Create embeddings
curl --request POST \
  --url https://platform.jobbit.uk/v1/embeddings \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "model": "openai/text-embedding-3-small",
  "input": [
    "Sports massage in Maidstone",
    "Physio for runners in Kent"
  ]
}
'
import requests

url = "https://platform.jobbit.uk/v1/embeddings"

payload = {
"model": "openai/text-embedding-3-small",
"input": ["Sports massage in Maidstone", "Physio for runners in Kent"]
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}

response = requests.post(url, json=payload, headers=headers)

print(response.text)
const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
model: 'openai/text-embedding-3-small',
input: ['Sports massage in Maidstone', 'Physio for runners in Kent']
})
};

fetch('https://platform.jobbit.uk/v1/embeddings', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));
<?php

$curl = curl_init();

curl_setopt_array($curl, [
CURLOPT_URL => "https://platform.jobbit.uk/v1/embeddings",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'model' => 'openai/text-embedding-3-small',
'input' => [
'Sports massage in Maidstone',
'Physio for runners in Kent'
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
package main

import (
"fmt"
"strings"
"net/http"
"io"
)

func main() {

url := "https://platform.jobbit.uk/v1/embeddings"

payload := strings.NewReader("{\n \"model\": \"openai/text-embedding-3-small\",\n \"input\": [\n \"Sports massage in Maidstone\",\n \"Physio for runners in Kent\"\n ]\n}")

req, _ := http.NewRequest("POST", url, payload)

req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")

res, _ := http.DefaultClient.Do(req)

defer res.Body.Close()
body, _ := io.ReadAll(res.Body)

fmt.Println(string(body))

}
HttpResponse<String> response = Unirest.post("https://platform.jobbit.uk/v1/embeddings")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"model\": \"openai/text-embedding-3-small\",\n \"input\": [\n \"Sports massage in Maidstone\",\n \"Physio for runners in Kent\"\n ]\n}")
.asString();
require 'uri'
require 'net/http'

url = URI("https://platform.jobbit.uk/v1/embeddings")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"model\": \"openai/text-embedding-3-small\",\n \"input\": [\n \"Sports massage in Maidstone\",\n \"Physio for runners in Kent\"\n ]\n}"

response = http.request(request)
puts response.read_body
{
  "object": "list",
  "model": "openai/text-embedding-3-small",
  "data": [
    {
      "object": "embedding",
      "index": 0,
      "embedding": [
        0.0123,
        -0.0456,
        0.0789
      ]
    },
    {
      "object": "embedding",
      "index": 1,
      "embedding": [
        0.0101,
        -0.0399,
        0.0814
      ]
    }
  ],
  "usage": {
    "prompt_tokens": 12,
    "total_tokens": 12
  }
}
{
"error": {
"code": "invalid_json",
"message": "the body is not valid JSON",
"request_id": "5d3f0b7c8a2e4e19b6c47a90d1e2f3a4"
}
}
{
"error": {
"code": "invalid_key",
"message": "the API key is missing or invalid",
"request_id": "5d3f0b7c8a2e4e19b6c47a90d1e2f3a4"
}
}
{
"error": {
"code": "insufficient_credits",
"message": "not enough credits to run this request",
"request_id": "5d3f0b7c8a2e4e19b6c47a90d1e2f3a4"
}
}
{
"error": {
"code": "insufficient_scope",
"message": "this key does not have the deploy:write permission",
"details": {
"required": "deploy:write"
},
"request_id": "5d3f0b7c8a2e4e19b6c47a90d1e2f3a4"
}
}
{
"error": {
"code": "payload_too_large",
"message": "the request body is larger than 26214400 bytes",
"request_id": "5d3f0b7c8a2e4e19b6c47a90d1e2f3a4"
}
}
{
"error": {
"code": "rate_limited",
"message": "too many read requests, retry in 4 s",
"details": {
"group": "read",
"limit": 120,
"window_seconds": 60
},
"request_id": "5d3f0b7c8a2e4e19b6c47a90d1e2f3a4"
}
}

Authorizations

Authorization
string
header
required

An API key from Settings → API keys, sent as Authorization: Bearer jb_live_…

Body

application/json
input
required

One string or a list of up to 2,048 strings, 2,000,000 characters in all. Empty strings are refused.

model
string

An embedding model id from GET /v1/embeddings/models. Defaults to openai/text-embedding-3-small.

dimensions
integer

Shorten the vectors, for models that allow it.

encoding_format
string

float or base64.

user
string

Your own id for the end user.

Response

The embeddings.

An OpenAI-compatible embeddings list.

data
object[]
required

One embedding per input.

object
string

Always list.

model
string

The model used.

usage
object