Skip to content
Support

Entretiens · Questionnaires ​

Créer un entretien, le suivre, relancer le candidat et récupérer son résultat.

Chaque appel porte votre clé et l'id du recruteur : voir Authentification et clés. Les listes, les erreurs et les quotas suivent les Conventions. Les descriptions ci-dessous sont celles du code : elles sont en anglais, comme les identifiants techniques.

Les exemples lisent votre clé, l'id du recruteur et les identifiants dans des variables d'environnement : CLE, RECRUTEUR_ID, puis AGENT_ID, INTERVIEW_ID… Une réponse d'exemple montre les champs principaux : l'API peut en renvoyer d'autres. Tous ces appels sont aussi dans la collection Postman.

Créer sans doublon ​

Cette règle vaut pour trois appels : Créer un entretien, Créer des entretiens en lot et Créer un questionnaire.

Si un appel de création part deux fois (délai dépassé, relance automatique…), aucun doublon n'est créé et le candidat ne reçoit pas de seconde invitation.

Un appel est un doublon quand le même candidat a déjà, avec le même agent virtuel, un entretien pas encore commencé et créé il y a moins de 5 minutes. Le candidat est reconnu à son e-mail ; pour un questionnaire, à son e-mail ou à son téléphone.

CréationRéponse sur un doublon
Un entretien, un questionnaireerreur 409, dont details donne l'identifiant de l'entretien existant
Une liste de candidats201 : le doublon est ignoré, les autres sont créés ; la réponse ne contient que les entretiens créés
json
{
  "statusCode": 409,
  "code": "CONFLICT",
  "message": "This candidate already has a pending interview with this agent.",
  "details": [
    { "field": "candidateEmail", "message": "Already invited: interview b3e7d1a4-5c92-4f6e-8d0a-2a9f6c1e7b48." }
  ],
  "requestId": "87309bff-2a18-4455-8e19-9439311446b1"
}

Sur une 409 après un délai dépassé, votre premier appel a donc bien créé l'entretien : reprenez son identifiant dans details plutôt que de réessayer.

Un second entretien reste toujours possible : un deuxième tour, un lien renvoyé plus tard, ou un autre agent virtuel passent normalement.

Lister les entretiens ​

GET /partner/interviews

List interviews

Paginated: page from 1, pageSize up to 100. See « Listes » in the conventions.

Paramètres

NomEmplacementTypeRequisDescription
pagequeryintegernonDéfaut : 1.
pageSizequeryintegernonDéfaut : 20.
searchquerystringnon
statusquerypending · in_progress · completed · failed · voicemail · no_answer · refused · not_available · recruiter_requested · condition_not_met · archivednon
agentIdquerystring (uuid)non
organizationIdquerystring (uuid)non
batchIdquerystringnon
requestedByUserIdquerystring (uuid)non
clientNamequerystringnon
completedFromquerystring (date)nonYYYY-MM-DD, with status=completed only
completedToquerystring (date)nonYYYY-MM-DD, with status=completed only
testsOnlyquerytrue · falsenonDéfaut : false.
sortquerycreatedAt · completedAt · expirationAt · scorenonDéfaut : createdAt.
orderqueryasc · descnonDéfaut : desc.

Réponses

CodeDescription
200
400Invalid request: details lists the fields at fault. Also an unsupported X-API-Version.
401Missing, revoked or expired API key, or missing or unknown acting user.
403Unknown API key, or the acting user may not act with this key or lacks the role.
404Not found, or not in the organizations of your key.
429Quota of the key exceeded: the Retry-After header gives the seconds to wait.
500Unexpected error: quote the requestId to the support.

Exemple

sh
curl "https://api.smart-interview.ai/partner/interviews?agentId=$AGENT_ID&status=pending" \
  -H "x-api-key: $CLE" \
  -H "x-acting-user-id: $RECRUTEUR_ID"
php
<?php
$curl = curl_init('https://api.smart-interview.ai/partner/interviews?agentId=' . getenv('AGENT_ID') . '&status=pending');
curl_setopt_array($curl, [
    CURLOPT_HTTPHEADER => [
        'x-api-key: ' . getenv('CLE'),
        'x-acting-user-id: ' . getenv('RECRUTEUR_ID'),
    ],
    CURLOPT_RETURNTRANSFER => true,
]);
$response = curl_exec($curl);
echo curl_getinfo($curl, CURLINFO_RESPONSE_CODE), PHP_EOL, $response, PHP_EOL;
js
const response = await fetch(`https://api.smart-interview.ai/partner/interviews?agentId=${process.env.AGENT_ID}&status=pending`, {
  headers: {
    'x-api-key': process.env.CLE,
    'x-acting-user-id': process.env.RECRUTEUR_ID,
  },
});
console.log(response.status, await response.json());
python
import os

import requests

response = requests.get(
    f"https://api.smart-interview.ai/partner/interviews?agentId={os.environ['AGENT_ID']}&status=pending",
    headers={
        "x-api-key": os.environ["CLE"],
        "x-acting-user-id": os.environ["RECRUTEUR_ID"],
    },
)
print(response.status_code, response.json())

Réponse 200 :

json
{
  "data": [
    {
      "id": "b3e7d1a4-5c92-4f6e-8d0a-2a9f6c1e7b48",
      "status": "pending",
      "purpose": "recruitment",
      "firstname": "Camille",
      "lastname": "Martin",
      "candidateEmail": "camille.martin@example.com",
      "phone": null,
      "agentId": "6f1c2a9e-3b7d-4e58-9a21-7c4d8e0b5f13",
      "organizationId": "e4a8c2f1-7d3b-4b9e-a6c5-1f0d9e8b2a37",
      "requestedByUserId": "9d2f6b1e-4a8c-4e7d-b3f5-6c0a1e9d8b24",
      "candidateData": null,
      "batchId": null,
      "batchName": null,
      "feedbackRating": null,
      "feedbackComment": null,
      "resendCount": 0,
      "isTesting": false,
      "allowedInterviewTypes": [
        "video",
        "phone"
      ],
      "transcript": null,
      "metadata": null,
      "analysis": null,
      "agentData": {
        "skills": [
          {
            "title": "Mise en place & organisation",
            "description": "Organiser son poste et préparer les ingrédients avant le service",
            "weight": 40
          }
        ],
        "methodologies": {
          "id": "STAR",
          "title": "Méthode STAR",
          "description": "Situation, tâche, action, résultat",
          "criteria": [
            {
              "criterion": "Situation",
              "expected": "Décrit un contexte précis"
            }
          ]
        },
        "customConditions": [
          {
            "title": "Horaires",
            "description": "Le candidat est-il disponible le week-end ?",
            "isMandatory": true
          }
        ]
      },
      "createdAt": "2026-11-23T10:00:00.000Z",
      "completedAt": null,
      "expirationAt": null,
      "updatedAt": "2026-11-23T10:00:00.000Z",
      "deletedAt": null
    }
  ],
  "page": 1,
  "pageSize": 20,
  "total": 1,
  "hasMore": false
}

WARNING

Les champs du résultat, sauf version, agentTitle, shareLink et conditionInterruption : demandez le lien avec share-link. metadata, analysis et agentData sont hors contrat ; transcript vaut null, sauf si votre organisation a demandé l'envoi de la transcription intégrale.

Créer un entretien ​

POST /partner/interviews

Create an interview and invite the candidate

organizationId and requestedByUserId are replaced by those of the acting user.

Corps de la requête

ChampTypeRequisDescription
agentIdstringouiThe agent ID (ex. 6f1c2a9e-3b7d-4e58-9a21-7c4d8e0b5f13)
firstnamestringouiThe candidate first name (ex. Camille)
candidateEmailstringouiThe candidate email (ex. camille.martin@example.com)
lastnamestringouiThe candidate last name (ex. Martin)
phonestringnonThe candidate phone number (ex. +33639980100)
requestedByUserIdstringouiRequired, but replaced by the acting user with an API key (ex. -)
organizationIdstringouiRequired, but replaced by the organization of the acting user with an API key (ex. -)
expirationAtstringnonExpiration date and time (ISO 8601) when the interview link becomes invalid (ex. 2026-12-31T23:00:00.000Z)
batchNamestringnonOptional custom name for the batch (ex. Saison été 2026)
triggerCallbooleannonWhether to trigger an outbound call instead of sending email (ex. false)
sendMessagebooleannonWhether to send a WhatsApp/SMS message instead of sending email (ex. false)
allowedInterviewTypesstring[]nonAllowed interview types. Can be "video", "phone", or both (ex. video,phone)
remindersobjectnonCustom reminder schedules. If not provided, default reminders will be created

Réponses

CodeDescription
201Interview created
400Invalid request: details lists the fields at fault. Also an unsupported X-API-Version.
401Missing, revoked or expired API key, or missing or unknown acting user.
403Unknown API key, or the acting user may not act with this key or lacks the role.
404Not found, or not in the organizations of your key.
409Duplicate: this candidate already has a pending interview with this agent, created less than 5 minutes ago. details gives its id. Nothing is created nor sent.
429Quota of the key exceeded: the Retry-After header gives the seconds to wait.
500Unexpected error: quote the requestId to the support.

Exemple

sh
curl -X POST "https://api.smart-interview.ai/partner/interviews" \
  -H "x-api-key: $CLE" \
  -H "x-acting-user-id: $RECRUTEUR_ID" \
  -H "Content-Type: application/json" \
  --data @- <<EOF
{
  "agentId": "$AGENT_ID",
  "firstname": "Camille",
  "lastname": "Martin",
  "candidateEmail": "camille.martin@example.com",
  "organizationId": "-",
  "requestedByUserId": "-"
}
EOF
php
<?php
$curl = curl_init('https://api.smart-interview.ai/partner/interviews');
curl_setopt_array($curl, [
    CURLOPT_CUSTOMREQUEST => 'POST',
    CURLOPT_HTTPHEADER => [
        'x-api-key: ' . getenv('CLE'),
        'x-acting-user-id: ' . getenv('RECRUTEUR_ID'),
        'Content-Type: application/json',
    ],
    CURLOPT_POSTFIELDS => json_encode([
        'agentId' => getenv('AGENT_ID'),
        'firstname' => 'Camille',
        'lastname' => 'Martin',
        'candidateEmail' => 'camille.martin@example.com',
        'organizationId' => '-',
        'requestedByUserId' => '-',
    ]),
    CURLOPT_RETURNTRANSFER => true,
]);
$response = curl_exec($curl);
echo curl_getinfo($curl, CURLINFO_RESPONSE_CODE), PHP_EOL, $response, PHP_EOL;
js
const response = await fetch('https://api.smart-interview.ai/partner/interviews', {
  method: 'POST',
  headers: {
    'x-api-key': process.env.CLE,
    'x-acting-user-id': process.env.RECRUTEUR_ID,
    'Content-Type': 'application/json',
  },
  body: JSON.stringify({
    agentId: process.env.AGENT_ID,
    firstname: 'Camille',
    lastname: 'Martin',
    candidateEmail: 'camille.martin@example.com',
    organizationId: '-',
    requestedByUserId: '-',
  }),
});
console.log(response.status, await response.json());
python
import os

import requests

response = requests.post(
    "https://api.smart-interview.ai/partner/interviews",
    headers={
        "x-api-key": os.environ["CLE"],
        "x-acting-user-id": os.environ["RECRUTEUR_ID"],
    },
    json={
        "agentId": os.environ["AGENT_ID"],
        "firstname": "Camille",
        "lastname": "Martin",
        "candidateEmail": "camille.martin@example.com",
        "organizationId": "-",
        "requestedByUserId": "-",
    },
)
print(response.status_code, response.json())

Réponse 201 :

json
{
  "id": "b3e7d1a4-5c92-4f6e-8d0a-2a9f6c1e7b48",
  "status": "pending",
  "purpose": "recruitment",
  "firstname": "Camille",
  "lastname": "Martin",
  "candidateEmail": "camille.martin@example.com",
  "phone": null,
  "agentId": "6f1c2a9e-3b7d-4e58-9a21-7c4d8e0b5f13",
  "organizationId": "e4a8c2f1-7d3b-4b9e-a6c5-1f0d9e8b2a37",
  "requestedByUserId": "9d2f6b1e-4a8c-4e7d-b3f5-6c0a1e9d8b24",
  "candidateData": null,
  "batchId": null,
  "batchName": null,
  "feedbackRating": null,
  "feedbackComment": null,
  "resendCount": 0,
  "isTesting": false,
  "allowedInterviewTypes": [
    "video",
    "phone"
  ],
  "transcript": null,
  "metadata": null,
  "analysis": null,
  "agentData": {
    "skills": [
      {
        "title": "Mise en place & organisation",
        "description": "Organiser son poste et préparer les ingrédients avant le service",
        "weight": 40
      }
    ],
    "methodologies": {
      "id": "STAR",
      "title": "Méthode STAR",
      "description": "Situation, tâche, action, résultat",
      "criteria": [
        {
          "criterion": "Situation",
          "expected": "Décrit un contexte précis"
        }
      ]
    },
    "customConditions": [
      {
        "title": "Horaires",
        "description": "Le candidat est-il disponible le week-end ?",
        "isMandatory": true
      }
    ]
  },
  "createdAt": "2026-11-23T10:00:00.000Z",
  "completedAt": null,
  "expirationAt": null,
  "updatedAt": "2026-11-23T10:00:00.000Z",
  "deletedAt": null
}

WARNING

Soumis à la règle Créer sans doublon : un appel envoyé deux fois ne crée pas de second entretien.

Obtenir le lien d'invitation ​

POST /partner/interviews/{id}/invitation-link

Generate the invitation link of an interview

Paramètres

NomEmplacementTypeRequisDescription
idpathstringoui

Réponses

CodeDescription
200Return the invitation URL and its code
400Invalid request: details lists the fields at fault. Also an unsupported X-API-Version.
401Missing, revoked or expired API key, or missing or unknown acting user.
403Unknown API key, or the acting user may not act with this key or lacks the role.
404Not found, or not in the organizations of your key.
429Quota of the key exceeded: the Retry-After header gives the seconds to wait.
500Unexpected error: quote the requestId to the support.

Exemple

sh
curl -X POST "https://api.smart-interview.ai/partner/interviews/$INTERVIEW_ID/invitation-link" \
  -H "x-api-key: $CLE" \
  -H "x-acting-user-id: $RECRUTEUR_ID"
php
<?php
$curl = curl_init('https://api.smart-interview.ai/partner/interviews/' . getenv('INTERVIEW_ID') . '/invitation-link');
curl_setopt_array($curl, [
    CURLOPT_CUSTOMREQUEST => 'POST',
    CURLOPT_HTTPHEADER => [
        'x-api-key: ' . getenv('CLE'),
        'x-acting-user-id: ' . getenv('RECRUTEUR_ID'),
    ],
    CURLOPT_RETURNTRANSFER => true,
]);
$response = curl_exec($curl);
echo curl_getinfo($curl, CURLINFO_RESPONSE_CODE), PHP_EOL, $response, PHP_EOL;
js
const response = await fetch(`https://api.smart-interview.ai/partner/interviews/${process.env.INTERVIEW_ID}/invitation-link`, {
  method: 'POST',
  headers: {
    'x-api-key': process.env.CLE,
    'x-acting-user-id': process.env.RECRUTEUR_ID,
  },
});
console.log(response.status, await response.json());
python
import os

