Archive a Line. This archives the line and removes it from the line list, from iPads and TVs, from the service screen and from statistics. The line can be unarchived.
Calls the following HTTP API: POST /lines/<ID>/archive
For example:
await Qminder.lines.archive(1425);
the Line or the line's ID to archive
A Promise that resolves when the line was archived, and rejects when something went wrong.
Create a new Line and return its details.
Calls the following HTTP API: POST /locations/<ID>/lines
For example:
const line: Line = await Qminder.lines.create(950, { name: 'Priority Service' });
console.log(line.id); // 1425
the location to add the line under
the parameters of the new line - must include the line name
a Promise that resolves to a new Line object, created according to the parameters.
Delete a Line. This deletes the line and removes it from the line list, from iPads and TVs, from the service screen and from statistics. This action cannot be undone.
Calls the following HTTP API: DELETE /lines/<ID>
For example:
await Qminder.lines.delete(1425);
the Line or the line's ID to delete
A Promise that resolves when the line was deleted, and rejects when something went wrong.
Fetch detailed information about one line.
Calls the following HTTP API: GET /lines/<ID>
For example:
const line: Line = await Qminder.lines.details(1425);
The line to get detailed info about, or the line's ID.
a promise that resolves to the Line object, or rejects if something went wrong.
Disable a Line.
Calls the following HTTP API: POST /lines/<ID>/disable
For example:
await Qminder.lines.disable(1425);
the Line or the ID of the line to be disabled.
A Promise that resolves when the line was disabled, and rejects when there active tickets in the line or something went wrong.
Enable a disabled Line.
Calls the following HTTP API: POST /lines/<ID>/enable
For example:
await Qminder.lines.enable(1425);
the Line or the ID of the line to be enabled.
A Promise that resolves when the line was enabled, and rejects when something went wrong.
Fetch the location's line list. The lines will have the line ID, name, and color filled in.
Calls the following HTTP API: GET /locations/<ID>/lines
For example:
const lines = await Qminder.lines.list(159);
the Location or its ID
a promise that resolves to a list of lines, or rejects if something went wrong.
Unarchive a Line.
Calls the following HTTP API: POST /lines/<ID>/unarchive
For example:
await Qminder.lines.unarchive(1425);
the Line or the line's ID to unarchive
A Promise that resolves when the line was unarchived, and rejects when something went wrong.
Update an existing Line name and color.
Calls the following HTTP API: POST /lines/<ID>
For example:
const line = { "id": 950, "name": "Front Desk", "color": "#ffffff" };
await Qminder.lines.update(line);
the Line to be updated - must include the line id, the desired new name and color.
A Promise that resolves when the line was updated, and rejects when something went wrong.
Generated using TypeDoc
The LineService allows you to access data about Lines in Qminder.
For example, list all Lines of your Location: