# Codility

> Manage assessment invitations and interviews, and look up sessions and reports.

App · 20 actions. Web page: https://docs.lodol.com/docs/integrations/codility

## Actions

### Cancel an assessment session

Cancels a test session (ticket) if it is not already canceled and can be canceled.

**Inputs**

- Session ID (`session_id`, text, required): A unique value identifying this ticket.

**Outputs**

- `data` (object): The response from cancel an assessment session.
- `has_more` (true/false): Whether another page is available.
- `next_cursor` (text): The page or cursor to pass to the next request.

**Example output**

```json
{
  "data": {
    "result": "example"
  },
  "has_more": false,
  "next_cursor": null
}
```

### Create an assessment invitation

Invites candidates to a specific test (campaign) by creating tickets for them.

**Inputs**

- Test (`test_id`, number, required): A unique integer value identifying this campaign.
- Candidates (`candidates`, list, required): Candidates.

**Outputs**

- `data` (object): The response from create an assessment invitation.
- `has_more` (true/false): Whether another page is available.
- `next_cursor` (text): The page or cursor to pass to the next request.

**Example output**

```json
{
  "data": {
    "candidates": [
      {
        "id": "example",
        "session_id": "QA-TICKET",
        "session_url": "https://codility.com/api/sessions/QA-TICKET/",
        "test_link": "https://example.com/"
      }
    ]
  },
  "has_more": false,
  "next_cursor": null
}
```

### Create an embeddable report link

You can retrieve a temporary link to the candidate report.

**Inputs**

- Session ID (`session_id`, text, required): A unique value identifying this ticket.
- Expiration time (`expiration_time`, number): Optional expiration time in minutes. From 15 to 129600.

**Outputs**

- `data` (object): The response from create an embeddable report link.
- `has_more` (true/false): Whether another page is available.
- `next_cursor` (text): The page or cursor to pass to the next request.

**Example output**

```json
{
  "data": {
    "url": "https://example.com/",
    "valid_until": "2026-11-18T12:00:00Z"
  },
  "has_more": false,
  "next_cursor": null
}
```

### Create an embeddable similarity report link

Generates an embed similarity report for a specific test session (ticket) and returns a tokenized URL.

**Inputs**

- Session ID (`session_id`, text, required): The unique identifier of the Session (Ticket) to retrieve the similarity report for.
- Expiration time (`expiration_time`, number): Optional expiration time in minutes. From 15 to 129600.

**Outputs**

- `data` (object): The response from create an embeddable similarity report link.
- `has_more` (true/false): Whether another page is available.
- `next_cursor` (text): The page or cursor to pass to the next request.

**Example output**

```json
{
  "data": {
    "url": "https://example.com/",
    "valid_until": "2026-11-18T12:00:00Z"
  },
  "has_more": false,
  "next_cursor": null
}
```

### Create an interview

Creates a new Interview with the specified parameters.

**Inputs**

- Room name (`room_name`, text): The name that will be displayed in the Codility interface.
- Template (`template_id`, number): The ID of the template that will be used for the interview.
- Candidate email (`candidate_email`, text): The email of the candidate who will be invited to the interview.
- Candidate first name (`candidate_first_name`, text): The first name of the candidate who will be invited to the interview.
- Candidate last name (`candidate_last_name`, text): The last name of the candidate who will be invited to the interview.
- Scheduled start date (`scheduled_start_date`, date and time): The date and time when the interview will start.
- Scheduled duration (`scheduled_duration`, number): The duration of the interview in minutes (integer from 1 to 600). From 1 to 600.
- Assessment ID (`assessment_id`, text): The ID of the Screen assessment.
- Campaign ID (`campaign_id`, number): The ID of the test (campaign).
- Interviewer emails (`interviewer_emails`, list): A list of emails of the interviewers who will be invited to the interview.

**Outputs**

- `data` (object): The response from create an interview.
- `has_more` (true/false): Whether another page is available.
- `next_cursor` (text): The page or cursor to pass to the next request.

**Example output**

```json
{
  "data": {
    "access_code": "example",
    "session_url": "https://example.com/",
    "test_url": "https://example.com/"
  },
  "has_more": false,
  "next_cursor": null
}
```

### Delete an interview

Deletes an interview with the specified ID.

**Inputs**

- Session ID (`session_id`, text, required): Session ID.

**Outputs**

- `data` (object): The response from delete an interview.
- `has_more` (true/false): Whether another page is available.
- `next_cursor` (text): The page or cursor to pass to the next request.

**Example output**

```json
{
  "data": {
    "success": true
  },
  "has_more": false,
  "next_cursor": null
}
```

### Get an assessment

Returns detailed information about a specific test (campaign), including its properties and associated team.

**Inputs**