import requests

response = requests.post(
    f"https://api.smart-interview.ai/partner/interviews/{os.environ['INTERVIEW_ID']}/invitation-link",
    headers={
        "x-api-key": os.environ["CLE"],
        "x-acting-user-id": os.environ["RECRUTEUR_ID"],
    },
)
print(response.status_code, response.json())

Réponse 200 :

json
{
  "url": "https://app.smart-interview.ai/candidates?code=Xk4pQ7wNz",
  "code": "Xk4pQ7wNz"
}

Renvoyer l'invitation par e-mail ​

POST /partner/interviews/{id}/resend-email

Resend interview invitation email to candidate

Paramètres

NomEmplacementTypeRequisDescription
idpathstringoui

Réponses

CodeDescription
200Email successfully resent
400Invalid request: details lists the fields at fault. Also an unsupported X-API-Version.
401Missing, revoked or expired API key, or missing or unknown acting user.
403Unknown API key, or the acting user may not act with this key or lacks the role.
404Not found, or not in the organizations of your key.
429Quota of the key exceeded: the Retry-After header gives the seconds to wait.
500Unexpected error: quote the requestId to the support.

Exemple

sh
curl -X POST "https://api.smart-interview.ai/partner/interviews/$INTERVIEW_ID/resend-email" \
  -H "x-api-key: $CLE" \
  -H "x-acting-user-id: $RECRUTEUR_ID"
php
<?php
$curl = curl_init('https://api.smart-interview.ai/partner/interviews/' . getenv('INTERVIEW_ID') . '/resend-email');
curl_setopt_array($curl, [
    CURLOPT_CUSTOMREQUEST => 'POST',
    CURLOPT_HTTPHEADER => [
        'x-api-key: ' . getenv('CLE'),
        'x-acting-user-id: ' . getenv('RECRUTEUR_ID'),
    ],
    CURLOPT_RETURNTRANSFER => true,
]);
$response = curl_exec($curl);
echo curl_getinfo($curl, CURLINFO_RESPONSE_CODE), PHP_EOL, $response, PHP_EOL;
js
const response = await fetch(`https://api.smart-interview.ai/partner/interviews/${process.env.INTERVIEW_ID}/resend-email`, {
  method: 'POST',
  headers: {
    'x-api-key': process.env.CLE,
    'x-acting-user-id': process.env.RECRUTEUR_ID,
  },
});
console.log(response.status, await response.json());
python
import os

import requests

response = requests.post(
    f"https://api.smart-interview.ai/partner/interviews/{os.environ['INTERVIEW_ID']}/resend-email",
    headers={
        "x-api-key": os.environ["CLE"],
        "x-acting-user-id": os.environ["RECRUTEUR_ID"],
    },
)
print(response.status_code, response.json())

Réponse 200 :

json
{
  "message": "Email successfully resent"
}

Renvoyer l'invitation par WhatsApp ​

POST /partner/interviews/{id}/resend-message

Resend interview invitation message (WhatsApp) to candidate

Paramètres

NomEmplacementTypeRequisDescription
idpathstringoui

Réponses

CodeDescription
200Message successfully resent
400Invalid request: details lists the fields at fault. Also an unsupported X-API-Version.
401Missing, revoked or expired API key, or missing or unknown acting user.
403Unknown API key, or the acting user may not act with this key or lacks the role.
404Not found, or not in the organizations of your key.
429Quota of the key exceeded: the Retry-After header gives the seconds to wait.
500Unexpected error: quote the requestId to the support.

Exemple

sh
curl -X POST "https://api.smart-interview.ai/partner/interviews/$INTERVIEW_ID/resend-message" \
  -H "x-api-key: $CLE" \
  -H "x-acting-user-id: $RECRUTEUR_ID"
php
<?php
$curl = curl_init('https://api.smart-interview.ai/partner/interviews/' . getenv('INTERVIEW_ID') . '/resend-message');
curl_setopt_array($curl, [
    CURLOPT_CUSTOMREQUEST => 'POST',
    CURLOPT_HTTPHEADER => [
        'x-api-key: ' . getenv('CLE'),
        'x-acting-user-id: ' . getenv('RECRUTEUR_ID'),
    ],
    CURLOPT_RETURNTRANSFER => true,
]);
$response = curl_exec($curl);
echo curl_getinfo($curl, CURLINFO_RESPONSE_CODE), PHP_EOL, $response, PHP_EOL;
js
const response = await fetch(`https://api.smart-interview.ai/partner/interviews/${process.env.INTERVIEW_ID}/resend-message`, {
  method: 'POST',
  headers: {
    'x-api-key': process.env.CLE,
    'x-acting-user-id': process.env.RECRUTEUR_ID,
  },
});
console.log(response.status, await response.json());
python
import os

import requests

response = requests.post(
    f"https://api.smart-interview.ai/partner/interviews/{os.environ['INTERVIEW_ID']}/resend-message",
    headers={
        "x-api-key": os.environ["CLE"],
        "x-acting-user-id": os.environ["RECRUTEUR_ID"],
    },
)
print(response.status_code, response.json())

Réponse 200 :

json
{
  "message": "Message successfully resent"
}

WARNING

Envoie un vrai message WhatsApp au candidat, sur le téléphone de l’entretien : un entretien sans téléphone est refusé (400).

Redonner une chance au candidat ​

POST /partner/interviews/{id}/retry

Give candidate another chance by resetting interview to pending

Paramètres

NomEmplacementTypeRequisDescription
idpathstringoui

Réponses

CodeDescription
200Interview successfully reset and email sent
400Invalid request: details lists the fields at fault. Also an unsupported X-API-Version.
401Missing, revoked or expired API key, or missing or unknown acting user.
403Unknown API key, or the acting user may not act with this key or lacks the role.
404Not found, or not in the organizations of your key.
429Quota of the key exceeded: the Retry-After header gives the seconds to wait.
500Unexpected error: quote the requestId to the support.

Exemple

sh
curl -X POST "https://api.smart-interview.ai/partner/interviews/$INTERVIEW_ID/retry" \
  -H "x-api-key: $CLE" \
  -H "x-acting-user-id: $RECRUTEUR_ID"
php
<?php
$curl = curl_init('https://api.smart-interview.ai/partner/interviews/' . getenv('INTERVIEW_ID') . '/retry');
curl_setopt_array($curl, [
    CURLOPT_CUSTOMREQUEST => 'POST',
    CURLOPT_HTTPHEADER => [
        'x-api-key: ' . getenv('CLE'),
        'x-acting-user-id: ' . getenv('RECRUTEUR_ID'),
    ],
    CURLOPT_RETURNTRANSFER => true,
]);
$response = curl_exec($curl);
echo curl_getinfo($curl, CURLINFO_RESPONSE_CODE), PHP_EOL, $response, PHP_EOL;
js
const response = await fetch(`https://api.smart-interview.ai/partner/interviews/${process.env.INTERVIEW_ID}/retry`, {
  method: 'POST',
  headers: {
    'x-api-key': process.env.CLE,
    'x-acting-user-id': process.env.RECRUTEUR_ID,
  },
});
console.log(response.status, await response.json());
python
import os

