Table of Contents

API : DK Operator Create

Introduction

This request will create a Danish Telecom Operator.

Request

URL https://api.telecomx.dk/dk/operator
Method POST
Access level ADMIN.
Body _id String Service Operator 5 digit CPS code.
name String Name of operator.
address String Postal address.
npNumber String [optional] Number porting service number.
npFax String [optional] Number porting fax number.
npEmail String [optional] Number porting e-mail address.
npOpeningHours String [optional] When is number porting open for personal contact.
notes String [optional] Notes about the operator.
fixedAuth String How to auth for fixed lines: FAX or EMAIL.
mvnoAuth String How to auth for mvno: ICC, ICC_FAX, ICC_EMAIL, FAX or EMAIL.
iccValidation String [optional] If using ICC validation, this is the RegEx to validate input with.
customerIdValidation Boolean [optional] True if operator requires customer id validation. Defaults to false.

Query examples

{
  "_id": "01234",
  "name": "Operator ApS",
  "address": "Eksempelvej 1, 2500 Valby",
  "npNumber": "+4571919900",
  "npFax": "+4571919901",
  "npEmail": "np@example.dk",
  "npOpeningHours": "man-fre 8:00-16:00",
  "notes": "Contact the porting desk by e-mail",
  "fixedAuth": "EMAIL",
  "mvnoAuth": "ICC_EMAIL",
  "iccValidation": "^894501\\d{13}$",
  "customerIdValidation": false
}

Response

The newly created operator.

JSON object
_id String Service Operator 5 digit CPS code.
name String Name of operator.
address String Postal address.
npNumber String [optional] Number porting service number.
npFax String [optional] Number porting fax number.
npEmail String [optional] Number porting e-mail address.
npOpeningHours String [optional] When is number porting open for personal contact.
notes String [optional] Notes about the operator.
fixedAuth String How to auth for fixed lines: FAX or EMAIL.
mvnoAuth String How to auth for mvno: ICC, ICC_FAX, ICC_EMAIL, FAX or EMAIL.
iccValidation String [optional] If using ICC validation, this is the RegEx to validate input with.
customerIdValidation Boolean True if operator requires customer id validation.
shortCode Integer Server-assigned operator code (0–255). Read-only.

Example

{
  "_id": "01234",
  "name": "Operator ApS",
  "address": "Eksempelvej 1, 2500 Valby",
  "npNumber": "+4571919900",
  "npFax": "+4571919901",
  "npEmail": "np@example.dk",
  "npOpeningHours": "man-fre 8:00-16:00",
  "notes": "Contact the porting desk by e-mail",
  "fixedAuth": "EMAIL",
  "mvnoAuth": "ICC_EMAIL",
  "iccValidation": "^894501\\d{13}$",
  "customerIdValidation": false,
  "shortCode": 20
}

Errors

Error code Message Description
404 _id Id is missing
404 name Name is missing
404 address Address is missing
404 fixedAuth Fixed authentication method is missing
404 mvnoAuth MVNO authentication method is missing
422 _id 5-digit operator code
422 npNumber NP phone number is not a valid phone number
422 npFax NP fax number is not a valid phone number
422 npEmail NP e-mail address is not a valid e-mail address
422 fixedAuth Fixed authentication method is not recognized
422 mvnoAuth MVNO authentication method is not recognized
422 customerIdValidation Value is not a valid boolean
409 _id Operator already exists
409 shortCode No more shortcodes available - need to delete operators first
403 access_denied Insufficient access level
500 internal_error <Unspecified>