POST
/
models
/
v2
/
BilelDJ
/
clip-hugging-face-finetuned
curl --request POST \
  --url https://api.bytez.com/models/v2/BilelDJ/clip-hugging-face-finetuned \
  --header 'Authorization: <api-key>' \
  --header 'Content-Type: application/json' \
  --data '{
  "candidate_labels": [
    "squid",
    "octopus",
    "human",
    "cat"
  ],
  "url": "https://ocean.si.edu/sites/default/files/styles/3_2_largest/public/2023-11/Screen_Shot_2018-04-16_at_1_42_56_PM.png.webp?itok=Icvi-ek9",
  "base64": "/9j/4AAQSkZJRgABAQAAAQABAAD..."
}'
{
  "output": [
    {
      "score": 0.838,
      "label": "octopus"
    }
  ]
}

Authorizations

Authorization
string
header
required

Provide your API key as Key your-key-here in the Authorization header.

Body

application/json
url
string
required

URL of the image.

Example:

"https://ocean.si.edu/sites/default/files/styles/3_2_largest/public/2023-11/Screen_Shot_2018-04-16_at_1_42_56_PM.png.webp?itok=Icvi-ek9"

candidate_labels
string[]

Labels for classification.

Example:
["squid", "octopus", "human", "cat"]
base64
string

Base64-encoded image data.

Example:

"/9j/4AAQSkZJRgABAQAAAQABAAD..."

Response

200 - application/json
Successful response with classification results.
output
any[]

Classification results.