Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: Reverted from v. 15

...

Endpoint ID:6011
Method:
Status
colourGreen
titleGET
URL:

/services/phonenumber/format/{phoneNumber}/{phoneNumberFormat=E164}?countryCode={countryCode}&countryCodeFormat={countryCodeFormat}

 phoneNumber

Phone number to be formatted.

Valid examples

  • +4529254029
  • 29254029 (valid only if country code is specified)
  phoneNumberFormat

 Desired format, if not specified default is set to E164.

Valid format options are

  • E164 (Default). A general format for international telephone numbers prefixed with the plus sign (+) and country dial code: +4529254029
  • National. A general format for numbers without a plus sign (+) or country dial code: 29254029
  • International. Similar to E164 with spaces between numbers: +45 29 25 40 29
  • RFC3966. The "tel" URI describes resources identified by telephone numbers: tel:+45-29-25-40-29
  • CustomRubiq. Internal RubiqSoft format: 4529254029
 countryCode

Optional value to identify country of phoneNumber.

 countryCodeFormat 

Optional value to identify countryCode format.

Valid values are

  • ISO2 (ISO 3166-1 alpha-2: two letter country codes)
  • ISO3 (ISO 3166-1 alpha-3: three letter country codes)
  • ISON (ISO 3166-1 numeric: three digit country codes)
  • Internet (top level domain names on web)
  • Custom Rubiq (internal RubiqSoft format)
Request body:None

Span
stylewhite-space:pre

Response body:

JSON data with information of formatted phone number 

 

Code Block
titleExample – Format +4529254029 as IntennationalInternational
{
  	 "phoneNumber": "+45 29 25 40 29"
}

   

Status codes:200

Phone number is formatted successfully.

 400

The following sub codes may be returned:

 

No matching country code found for country code format. 
400.1Invalid phone number.
400.2Phone number must be in E164 format if country code is not specified.
400.3Invalid country code format.
400.4 Invalid phone number formatcountry code. 
 404

400.5

Invalid phone number format.