- Test (`test_id`, number, required): A unique integer value identifying this campaign.

**Outputs**

- `data` (object): The response from get an assessment.
- `has_more` (true/false): Whether another page is available.
- `next_cursor` (text): The page or cursor to pass to the next request.

**Example output**

```json
{
  "data": {
    "create_date": "2026-11-18T12:00:00Z",
    "id": 1,
    "invite_url": "https://example.com/",
    "is_archived": true,
    "name": "example",
    "possible_total_score": 1,
    "public_test_link": "example",
    "sessions_url": "https://example.com/",
    "test_setup": {
      "allowed_languages": [],
      "task_names": [],
      "tasks": [],
      "timelimit_minutes": 1
    },
    "time_limit": 1,
    "total_number_of_tasks": 1,
    "url": "https://example.com/"
  },
  "has_more": false,
  "next_cursor": null
}
```

### Get an assessment session

Returns detailed information about a specific test session (ticket), including candidate data and status.

**Inputs**

- Session ID (`session_id`, text, required): A unique value identifying this ticket.

**Outputs**

- `data` (object): The response from get an assessment session.
- `has_more` (true/false): Whether another page is available.
- `next_cursor` (text): The page or cursor to pass to the next request.

**Example output**

```json
{
  "data": {
    "access_data": [
      {
        "accessor_type": {},
        "created_at": "2026-11-18T12:00:00Z",
        "http_accept_language": "example",
        "http_user_agent": "example",
        "ip": "example"
      }
    ],
    "campaign_url": "https://example.com/",
    "cancel_url": "https://example.com/",
    "candidate": "example",
    "candidate_data": {
      "academic_degree": "example",
      "additional_data": {},
      "field_of_study": "example",
      "profile_url": "https://example.com/",
      "programming_experience": "example",
      "school": "example"
    },
    "codelive": {
      "access_code": "example",
      "candidate_start_date": "2026-11-18T12:00:00Z",
      "last_activity_date": "2026-11-18T12:00:00Z",
      "notes": [],
      "scorecard": {}
    },
    "create_date": "2026-11-18T12:00:00Z",
    "email": "qa@example.com",
    "evaluation": {
      "max_result": 1,
      "result": 1,
      "tasks": []
    },
    "feedback_link": "https://example.com/",
    "first_name": "example",
    "integrity": {
      "risk": {}
    },
    "is_expired": true,
    "last_name": "example",
    "pdf_report_url": "https://example.com/",
    "report_link": "https://example.com/",
    "reviews": [
      {
        "feedback": "example",
        "recommendation": "thumbs-up",
        "reviewer": "example"
      }
    ],
    "similarity": {
      "embed_url": "https://example.com/",
      "icon": "example",
      "text": "example"
    },
    "skills_proficiency_levels": [
      {
        "category": "Skill",
        "name": "example",
        "proficiency_level": 1,
        "slug": "example"
      }
    ],
    "start_codelive_url": "https://example.com/",
    "start_date": "2026-11-18T12:00:00Z",
    "test_link": "https://example.com/",
    "url": "https://example.com/"
  },
  "has_more": false,
  "next_cursor": null
}
```

### Get available credits

Retrieve the current amount of available credits for the account.

**Inputs**: None.

**Outputs**

- `data` (object): The response from get available credits.
- `has_more` (true/false): Whether another page is available.
- `next_cursor` (text): The page or cursor to pass to the next request.

**Example output**

```json
{
  "data": {
    "credits_available": 1,
    "level": {},
    "message": "example"
  },
  "has_more": false,
  "next_cursor": null
}
```

### Get session integrity insights

Retrieves integrity insights for a specific test session (ticket).

**Inputs**

- Ticket ID (`ticket_id`, text, required): The ID of the test session (ticket) to retrieve integrity insights for.

**Outputs**

- `data` (object): The response from get session integrity insights.
- `has_more` (true/false): Whether another page is available.
- `next_cursor` (text): The page or cursor to pass to the next request.

**Example output**

```json
{
  "data": {
    "account_id": "example",
    "assessment_id": "example",
    "assessment_integrity_status": "example",
    "assessment_passing_score": 1,
    "assessment_reports": [],
    "assessment_score": 1,
    "assessment_status": "example",
    "campaign_id": "example",
    "created_at": 1,
    "evaluations": [],
    "integrity_risk": {},
    "source_environment": "example",
    "updated_at": 1
  },
  "has_more": false,
  "next_cursor": null
}
```

### Get the account

Restful API endpoint to retrieve account information, including links to credit level and user login history.

**Inputs**: None.

**Outputs**

- `data` (object): The response from get the account.
- `has_more` (true/false): Whether another page is available.
- `next_cursor` (text): The page or cursor to pass to the next request.