import requests

response = requests.post(
    f"https://api.smart-interview.ai/partner/interviews/{os.environ['INTERVIEW_ID']}/retry",
    headers={
        "x-api-key": os.environ["CLE"],
        "x-acting-user-id": os.environ["RECRUTEUR_ID"],
    },
)
print(response.status_code, response.json())

Réponse 200 :

json
{
  "message": "Interview reset successfully"
}

WARNING

Seulement sur un entretien terminé : un entretien en attente est refusé (400).

Partager le compte rendu ​

POST /partner/interviews/{id}/share-link

Generate public recap share link

Paramètres

NomEmplacementTypeRequisDescription
idpathstringoui

Réponses

CodeDescription
200Return the public recap URL and its code
400Invalid request: details lists the fields at fault. Also an unsupported X-API-Version.
401Missing, revoked or expired API key, or missing or unknown acting user.
403Unknown API key, or the acting user may not act with this key or lacks the role.
404Not found, or not in the organizations of your key.
429Quota of the key exceeded: the Retry-After header gives the seconds to wait.
500Unexpected error: quote the requestId to the support.

Exemple

sh
curl -X POST "https://api.smart-interview.ai/partner/interviews/$INTERVIEW_ID/share-link" \
  -H "x-api-key: $CLE" \
  -H "x-acting-user-id: $RECRUTEUR_ID"
php
<?php
$curl = curl_init('https://api.smart-interview.ai/partner/interviews/' . getenv('INTERVIEW_ID') . '/share-link');
curl_setopt_array($curl, [
    CURLOPT_CUSTOMREQUEST => 'POST',
    CURLOPT_HTTPHEADER => [
        'x-api-key: ' . getenv('CLE'),
        'x-acting-user-id: ' . getenv('RECRUTEUR_ID'),
    ],
    CURLOPT_RETURNTRANSFER => true,
]);
$response = curl_exec($curl);
echo curl_getinfo($curl, CURLINFO_RESPONSE_CODE), PHP_EOL, $response, PHP_EOL;
js
const response = await fetch(`https://api.smart-interview.ai/partner/interviews/${process.env.INTERVIEW_ID}/share-link`, {
  method: 'POST',
  headers: {
    'x-api-key': process.env.CLE,
    'x-acting-user-id': process.env.RECRUTEUR_ID,
  },
});
console.log(response.status, await response.json());
python
import os

import requests

response = requests.post(
    f"https://api.smart-interview.ai/partner/interviews/{os.environ['INTERVIEW_ID']}/share-link",
    headers={
        "x-api-key": os.environ["CLE"],
        "x-acting-user-id": os.environ["RECRUTEUR_ID"],
    },
)
print(response.status_code, response.json())

Réponse 200 :

json
{
  "url": "https://app.smart-interview.ai/interviews/recap/b3e7d1a4-5c92-4f6e-8d0a-2a9f6c1e7b48?code=Rt8vL2mQc",
  "code": "Rt8vL2mQc"
}

Créer des entretiens en lot ​

POST /partner/interviews/batch

Create multiple interviews in a batch

Corps de la requête

ChampTypeRequisDescription
agentIdstringouiThe agent ID (ex. 6f1c2a9e-3b7d-4e58-9a21-7c4d8e0b5f13)
requestedByUserIdstringouiRequired, but replaced by the acting user with an API key (ex. -)
organizationIdstringouiRequired, but replaced by the organization of the acting user with an API key (ex. -)
expirationAtstringnonExpiration date and time (ISO 8601) when the interview link becomes invalid (ex. 2026-12-31T23:00:00.000Z)
candidatesCandidateDto[]ouiArray of candidates for the batch
batchNamestringnonOptional custom name for the batch (ex. Saison été 2026)
sendEmailbooleannonSend invitations via email instead of WhatsApp message (ex. false)
allowedInterviewTypesstring[]nonAllowed interview types. Can be "video", "phone", or both (ex. video,phone)
remindersobjectnonCustom reminder schedules. If not provided, default reminders will be created

Réponses

CodeDescription
201Return created interviews with batch ID
400Invalid request: details lists the fields at fault. Also an unsupported X-API-Version.
401Missing, revoked or expired API key, or missing or unknown acting user.
403Unknown API key, or the acting user may not act with this key or lacks the role.
404Not found, or not in the organizations of your key.
429Quota of the key exceeded: the Retry-After header gives the seconds to wait.
500Unexpected error: quote the requestId to the support.

Exemple

sh
curl -X POST "https://api.smart-interview.ai/partner/interviews/batch" \
  -H "x-api-key: $CLE" \
  -H "x-acting-user-id: $RECRUTEUR_ID" \
  -H "Content-Type: application/json" \
  --data @- <<EOF
{
  "agentId": "$AGENT_ID",
  "organizationId": "-",
  "requestedByUserId": "-",
  "batchName": "Saison été 2026",
  "sendEmail": true,
  "candidates": [
    {
      "firstname": "Lucas",
      "lastname": "Petit",
      "candidateEmail": "lucas.petit@example.com"
    },
    {
      "firstname": "Inès",
      "lastname": "Moreau",
      "candidateEmail": "ines.moreau@example.com"
    }
  ]
}
EOF
php
<?php
$curl = curl_init('https://api.smart-interview.ai/partner/interviews/batch');
curl_setopt_array($curl, [
    CURLOPT_CUSTOMREQUEST => 'POST',
    CURLOPT_HTTPHEADER => [
        'x-api-key: ' . getenv('CLE'),
        'x-acting-user-id: ' . getenv('RECRUTEUR_ID'),
        'Content-Type: application/json',
    ],
    CURLOPT_POSTFIELDS => json_encode([
        'agentId' => getenv('AGENT_ID'),
        'organizationId' => '-',
        'requestedByUserId' => '-',
        'batchName' => 'Saison été 2026',
        'sendEmail' => true,
        'candidates' => [
            [
                'firstname' => 'Lucas',
                'lastname' => 'Petit',
                'candidateEmail' => 'lucas.petit@example.com',
            ],
            [
                'firstname' => 'Inès',
                'lastname' => 'Moreau',
                'candidateEmail' => 'ines.moreau@example.com',
            ],
        ],
    ]),
    CURLOPT_RETURNTRANSFER => true,
]);
$response = curl_exec($curl);
echo curl_getinfo($curl, CURLINFO_RESPONSE_CODE), PHP_EOL, $response, PHP_EOL;
js
const response = await fetch('https://api.smart-interview.ai/partner/interviews/batch', {
  method: 'POST',
  headers: {
    'x-api-key': process.env.CLE,
    'x-acting-user-id': process.env.RECRUTEUR_ID,
    'Content-Type': 'application/json',
  },
  body: JSON.stringify({
    agentId: process.env.AGENT_ID,
    organizationId: '-',
    requestedByUserId: '-',
    batchName: 'Saison été 2026',
    sendEmail: true,
    candidates: [
      {
        firstname: 'Lucas',
        lastname: 'Petit',
        candidateEmail: 'lucas.petit@example.com',
      },
      {
        firstname: 'Inès',
        lastname: 'Moreau',
        candidateEmail: 'ines.moreau@example.com',
      },
    ],
  }),
});
console.log(response.status, await response.json());
python
import os

import requests

response = requests.post(
    "https://api.smart-interview.ai/partner/interviews/batch",
    headers={
        "x-api-key": os.environ["CLE"],
        "x-acting-user-id": os.environ["RECRUTEUR_ID"],
    },
    json={
        "agentId": os.environ["AGENT_ID"],
        "organizationId": "-",
        "requestedByUserId": "-",
        "batchName": "Saison été 2026",
        "sendEmail": True,
        "candidates": [
            {
                "firstname": "Lucas",
                "lastname": "Petit",
                "candidateEmail": "lucas.petit@example.com",
            },
            {
                "firstname": "Inès",
                "lastname": "Moreau",
                "candidateEmail": "ines.moreau@example.com",
            },
        ],
    },
)
print(response.status_code, response.json())

Réponse 201 :

json
[
  {
    "id": "1a6c9e3f-8b2d-4f7a-9c5e-0d4b7a2e6f91",
    "status": "pending",
    "purpose": "recruitment",
    "firstname": "Lucas",
    "lastname": "Petit",
    "candidateEmail": "lucas.petit@example.com",
    "phone": null,
    "agentId": "6f1c2a9e-3b7d-4e58-9a21-7c4d8e0b5f13",
    "organizationId": "e4a8c2f1-7d3b-4b9e-a6c5-1f0d9e8b2a37",
    "requestedByUserId": "9d2f6b1e-4a8c-4e7d-b3f5-6c0a1e9d8b24",
    "candidateData": null,
    "batchId": "batch_1795435200000_k3m9x2p7q",
    "batchName": "Saison été 2026",
    "feedbackRating": null,
    "feedbackComment": null,
    "resendCount": 0,
    "isTesting": false,
    "allowedInterviewTypes": [
      "video",
      "phone"
    ],
    "transcript": null,
    "metadata": null,
    "analysis": null,
    "agentData": {
      "skills": [
        {
          "title": "Mise en place & organisation",
          "description": "Organiser son poste et préparer les ingrédients avant le service",
          "weight": 40
        }
      ],
      "methodologies": {
        "id": "STAR",
        "title": "Méthode STAR",
        "description": "Situation, tâche, action, résultat",
        "criteria": [
          {
            "criterion": "Situation",
            "expected": "Décrit un contexte précis"
          }
        ]
      },
      "customConditions": [
        {
          "title": "Horaires",
          "description": "Le candidat est-il disponible le week-end ?",
          "isMandatory": true
        }
      ]
    },
    "createdAt": "2026-11-23T10:05:00.000Z",
    "completedAt": null,
    "expirationAt": null,
    "updatedAt": "2026-11-23T10:05:00.000Z",
    "deletedAt": null
  },
  {
    "id": "5e2b8d4a-6f1c-4a9e-b7d3-8c0f2e5a9b16",
    "status": "pending",
    "purpose": "recruitment",
    "firstname": "Inès",
    "lastname": "Moreau",
    "candidateEmail": "ines.moreau@example.com",
    "phone": null,
    "agentId": "6f1c2a9e-3b7d-4e58-9a21-7c4d8e0b5f13",
    "organizationId": "e4a8c2f1-7d3b-4b9e-a6c5-1f0d9e8b2a37",
    "requestedByUserId": "9d2f6b1e-4a8c-4e7d-b3f5-6c0a1e9d8b24",
    "candidateData": null,
    "batchId": "batch_1795435200000_k3m9x2p7q",
    "batchName": "Saison été 2026",
    "feedbackRating": null,
    "feedbackComment": null,
    "resendCount": 0,
    "isTesting": false,
    "allowedInterviewTypes": [
      "video",
      "phone"
    ],
    "transcript": null,
    "metadata": null,
    "analysis": null,
    "agentData": {
      "skills": [
        {
          "title": "Mise en place & organisation",
          "description": "Organiser son poste et préparer les ingrédients avant le service",
          "weight": 40
        }
      ],
      "methodologies": {
        "id": "STAR",
        "title": "Méthode STAR",
        "description": "Situation, tâche, action, résultat",
        "criteria": [
          {
            "criterion": "Situation",
            "expected": "Décrit un contexte précis"
          }
        ]
      },
      "customConditions": [
        {
          "title": "Horaires",
          "description": "Le candidat est-il disponible le week-end ?",
          "isMandatory": true
        }
      ]
    },
    "createdAt": "2026-11-23T10:05:00.000Z",
    "completedAt": null,
    "expirationAt": null,
    "updatedAt": "2026-11-23T10:05:00.000Z",
    "deletedAt": null
  }
]

WARNING

Soumis à la règle Créer sans doublon : un appel envoyé deux fois ne crée pas de second entretien.

Lire un entretien ​

GET /partner/interviews/by-id/{id}

Get interview by internal ID (authenticated)

Paramètres

NomEmplacementTypeRequisDescription
idpathstringoui

Réponses

CodeDescription
200
400Invalid request: details lists the fields at fault. Also an unsupported X-API-Version.
401Missing, revoked or expired API key, or missing or unknown acting user.
403Unknown API key, or the acting user may not act with this key or lacks the role.
404Not found, or not in the organizations of your key.
429Quota of the key exceeded: the Retry-After header gives the seconds to wait.
500Unexpected error: quote the requestId to the support.

Exemple

sh
curl "https://api.smart-interview.ai/partner/interviews/by-id/$INTERVIEW_ID" \
  -H "x-api-key: $CLE" \
  -H "x-acting-user-id: $RECRUTEUR_ID"
php
<?php
$curl = curl_init('https://api.smart-interview.ai/partner/interviews/by-id/' . getenv('INTERVIEW_ID'));
curl_setopt_array($curl, [
    CURLOPT_HTTPHEADER => [
        'x-api-key: ' . getenv('CLE'),
        'x-acting-user-id: ' . getenv('RECRUTEUR_ID'),
    ],
    CURLOPT_RETURNTRANSFER => true,
]);
$response = curl_exec($curl);
echo curl_getinfo($curl, CURLINFO_RESPONSE_CODE), PHP_EOL, $response, PHP_EOL;
js
const response = await fetch(`https://api.smart-interview.ai/partner/interviews/by-id/${process.env.INTERVIEW_ID}`, {
  headers: {
    'x-api-key': process.env.CLE,
    'x-acting-user-id': process.env.RECRUTEUR_ID,
  },
});
console.log(response.status, await response.json());
python
import os

import requests

response = requests.get(
    f"https://api.smart-interview.ai/partner/interviews/by-id/{os.environ['INTERVIEW_ID']}",
    headers={
        "x-api-key": os.environ["CLE"],
        "x-acting-user-id": os.environ["RECRUTEUR_ID"],
    },
)
print(response.status_code, response.json())

Réponse 200 :

json
{
  "id": "b3e7d1a4-5c92-4f6e-8d0a-2a9f6c1e7b48",
  "status": "pending",
  "purpose": "recruitment",
  "firstname": "Camille",
  "lastname": "Martin",
  "candidateEmail": "camille.martin@example.com",
  "phone": null,
  "agentId": "6f1c2a9e-3b7d-4e58-9a21-7c4d8e0b5f13",
  "organizationId": "e4a8c2f1-7d3b-4b9e-a6c5-1f0d9e8b2a37",
  "requestedByUserId": "9d2f6b1e-4a8c-4e7d-b3f5-6c0a1e9d8b24",
  "candidateData": null,
  "batchId": null,
  "batchName": null,
  "feedbackRating": null,
  "feedbackComment": null,
  "resendCount": 0,
  "isTesting": false,
  "allowedInterviewTypes": [
    "video",
    "phone"
  ],
  "transcript": null,
  "metadata": null,
  "analysis": null,
  "agentData": {
    "skills": [
      {
        "title": "Mise en place & organisation",
        "description": "Organiser son poste et préparer les ingrédients avant le service",
        "weight": 40
      }
    ],
    "methodologies": {
      "id": "STAR",
      "title": "Méthode STAR",
      "description": "Situation, tâche, action, résultat",
      "criteria": [
        {
          "criterion": "Situation",
          "expected": "Décrit un contexte précis"
        }
      ]
    },
    "customConditions": [
      {
        "title": "Horaires",
        "description": "Le candidat est-il disponible le week-end ?",
        "isMandatory": true
      }
    ]
  },
  "createdAt": "2026-11-23T10:00:00.000Z",
  "completedAt": null,
  "expirationAt": null,
  "updatedAt": "2026-11-23T10:00:00.000Z",
  "deletedAt": null
}

