API Version: 6.4

Handset Management

Permissions

Unless otherwise specified, this requires System-Admin or Company-Admin access.

command 'create'

Path: /rest/ops/create/
This option requires System-Admin access.
Create a DDI entry linked to an extension.
{
    "type": "ddi"
    "values": {
        "dialcode": "dialcode part of DDI",
        "number": "number part of DDI",
        "virt_exten": "linked extension number",
        "company": "company"
    }
}
Return value:
{
    "result": "success",
    "numrows": rows-created
}

command 'read'

Path: /rest/ops/read/
This option requires System-Admin or relevant Company-Admin access.
Read a DDI or list of DDIs - For Company-Admin users the result is automatically restricted to administered companies.
{
    "type": "ddi"
    "scope": {
        "dialcode": "dialcode part of DDI (optional)",
        "number": "number part of DDI (optional)",
        "virt_exten": "linked extension number (optional)",
        "company": "company (optional)"
    }
}
Return value:
{
    "result": "success",
    "values": [
        {
            "dialcode": "dialcode part of DDI",
            "number": "number part of DDI",
            "virt_exten": "linked extension number",
            "company": "company"
        },
        ...
    ],
    numrows: number-of-rows
}

command 'update'

Path: /rest/ops/update/
This option requires System-Admin or relevant Company-Admin access.
Update a DDI or list of DDIs - For Company-Admin users the result is automatically restricted to administered companies.
The dialcode and number fields cannot be edited.
{
    "type": "ddi"
    "scope": {
        "dialcode": "dialcode part of DDI (optional)",
        "number": "number part of DDI (optional)",
        "virt_exten": "linked extension number (optional)",
        "company": "company"
    },
    "values": {
        "virt_exten": "linked extension number (optional)",
        "company": "company (optional)"
    }
}
Path: /rest/ops/link/
This option requires System-Admin or relevant Company-Admin access.
Very much like 'update' but with additional checks to operate more like a DDI-to-extension link call. The fields shown below must all be provided. For Company-Admin users the result is automatically restricted to administered companies.
{
    "type": "ddi"
    "scope": {
        "dialcode": "dialcode part of DDI",
        "number": "number part of DDI"
    },
    "values": {
        "virt_exten": "linked extension number",
        "company": "company"
    }
}
Return value:
{
    "result": "success",
    "numrows": number-of-rows-updated
}

command 'delete'

Path: /rest/ops/delete/
This option requires System-Admin access.
Deletes a DDI from the system completely.
{
    "type": "ddi"
    "scope": {
        "dialcode": "dialcode part of DDI (optional)",
        "number": "number part of DDI (optional)",
        "virt_exten": "linked extension number (optional)",
        "company": "company"
    }
}
Return value:
{
    "result": "success",
    "numrows": rows-deleted
}