**Example output**

```json
{
  "data": {
    "credit_level": "https://example.com/",
    "user_logins": "https://example.com/"
  },
  "has_more": false,
  "next_cursor": null
}
```

### Get the default email template

The default email template for the authenticated account.

**Inputs**: None.

**Outputs**

- `data` (object): The response from get the default email template.
- `has_more` (true/false): Whether another page is available.
- `next_cursor` (text): The page or cursor to pass to the next request.

**Example output**

```json
{
  "data": {
    "content": "example",
    "reply_to": "qa@example.com",
    "subject": "example"
  },
  "has_more": false,
  "next_cursor": null
}
```

### List assessment sessions

Returns a list of test sessions (tickets) visible to the user, with optional filtering and pagination.

**Inputs**

- Business domain (`business_domain`, text): Restrict returned sessions to a single business domain: 'hire' for hiring sessions, 'csi' for Skills Intelligence sessions. One of: `csi`, `hire`.
- Create date 0 (`create_date_0`, date and time): Create date 0.
- Create date 1 (`create_date_1`, date and time): Create date 1.
- Extra fields (`extra_fields`, text): Include extra fields in the response, comma separated.
- Ordering (`ordering`, text): Which field to use when ordering the results.
- Page (`page`, number): A page number within the paginated result set. At least 1.
- Start date 0 (`start_date_0`, date and time): Start date 0.
- Start date 1 (`start_date_1`, date and time): Start date 1.

**Outputs**

- `data` (object): The response from list assessment sessions.
- `has_more` (true/false): Whether another page is available.
- `next_cursor` (text): The page or cursor to pass to the next request.

**Example output**

```json
{
  "data": {
    "count": 1,
    "next": "https://example.com/",
    "previous": "https://example.com/",
    "results": [
      {
        "campaign_url": "https://example.com/",
        "candidate": "example",
        "close_date": "2026-11-18T12:00:00Z",
        "create_date": "2026-11-18T12:00:00Z",
        "email": "qa@example.com",
        "email_of_invited_by": "example",
        "evaluation": {},
        "first_name": "example",
        "id": "example",
        "integrity": {},
        "invite_expiration_date": "2026-11-18T12:00:00Z",
        "invited_by": "example",
        "last_name": "example",
        "proctoring": {},
        "reviews": [],
        "similarity": {},
        "skills_proficiency_levels": [],
        "start_date": "2026-11-18T12:00:00Z",
        "status": "example",
        "team_name": "example",
        "test_name": "example",
        "time_used_minutes": 1,
        "url": "https://example.com/"
      }
    ]
  },
  "has_more": false,
  "next_cursor": null
}
```

### List assessments

Returns a list of tests (campaigns) visible to the user, with optional filtering and pagination.

**Inputs**

- Is archived (`is_archived`, true/false): Is archived.
- Page (`page`, number): A page number within the paginated result set. At least 1.

**Outputs**

- `data` (object): The response from list assessments.
- `has_more` (true/false): Whether another page is available.
- `next_cursor` (text): The page or cursor to pass to the next request.

**Example output**

```json
{
  "data": {
    "count": 1,
    "next": "https://example.com/",
    "previous": "https://example.com/",
    "results": [
      {
        "create_date": "2026-11-18T12:00:00Z",
        "id": 1,
        "invite_url": "https://example.com/",
        "is_archived": true,
        "name": "example",
        "possible_total_score": 1,
        "public_test_link": "example",
        "sessions_url": "https://example.com/",
        "time_limit": 1,
        "total_number_of_tasks": 1,
        "url": "https://example.com/"
      }
    ]
  },
  "has_more": false,
  "next_cursor": null
}
```

### List interview templates

Returns a list of interview templates available for the current user.

**Inputs**

- Ordering (`ordering`, text): Which field to use when ordering the results.
- Page (`page`, number): A page number within the paginated result set. At least 1.

**Outputs**

- `data` (object): The response from list interview templates.
- `has_more` (true/false): Whether another page is available.
- `next_cursor` (text): The page or cursor to pass to the next request.

**Example output**

```json
{
  "data": {
    "count": 1,
    "next": "https://example.com/",
    "previous": "https://example.com/",
    "results": [
      {
        "id": 1,
        "name": "example"
      }
    ]
  },
  "has_more": false,
  "next_cursor": null
}
```

### List saved email templates

List of saved email templates for the authenticated user.

**Inputs**: None.

**Outputs**

- `data` (list): The response from list saved email templates.
- `has_more` (true/false): Whether another page is available.
- `next_cursor` (text): The page or cursor to pass to the next request.

**Example output**