WARNING

Les champs du résultat, sauf version, agentTitle, shareLink et conditionInterruption : demandez le lien avec share-link. metadata, analysis et agentData sont hors contrat ; transcript vaut null, sauf si votre organisation a demandé l'envoi de la transcription intégrale.

Lister les questionnaires ​

GET /partner/questionnaires

List questionnaires, filtered by verdict and call outcome

Paginated: page from 1, pageSize up to 100. See « Listes » in the conventions.

Paramètres

NomEmplacementTypeRequisDescription
pagequeryintegernonDéfaut : 1.
pageSizequeryintegernonDéfaut : 20.
searchquerystringnon
statusquerypending · in_progress · completed · failed · voicemail · no_answer · refused · not_available · recruiter_requested · condition_not_metnon
verdictquerycompliant · minor_deviation · non_compliant · inconclusivenon
agentIdquerystring (uuid)non
organizationIdquerystring (uuid)non
orderqueryasc · descnonDéfaut : desc.

Réponses

CodeDescription
200
400Invalid request: details lists the fields at fault. Also an unsupported X-API-Version.
401Missing, revoked or expired API key, or missing or unknown acting user.
403Unknown API key, or the acting user may not act with this key or lacks the role.
404Not found, or not in the organizations of your key.
429Quota of the key exceeded: the Retry-After header gives the seconds to wait.
500Unexpected error: quote the requestId to the support.

Exemple

sh
curl "https://api.smart-interview.ai/partner/questionnaires?agentId=$QUESTIONNAIRE_AGENT_ID" \
  -H "x-api-key: $CLE" \
  -H "x-acting-user-id: $RECRUTEUR_ID"
php
<?php
$curl = curl_init('https://api.smart-interview.ai/partner/questionnaires?agentId=' . getenv('QUESTIONNAIRE_AGENT_ID'));
curl_setopt_array($curl, [
    CURLOPT_HTTPHEADER => [
        'x-api-key: ' . getenv('CLE'),
        'x-acting-user-id: ' . getenv('RECRUTEUR_ID'),
    ],
    CURLOPT_RETURNTRANSFER => true,
]);
$response = curl_exec($curl);
echo curl_getinfo($curl, CURLINFO_RESPONSE_CODE), PHP_EOL, $response, PHP_EOL;
js
const response = await fetch(`https://api.smart-interview.ai/partner/questionnaires?agentId=${process.env.QUESTIONNAIRE_AGENT_ID}`, {
  headers: {
    'x-api-key': process.env.CLE,
    'x-acting-user-id': process.env.RECRUTEUR_ID,
  },
});
console.log(response.status, await response.json());
python
import os

import requests

response = requests.get(
    f"https://api.smart-interview.ai/partner/questionnaires?agentId={os.environ['QUESTIONNAIRE_AGENT_ID']}",
    headers={
        "x-api-key": os.environ["CLE"],
        "x-acting-user-id": os.environ["RECRUTEUR_ID"],
    },
)
print(response.status_code, response.json())

Réponse 200 :

json
{
  "data": [
    {
      "id": "3c9f1e7b-2a5d-4b8e-9f6c-1d7a4e0b8c25",
      "status": "pending",
      "purpose": "questionnaire",
      "firstname": "Hugo",
      "lastname": "Lefèvre",
      "candidateEmail": "hugo.lefevre@example.com",
      "phone": "+33639980101",
      "agentId": "a8d4f2c6-9e1b-4d7a-8f3c-5b0e6a2d9c74",
      "organizationId": "e4a8c2f1-7d3b-4b9e-a6c5-1f0d9e8b2a37",
      "requestedByUserId": "9d2f6b1e-4a8c-4e7d-b3f5-6c0a1e9d8b24",
      "candidateData": null,
      "batchId": null,
      "batchName": null,
      "feedbackRating": null,
      "feedbackComment": null,
      "resendCount": 0,
      "isTesting": false,
      "allowedInterviewTypes": [
        "video"
      ],
      "transcript": null,
      "metadata": null,
      "analysis": null,
      "agentData": {
        "questions": [
          {
            "id": "q1",
            "order": 1,
            "label": "Avez-vous reçu vos EPI ?",
            "answerType": "yes_no",
            "expectedAnswer": "yes",
            "criticality": "blocking"
          }
        ],
        "midpointAnnouncement": true
      },
      "createdAt": "2026-11-23T11:00:00.000Z",
      "completedAt": null,
      "expirationAt": null,
      "updatedAt": "2026-11-23T11:00:00.000Z",
      "deletedAt": null
    }
  ],
  "page": 1,
  "pageSize": 20,
  "total": 1,
  "hasMore": false
}

Créer un questionnaire ​

POST /partner/questionnaires

Create a questionnaire for a phone number

Corps de la requête

ChampTypeRequisDescription
agentIdstringouiThe questionnaire agent (ex. a8d4f2c6-9e1b-4d7a-8f3c-5b0e6a2d9c74)
firstnamestringouiThe person first name (ex. Hugo)
lastnamestringouiThe person last name (ex. Lefèvre)
phonestringnonRequired to place a call or to send the link on WhatsApp (ex. +33639980101)
candidateEmailstringnonRequired to send the link by email (ex. hugo.lefevre@example.com)
modecall · linknonHow the person takes the questionnaire: call on the phone, link from their browser (ex. link)
organizationIdstringnonReplaced by the organization of the acting user with an API key
requestedByUserIdstringnonReplaced by the acting user with an API key

Réponses

CodeDescription
201Questionnaire created
400Invalid request: details lists the fields at fault. Also an unsupported X-API-Version.
401Missing, revoked or expired API key, or missing or unknown acting user.
403Unknown API key, or the acting user may not act with this key or lacks the role.
404Not found, or not in the organizations of your key.
409Duplicate: this candidate already has a pending interview with this agent, created less than 5 minutes ago. details gives its id. Nothing is created nor sent.
429Quota of the key exceeded: the Retry-After header gives the seconds to wait.
500Unexpected error: quote the requestId to the support.

Exemple

