Table of Contents

API : SBC Rule Get

Introduction

This request will return an outbound routing rule.

Request

URL https://api.telecomx.dk/sbc/rule/RULE_ID
Method GET
Access level RESELLER_ADMIN, ADMIN.
Param RULE_ID Id of the rule (24-char hex string).

Query examples

https://api.telecomx.dk/sbc/rule/650000000000000000000101

Response

The response is a rule object, or null when no rule has that id.

Rule object (JSON)
_id Id Id of the rule.
type String Type of rule: PREFIX, ANUMBER, CUSTOMER, DKCPS.
condition String Condition to be met for rule to be applied:
PREFIX - Prefix of full E.164 number, e.g. +462
ANUMBER - Callers number in E.164 format, e.g. +4570305050
CUSTOMER - Id of calling customer, a lowercase 24-character hex string, e.g. 650000000000000000000201
DKCPS - CPS code of destination service operator, e.g. 01011
peer String Id of the peer to send outbound calls to if the rule is matched.
note String Note about the rule.

Note that properties holding no value may be omitted from the object.

Response example

{
  "_id": "650000000000000000000101",
  "type": "PREFIX",
  "condition": "+462",
  "peer": "SuperTel",
  "note": null
}

Errors

Error code Message Description
403 access_denied Insufficient access level
500 internal_error <Unspecified>