api:deletedcustomer:employees
Table of Contents
API : Deleted Customer Users
Introduction
This request returns the users a deleted customer had. Deleting a customer strips personal data such as e-mail address, mobile number and address from its users; this endpoint only returns what the user records still hold, so that data is not read back from the change log.
Request
| URL | https://api.telecomx.dk/deletedcustomer/CUSTOMER_ID/employees | |
|---|---|---|
| Method | GET | |
| Access level | RESELLER_ADMIN or ADMIN | |
| Param | CUSTOMER_ID | Id of the deleted customer (24 hex-char string) |
Query example
https://api.telecomx.dk/deletedcustomer/619366605a8fe9d7495f1699/employees
Response
An array of users, sorted by name:
| User object | ||
|---|---|---|
| _id | Id | Id of the user. |
| name | String | Name of the user. |
| title | String | Title, if any. |
| department | String | Department, if any. |
| state | String | State of the user, DELETED once the customer is deleted. |
| product | Object | _id and name of the user product, null if none. name is null if the product no longer exists. |
| addonProducts | Array | Add-on products: _id and product (_id, name). |
| startDate | Date | When the user product started, if any. |
| invoicedUntil | Date | Until when the user product was invoiced, if any. |
| createdAt | Date | When the user was created. |
| deletedAt | Date | When the user was deleted. |
Example
[ { "_id": "67dd723da1f3906cd381ac62", "name": "Hans Hansen", "title": "Manager", "state": "DELETED", "product": { "_id": "6516a3a70d3680d715ffd06e", "name": "PBX user" }, "addonProducts": [], "startDate": "2025-03-21T00:00:00.000Z", "invoicedUntil": "2026-09-30T00:00:00.000Z", "createdAt": "2025-03-21T14:02:37.000Z", "deletedAt": "2026-09-15T17:53:02.118Z" } ]
Errors
| Error code | Message | Description |
|---|---|---|
| 403 | access_denied | Insufficient access level |
| 404 | customer | Customer not found - also when the customer is not deleted |
| 422 | id | Customer id is invalid |
| 500 | internal_error | <Unspecified> |
api/deletedcustomer/employees.txt · Last modified: by Telecom X AI