sh
curl -X POST "https://api.smart-interview.ai/partner/questionnaires" \
  -H "x-api-key: $CLE" \
  -H "x-acting-user-id: $RECRUTEUR_ID" \
  -H "Content-Type: application/json" \
  --data @- <<EOF
{
  "agentId": "$QUESTIONNAIRE_AGENT_ID",
  "firstname": "Hugo",
  "lastname": "Lefèvre",
  "candidateEmail": "hugo.lefevre@example.com",
  "phone": "+33639980101",
  "mode": "link"
}
EOF
php
<?php
$curl = curl_init('https://api.smart-interview.ai/partner/questionnaires');
curl_setopt_array($curl, [
    CURLOPT_CUSTOMREQUEST => 'POST',
    CURLOPT_HTTPHEADER => [
        'x-api-key: ' . getenv('CLE'),
        'x-acting-user-id: ' . getenv('RECRUTEUR_ID'),
        'Content-Type: application/json',
    ],
    CURLOPT_POSTFIELDS => json_encode([
        'agentId' => getenv('QUESTIONNAIRE_AGENT_ID'),
        'firstname' => 'Hugo',
        'lastname' => 'Lefèvre',
        'candidateEmail' => 'hugo.lefevre@example.com',
        'phone' => '+33639980101',
        'mode' => 'link',
    ]),
    CURLOPT_RETURNTRANSFER => true,
]);
$response = curl_exec($curl);
echo curl_getinfo($curl, CURLINFO_RESPONSE_CODE), PHP_EOL, $response, PHP_EOL;
js
const response = await fetch('https://api.smart-interview.ai/partner/questionnaires', {
  method: 'POST',
  headers: {
    'x-api-key': process.env.CLE,
    'x-acting-user-id': process.env.RECRUTEUR_ID,
    'Content-Type': 'application/json',
  },
  body: JSON.stringify({
    agentId: process.env.QUESTIONNAIRE_AGENT_ID,
    firstname: 'Hugo',
    lastname: 'Lefèvre',
    candidateEmail: 'hugo.lefevre@example.com',
    phone: '+33639980101',
    mode: 'link',
  }),
});
console.log(response.status, await response.json());
python
import os

import requests

response = requests.post(
    "https://api.smart-interview.ai/partner/questionnaires",
    headers={
        "x-api-key": os.environ["CLE"],
        "x-acting-user-id": os.environ["RECRUTEUR_ID"],
    },
    json={
        "agentId": os.environ["QUESTIONNAIRE_AGENT_ID"],
        "firstname": "Hugo",
        "lastname": "Lefèvre",
        "candidateEmail": "hugo.lefevre@example.com",
        "phone": "+33639980101",
        "mode": "link",
    },
)
print(response.status_code, response.json())

Réponse 201 :

json
{
  "id": "3c9f1e7b-2a5d-4b8e-9f6c-1d7a4e0b8c25",
  "status": "pending",
  "purpose": "questionnaire",
  "firstname": "Hugo",
  "lastname": "Lefèvre",
  "candidateEmail": "hugo.lefevre@example.com",
  "phone": "+33639980101",
  "agentId": "a8d4f2c6-9e1b-4d7a-8f3c-5b0e6a2d9c74",
  "organizationId": "e4a8c2f1-7d3b-4b9e-a6c5-1f0d9e8b2a37",
  "requestedByUserId": "9d2f6b1e-4a8c-4e7d-b3f5-6c0a1e9d8b24",
  "candidateData": null,
  "batchId": null,
  "batchName": null,
  "feedbackRating": null,
  "feedbackComment": null,
  "resendCount": 0,
  "isTesting": false,
  "allowedInterviewTypes": [
    "video"
  ],
  "transcript": null,
  "metadata": null,
  "analysis": null,
  "agentData": {
    "questions": [
      {
        "id": "q1",
        "order": 1,
        "label": "Avez-vous reçu vos EPI ?",
        "answerType": "yes_no",
        "expectedAnswer": "yes",
        "criticality": "blocking"
      }
    ],
    "midpointAnnouncement": true
  },
  "createdAt": "2026-11-23T11:00:00.000Z",
  "completedAt": null,
  "expirationAt": null,
  "updatedAt": "2026-11-23T11:00:00.000Z",
  "deletedAt": null
}

WARNING

Réservé aux organisations qui ont accès aux questionnaires : sinon, l'appel est refusé (403).

Soumis à la règle Créer sans doublon : un appel envoyé deux fois ne crée pas de second entretien.

Envoyer le lien d'un questionnaire ​

POST /partner/questionnaires/{id}/link

Get the questionnaire link, and send it on WhatsApp or by email when a channel is given

Paramètres

NomEmplacementTypeRequisDescription
idpathstringoui

Corps de la requête

ChampTypeRequisDescription
channelwhatsapp · emailnonThe channel the link goes out on. Left out: nothing is sent, the link is returned (ex. email)

Réponses

CodeDescription
200The link, plus the channel it went out on when one was asked for
400Invalid request: details lists the fields at fault. Also an unsupported X-API-Version.
401Missing, revoked or expired API key, or missing or unknown acting user.
403Unknown API key, or the acting user may not act with this key or lacks the role.
404Not found, or not in the organizations of your key.
429Quota of the key exceeded: the Retry-After header gives the seconds to wait.
500Unexpected error: quote the requestId to the support.

Exemple

sh
curl -X POST "https://api.smart-interview.ai/partner/questionnaires/$QUESTIONNAIRE_ID/link" \
  -H "x-api-key: $CLE" \
  -H "x-acting-user-id: $RECRUTEUR_ID" \
  -H "Content-Type: application/json" \
  --data @- <<EOF
{
  "channel": "email"
}
EOF
php
<?php
$curl = curl_init('https://api.smart-interview.ai/partner/questionnaires/' . getenv('QUESTIONNAIRE_ID') . '/link');
curl_setopt_array($curl, [
    CURLOPT_CUSTOMREQUEST => 'POST',
    CURLOPT_HTTPHEADER => [
        'x-api-key: ' . getenv('CLE'),
        'x-acting-user-id: ' . getenv('RECRUTEUR_ID'),
        'Content-Type: application/json',
    ],
    CURLOPT_POSTFIELDS => json_encode([
        'channel' => 'email',
    ]),
    CURLOPT_RETURNTRANSFER => true,
]);
$response = curl_exec($curl);
echo curl_getinfo($curl, CURLINFO_RESPONSE_CODE), PHP_EOL, $response, PHP_EOL;
js
const response = await fetch(`https://api.smart-interview.ai/partner/questionnaires/${process.env.QUESTIONNAIRE_ID}/link`, {
  method: 'POST',
  headers: {
    'x-api-key': process.env.CLE,
    'x-acting-user-id': process.env.RECRUTEUR_ID,
    'Content-Type': 'application/json',
  },
  body: JSON.stringify({
    channel: 'email',
  }),
});
console.log(response.status, await response.json());
python
import os

import requests

response = requests.post(
    f"https://api.smart-interview.ai/partner/questionnaires/{os.environ['QUESTIONNAIRE_ID']}/link",
    headers={
        "x-api-key": os.environ["CLE"],
        "x-acting-user-id": os.environ["RECRUTEUR_ID"],
    },
    json={
        "channel": "email",
    },
)
print(response.status_code, response.json())

Réponse 200 :

json
{
  "url": "https://app.smart-interview.ai/candidates?code=Hn5wB9kTe",
  "code": "Hn5wB9kTe",
  "sentOn": "email"
}

Relancer un questionnaire ​

POST /partner/questionnaires/{id}/retry

Reset a completed questionnaire to pending and solicit the person again

Paramètres

NomEmplacementTypeRequisDescription
idpathstringoui

Réponses

CodeDescription
200Questionnaire successfully reset and sent again
400Invalid request: details lists the fields at fault. Also an unsupported X-API-Version.
401Missing, revoked or expired API key, or missing or unknown acting user.
403Unknown API key, or the acting user may not act with this key or lacks the role.
404Not found, or not in the organizations of your key.
429Quota of the key exceeded: the Retry-After header gives the seconds to wait.
500Unexpected error: quote the requestId to the support.

Exemple

sh
curl -X POST "https://api.smart-interview.ai/partner/questionnaires/$QUESTIONNAIRE_ID/retry" \
  -H "x-api-key: $CLE" \
  -H "x-acting-user-id: $RECRUTEUR_ID"