```json
{
  "data": [
    {
      "form_data": {
        "content": "example",
        "reply_to": "qa@example.com",
        "subject": "example"
      },
      "name": "example"
    }
  ],
  "has_more": false,
  "next_cursor": null
}
```

### List sessions for an assessment

Returns a list of test sessions (tickets) visible to the user, with optional filtering and pagination.

**Inputs**

- Business domain (`business_domain`, text): Restrict returned sessions to a single business domain: 'hire' for hiring sessions, 'csi' for Skills Intelligence sessions. One of: `csi`, `hire`.
- Create date 0 (`create_date_0`, date and time): Create date 0.
- Create date 1 (`create_date_1`, date and time): Create date 1.
- Extra fields (`extra_fields`, text): Include extra fields in the response, comma separated.
- Test (`test_id`, text, required): A unique value identifying this ticket.
- Ordering (`ordering`, text): Which field to use when ordering the results.
- Page (`page`, number): A page number within the paginated result set. At least 1.
- Start date 0 (`start_date_0`, date and time): Start date 0.
- Start date 1 (`start_date_1`, date and time): Start date 1.

**Outputs**

- `data` (object): The response from list sessions for an assessment.
- `has_more` (true/false): Whether another page is available.
- `next_cursor` (text): The page or cursor to pass to the next request.

**Example output**

```json
{
  "data": {
    "count": 1,
    "next": "https://example.com/",
    "previous": "https://example.com/",
    "results": [
      {
        "campaign_url": "https://example.com/",
        "candidate": "example",
        "close_date": "2026-11-18T12:00:00Z",
        "create_date": "2026-11-18T12:00:00Z",
        "email": "qa@example.com",
        "email_of_invited_by": "example",
        "evaluation": {},
        "first_name": "example",
        "id": "example",
        "integrity": {},
        "invite_expiration_date": "2026-11-18T12:00:00Z",
        "invited_by": "example",
        "last_name": "example",
        "proctoring": {},
        "reviews": [],
        "similarity": {},
        "skills_proficiency_levels": [],
        "start_date": "2026-11-18T12:00:00Z",
        "status": "example",
        "team_name": "example",
        "test_name": "example",
        "time_used_minutes": 1,
        "url": "https://example.com/"
      }
    ]
  },
  "has_more": false,
  "next_cursor": null
}
```

### List user logins

Returns a paginated list of user login events for the account, ordered by timestamp descending.

**Inputs**

- Email (`email`, text): Email.
- Page (`page`, number): A page number within the paginated result set. At least 1.

**Outputs**

- `data` (object): The response from list user logins.
- `has_more` (true/false): Whether another page is available.
- `next_cursor` (text): The page or cursor to pass to the next request.

**Example output**

```json
{
  "data": {
    "count": 1,
    "next": "https://example.com/",
    "previous": "https://example.com/",
    "results": [
      {
        "ip": "example",
        "timestamp": "2026-11-18T12:00:00Z",
        "user": {}
      }
    ]
  },
  "has_more": false,
  "next_cursor": null
}
```

### Send an assessment invitation email

This endpoint allows you to send or resend an invitation email to a candidate for a test session.

**Inputs**

- Session ID (`session_id`, text, required): A unique value identifying this ticket.
- Subject (`subject`, text): Subject of the email.
- Content (`content`, text): Content of the email.
- Reply to (`reply_to`, text): Reply-to email address.
- CC (`cc`, list): List of emails.

**Outputs**

- `data` (object): The response from send an assessment invitation email.
- `has_more` (true/false): Whether another page is available.
- `next_cursor` (text): The page or cursor to pass to the next request.

**Example output**

```json
{
  "data": {
    "result": "example"
  },
  "has_more": false,
  "next_cursor": null
}
```

### Update an interview

Updates an interview with the specified ID.

**Inputs**

- Session ID (`session_id`, text, required): Session ID.
- Room name (`room_name`, text): The name that will be displayed in the Codility interface.
- Candidate email (`candidate_email`, text): The email of the candidate who will be invited to the interview.
- Candidate first name (`candidate_first_name`, text): The first name of the candidate who will be invited to the interview.
- Candidate last name (`candidate_last_name`, text): The last name of the candidate who will be invited to the interview.
- Scheduled start date (`scheduled_start_date`, date and time): The date and time when the interview will start.
- Scheduled duration (`scheduled_duration`, number): The duration of the interview in minutes (integer from 1 to 600). From 1 to 600.
- Interviewer emails (`interviewer_emails`, list): A list of emails of the interviewers who will be invited to the interview.

**Outputs**

- `data` (object): The response from update an interview.
- `has_more` (true/false): Whether another page is available.
- `next_cursor` (text): The page or cursor to pass to the next request.

**Example output**

```json
{
  "data": {},
  "has_more": false,
  "next_cursor": null
}
```
