API reference

MyJev API

One endpoint, three question types. Every request carries your API key.

Authentication

Send your key in the X-API-Key header. Keys are created in the console and shown once.

X-API-Key: mjk_xxxxxxxxxxxxxxxxxxxxxxxx

Request

curl -s https://api.myjev.net/v1/systemone \
  -H "X-API-Key: $MYJEV_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "state": "def get_user(user_id):\n    return db.query(User).filter(User.id == user_id).first()",
    "questions": {
      "language": {"type": "choice", "instructions": "What programming language is this code written in?",
                   "options": ["python", "javascript", "typescript", "go", "rust", "other"]}
    }
  }'

Three question types

choice

{
  "state": "def get_user(user_id):\n    return db.query(User).filter(User.id == user_id).first()",
  "questions": {
    "q": {
      "type": "choice",
      "instructions": "What programming language is this code written in?",
      "options": [
        "python",
        "javascript",
        "typescript",
        "go",
        "rust",
        "other"
      ]
    }
  }
}

noul

{
  "state": "I have asked three times now. Put me through to a real person.",
  "questions": {
    "q": {
      "type": "noul",
      "instructions": "Does the customer want a human agent?"
    }
  }
}

score

{
  "state": "Where is my refund? This is the second time I have written to you.",
  "questions": {
    "q": {
      "type": "score",
      "instructions": "How angry is the customer?",
      "levels": [
        "calm",
        "mildly annoyed",
        "frustrated but civil",
        "angry, strong language or threatening to leave"
      ]
    }
  }
}

Response

{
  "answers": {
    "<question name>": {
      "choice": "...",            // choice questions
      "probabilities": {"...": 0.0},
      "confidence": 0.0
    },
    "<noul name>":   {"noul": 0.0},          // probability of yes
    "<score name>":  {"score": 1.64, "level": "...", "probabilities": {}, "confidence": 0.0}
  },
  "model": "...",
  "temperature": 1.411,
  "latency_ms": 147.2
}

Question types

TypeFieldsAnswer
choiceoptions (2–26)best option + per-option probabilities
noul—probability that the answer is yes
scorelevels (low → high)expected level, most likely level, probabilities

Limits