php
<?php
$curl = curl_init('https://api.smart-interview.ai/partner/questionnaires/' . getenv('QUESTIONNAIRE_ID') . '/retry');
curl_setopt_array($curl, [
    CURLOPT_CUSTOMREQUEST => 'POST',
    CURLOPT_HTTPHEADER => [
        'x-api-key: ' . getenv('CLE'),
        'x-acting-user-id: ' . getenv('RECRUTEUR_ID'),
    ],
    CURLOPT_RETURNTRANSFER => true,
]);
$response = curl_exec($curl);
echo curl_getinfo($curl, CURLINFO_RESPONSE_CODE), PHP_EOL, $response, PHP_EOL;
js
const response = await fetch(`https://api.smart-interview.ai/partner/questionnaires/${process.env.QUESTIONNAIRE_ID}/retry`, {
  method: 'POST',
  headers: {
    'x-api-key': process.env.CLE,
    'x-acting-user-id': process.env.RECRUTEUR_ID,
  },
});
console.log(response.status, await response.json());
python
import os

import requests

response = requests.post(
    f"https://api.smart-interview.ai/partner/questionnaires/{os.environ['QUESTIONNAIRE_ID']}/retry",
    headers={
        "x-api-key": os.environ["CLE"],
        "x-acting-user-id": os.environ["RECRUTEUR_ID"],
    },
)
print(response.status_code, response.json())

Réponse 200 :

json
{
  "message": "Questionnaire reset successfully"
}

WARNING

Seulement sur un questionnaire terminé : un questionnaire en attente est refusé (400).

Partager le résultat d'un questionnaire ​

POST /partner/questionnaires/{id}/share-link

Generate public questionnaire report share link

Paramètres

NomEmplacementTypeRequisDescription
idpathstringoui

Réponses

CodeDescription
200Return the public report URL and its code
400Invalid request: details lists the fields at fault. Also an unsupported X-API-Version.
401Missing, revoked or expired API key, or missing or unknown acting user.
403Unknown API key, or the acting user may not act with this key or lacks the role.
404Not found, or not in the organizations of your key.
429Quota of the key exceeded: the Retry-After header gives the seconds to wait.
500Unexpected error: quote the requestId to the support.

Exemple

sh
curl -X POST "https://api.smart-interview.ai/partner/questionnaires/$QUESTIONNAIRE_ID/share-link" \
  -H "x-api-key: $CLE" \
  -H "x-acting-user-id: $RECRUTEUR_ID"
php
<?php
$curl = curl_init('https://api.smart-interview.ai/partner/questionnaires/' . getenv('QUESTIONNAIRE_ID') . '/share-link');
curl_setopt_array($curl, [
    CURLOPT_CUSTOMREQUEST => 'POST',
    CURLOPT_HTTPHEADER => [
        'x-api-key: ' . getenv('CLE'),
        'x-acting-user-id: ' . getenv('RECRUTEUR_ID'),
    ],
    CURLOPT_RETURNTRANSFER => true,
]);
$response = curl_exec($curl);
echo curl_getinfo($curl, CURLINFO_RESPONSE_CODE), PHP_EOL, $response, PHP_EOL;
js
const response = await fetch(`https://api.smart-interview.ai/partner/questionnaires/${process.env.QUESTIONNAIRE_ID}/share-link`, {
  method: 'POST',
  headers: {
    'x-api-key': process.env.CLE,
    'x-acting-user-id': process.env.RECRUTEUR_ID,
  },
});
console.log(response.status, await response.json());
python
import os

import requests

response = requests.post(
    f"https://api.smart-interview.ai/partner/questionnaires/{os.environ['QUESTIONNAIRE_ID']}/share-link",
    headers={
        "x-api-key": os.environ["CLE"],
        "x-acting-user-id": os.environ["RECRUTEUR_ID"],
    },
)
print(response.status_code, response.json())

Réponse 200 :

json
{
  "url": "https://app.smart-interview.ai/questionnaires/report/3c9f1e7b-2a5d-4b8e-9f6c-1d7a4e0b8c25?code=Hn5wB9kTe",
  "code": "Hn5wB9kTe"
}

Envoyer des liens en lot ​

POST /partner/questionnaires/bulk-send-link

Send the questionnaire link to several people at once

Corps de la requête

ChampTypeRequisDescription
questionnaireIdsstring[]ouiThe questionnaires whose link is sent (ex. 3c9f1e7b-2a5d-4b8e-9f6c-1d7a4e0b8c25)
channelwhatsapp · emailnonThe channel the links go out on. Left out: WhatsApp (ex. email)

Réponses

CodeDescription
200Links sent, with the per-questionnaire tally
400Invalid request: details lists the fields at fault. Also an unsupported X-API-Version.
401Missing, revoked or expired API key, or missing or unknown acting user.
403Unknown API key, or the acting user may not act with this key or lacks the role.
404Not found, or not in the organizations of your key.
429Quota of the key exceeded: the Retry-After header gives the seconds to wait.
500Unexpected error: quote the requestId to the support.

Exemple

sh
curl -X POST "https://api.smart-interview.ai/partner/questionnaires/bulk-send-link" \
  -H "x-api-key: $CLE" \
  -H "x-acting-user-id: $RECRUTEUR_ID" \
  -H "Content-Type: application/json" \
  --data @- <<EOF
{
  "questionnaireIds": [
    "$QUESTIONNAIRE_ID"
  ],
  "channel": "email"
}
EOF
php
<?php
$curl = curl_init('https://api.smart-interview.ai/partner/questionnaires/bulk-send-link');
curl_setopt_array($curl, [
    CURLOPT_CUSTOMREQUEST => 'POST',
    CURLOPT_HTTPHEADER => [
        'x-api-key: ' . getenv('CLE'),
        'x-acting-user-id: ' . getenv('RECRUTEUR_ID'),
        'Content-Type: application/json',
    ],
    CURLOPT_POSTFIELDS => json_encode([
        'questionnaireIds' => [
            getenv('QUESTIONNAIRE_ID'),
        ],
        'channel' => 'email',
    ]),
    CURLOPT_RETURNTRANSFER => true,
]);
$response = curl_exec($curl);
echo curl_getinfo($curl, CURLINFO_RESPONSE_CODE), PHP_EOL, $response, PHP_EOL;
js
const response = await fetch('https://api.smart-interview.ai/partner/questionnaires/bulk-send-link', {
  method: 'POST',
  headers: {
    'x-api-key': process.env.CLE,
    'x-acting-user-id': process.env.RECRUTEUR_ID,
    'Content-Type': 'application/json',
  },
  body: JSON.stringify({
    questionnaireIds: [
      process.env.QUESTIONNAIRE_ID,
    ],
    channel: 'email',
  }),
});
console.log(response.status, await response.json());
python
import os

import requests

response = requests.post(
    "https://api.smart-interview.ai/partner/questionnaires/bulk-send-link",
    headers={
        "x-api-key": os.environ["CLE"],
        "x-acting-user-id": os.environ["RECRUTEUR_ID"],
    },
    json={
        "questionnaireIds": [
            os.environ["QUESTIONNAIRE_ID"],
        ],
        "channel": "email",
    },
)
print(response.status_code, response.json())

Réponse 200 :

json
{
  "message": "Bulk send completed: 1 link(s) sent successfully, 0 failed",
  "successCount": 1,
  "failedCount": 0,
  "failedIds": []
}

Documentation d'intégration Smart Interview.