---
sourceDocument: Xanadu API Reference
sourceDocumentLink: https://servicenow-prod.fluidtopics.net/r/xanadu/api-reference

 Release :

    - xanadu

ft:locale :

    - en-US

ft:publication_title :

    - Xanadu API Reference

ft:clusterId :

    - crapiref

bundleId :

    - crapiref

workflow :

    - Creator


---

# NotifyPhoneNumber - Global

# NotifyPhoneNumber - Global {#ariaid-title1}

* Release version: Xanadu
* 
* Updated August 1, 2024
* 
* ![](https://www.servicenow.com/docs/portal-asset/ico-clock) 6 minutes to read

The NotifyPhoneNumber API allows you to query information about a
Notify phone number.

Access the global NotifyPhoneNumber class and its associated methods in the
`SNC` namespace.

## NotifyPhoneNumber - getDialCode() {#ariaid-title2}

Returns the international dialing code for a Notify phone number.
{#r_NPN-getDialCode__table_n4g_jp4_wr__entry__3}

| Name | Type | Description |
|-|-|-|
| None |   |   |
[Table 1. Parameters]

{#r_NPN-getDialCode__table_n4g_jp4_wr} {#r_NPN-getDialCode__table_o4g_jp4_wr__entry__2}

| Type | Description |
|-|-|
| String | International phone code for a country. |
[Table 2. Returns]

{#r_NPN-getDialCode__table_o4g_jp4_wr}  
This example shows how to obtain the dial code for a phone number.

    var numbers = SNC.Notify.getPhoneNumbers();
     
    // Here numbers is of type List
    if (numbers.size() > 0) {
       var number = numbers.get(0);
     
       // Here number is of type NotifyPhoneNumber
      gs.info(number.getDialCode());
    }

### Scoped equivalent {#r_NPN-getDialCode__section_x32_ysl_1gb}

To use the getDialCode() method in a scoped application, use the
corresponding scoped method: [Scoped NotifyPhoneNumber -
getDialCode()](https://servicenow-prod.fluidtopics.net/NdEOh~xDikwAK6FYj~Bz0A#NPNScoped-getDialCode "Returns the international dialing code for a Notify phone number.").

## NotifyPhoneNumber - getID() {#ariaid-title3}

Returns the ID of this phone number as defined by the telephony provider.
{#r_NPN-getID__table_l5l_lp4_wr__entry__3}

| Name | Type | Description |
|-|-|-|
| None |   |   |
[Table 3. Parameters]

{#r_NPN-getID__table_l5l_lp4_wr} {#r_NPN-getID__table_m5l_lp4_wr__entry__2}

| Type | Description |
|-|-|
| String | Identifier of the number within the telephony provider. |
[Table 4. Returns]

{#r_NPN-getID__table_m5l_lp4_wr}  
This example shows how to obtain the unique identifier for a phone number.

    var numbers = SNC.NotifyScoped.getPhoneNumbers();
     
    // Here numbers is of type List
    if (numbers.size() > 0) {
       var number = numbers.get(0);
     
       // Here number is of type NotifyPhoneNumber
      gs.info(number.getID());
    }

### Scoped equivalent {#r_NPN-getID__section_x32_ysl_1gb}

To use the getID() method in a scoped application, use the corresponding
scoped method: [Scoped NotifyPhoneNumber -
getID()](https://servicenow-prod.fluidtopics.net/NdEOh~xDikwAK6FYj~Bz0A#NPNScoped-getID "Returns the ID of this phone number as defined by the telephony provider.").

## NotifyPhoneNumber - getNumber() {#ariaid-title4}

Returns the numerical phone number for the current Notify caller.
{#r_NPN-getNumber__table_nxr_gp4_wr__entry__3}

| Name | Type | Description |
|-|-|-|
| None |   |   |
[Table 5. Parameters]

{#r_NPN-getNumber__table_nxr_gp4_wr} {#r_NPN-getNumber__table_oxr_gp4_wr__entry__2}

| Type | Description |
|-|-|
| String | E.164-compliant phone number. |
[Table 6. Returns]

{#r_NPN-getNumber__table_oxr_gp4_wr}  
This example shows how to obtain a Notify caller's phone number.

    var numbers = SNC.Notify.getPhoneNumbers();
     
    // Here numbers is of type List
    if (numbers.size() > 0) {
       var number = numbers.get(0);
     
       // Here number is of type NotifyPhoneNumber
      gs.info(number.getNumber());
    }

### Scoped equivalent {#r_NPN-getNumber__section_x32_ysl_1gb}

To use the getNumber() method in a scoped application, use the
corresponding scoped method: [Scoped NotifyPhoneNumber -
getNumber()](https://servicenow-prod.fluidtopics.net/NdEOh~xDikwAK6FYj~Bz0A#NPNScoped-getNumber "Returns the numerical phone number for the current Notify caller.").

## NotifyPhoneNumber - getOwner() {#ariaid-title5}

Returns the telephony provider associated with this phone number.
{#r_NPN-getOwner__table_by2_mp4_wr__entry__3}

| Name | Type | Description |
|-|-|-|
| None |   |   |
[Table 7. Parameters]

{#r_NPN-getOwner__table_by2_mp4_wr} {#r_NPN-getOwner__table_cy2_mp4_wr__entry__2}

| Type | Description |
|-|-|
| String | Telephony provider associated with the number: Twilio. |
[Table 8. Returns]

{#r_NPN-getOwner__table_cy2_mp4_wr}  
This example shows how to obtain the telephony provide that owns the specified phone
number.

    var numbers = SNC.Notify.getPhoneNumbers();
     
    // Here numbers is of type List
    if (numbers.size() > 0) {
       var number = numbers.get(0);
     
       // Here number is of type NotifyPhoneNumber
      gs.info(number.getOwner());
    }

### Scoped equivalent {#r_NPN-getOwner__section_x32_ysl_1gb}

To use the getOwner() method in a scoped application, use the
corresponding scoped method: [Scoped NotifyPhoneNumber -
getOwner()](https://servicenow-prod.fluidtopics.net/NdEOh~xDikwAK6FYj~Bz0A#NPNScoped-getOwner "Returns the telephony provider associated with this phone number.").

## NotifyPhoneNumber - getTerritory() {#ariaid-title6}

Returns the country associated with the phone number.
{#r_NPN-getTerritory__table_dhg_kp4_wr__entry__3}

| Name | Type | Description |
|-|-|-|
| None |   |   |
[Table 9. Parameters]

{#r_NPN-getTerritory__table_dhg_kp4_wr} {#r_NPN-getTerritory__table_ehg_kp4_wr__entry__2}

| Type | Description |
|-|-|
| String | Name of the country to which the phone number belongs. |
[Table 10. Returns]

{#r_NPN-getTerritory__table_ehg_kp4_wr}  
This example shows how to obtain the country of a Notify caller.

    var numbers = SNC.Notify.getPhoneNumbers();
     
    // Here numbers is of type List
    if (numbers.size() > 0) {
       var number = numbers.get(0);
     
       // Here number is of type NotifyPhoneNumber
      gs.info(number.getTerritory());
    }

### Scoped equivalent {#r_NPN-getTerritory__section_x32_ysl_1gb}

To use the getTerritory() method in a scoped application, use the
corresponding scoped method: [Scoped NotifyPhoneNumber -
getTerritory()](https://servicenow-prod.fluidtopics.net/NdEOh~xDikwAK6FYj~Bz0A#NPNScoped-getTerritory "Returns the country associated with the phone number.").

## NotifyPhoneNumber - isShortCode() {#ariaid-title7}

Determines whether the current Notify phone number is a short code.
{#NPN-isShortCode__table_lgj_csx_zfb__entry__3}

| Name | Type | Description |
|-|-|-|
| None |   |   |
[Table 11. Parameters]

{#NPN-isShortCode__table_lgj_csx_zfb} {#NPN-isShortCode__table_mgj_csx_zfb__entry__2}

| Type | Description |
|-|-|
| Boolean | Flag that indicates whether the current Notify phone number is a short code. * true: phone number is a short code. * false: phone number is not a short code. {#NPN-isShortCode__ul_ghr_ksx_zfb} |
[Table 12. Returns]

{#NPN-isShortCode__table_mgj_csx_zfb}  
This example shows how to check if the current Notify phone number is a short code.

    GlideRecord notifyNumber = new GlideRecord(TABLE_NOTIFY_NUMBER);
    notifyNumber.query(COL_NUMBER, notifyPhoneNumber.getNumber());

    if (!notifyNumber.next()) {
      notifyNumber.initialize();
      notifyNumber.setValue(COL_OWNER, notifyPhoneNumber.getOwner());
      if (notifyPhoneNumber.isShortCode()) {
        notifyNumber.setValue(COL_SHORT_CODE, notifyPhoneNumber.getNumber());
      } else {
        notifyNumber.setValue(COL_PHONE_NUMBER, notifyPhoneNumber.getNumber());
      }

## NotifyPhoneNumber - supportsConferenceCall() {#ariaid-title8}

Determines if the Notify phone number supports conference calling.
{#r_NPN-supportsConferenceCall__table_ccj_qp4_wr__entry__3}

| Name | Type | Description |
|-|-|-|
| None |   |   |
[Table 13. Parameters]

{#r_NPN-supportsConferenceCall__table_ccj_qp4_wr} {#r_NPN-supportsConferenceCall__table_dcj_qp4_wr__entry__2}

| Type | Description |
|-|-|
| Boolean | Value that indicates whether the Notify phone number supports conference calling. * true: phone number does support conference calling * false: phone number does not support conference calling {#r_NPN-supportsConferenceCall__ul_xkc_qmv_bgb} |
[Table 14. Returns]

{#r_NPN-supportsConferenceCall__table_dcj_qp4_wr}  
This example shows how to determine if a Notify caller supports conference calls.

    var numbers = SNC.Notify.getPhoneNumbers();
     
    // Here numbers is of type List
    if (numbers.size() > 0) {
       var number = numbers.get(0);
     
       // Here number is of type NotifyPhoneNumber
      gs.info(number.supportsConferenceCall());
    }

### Scoped equivalent {#r_NPN-supportsConferenceCall__section_x32_ysl_1gb}

To use the supportsConferenceCall() method in a scoped application, use the
corresponding scoped method: [Scoped NotifyPhoneNumber -
supportsConferenceCall()](https://servicenow-prod.fluidtopics.net/NdEOh~xDikwAK6FYj~Bz0A#NPNScoped-supportsConferenceCall "Determines if the Notify phone number supports conference calls.").

## NotifyPhoneNumber - supportsIncomingPhoneCall() {#ariaid-title9}

Determines if the Notify phone number supports receiving phone calls.
{#r_NPN-supportsIncomingPhoneCall__table_tll_np4_wr__entry__3}

| Name | Type | Description |
|-|-|-|
| None |   |   |
[Table 15. Parameters]

{#r_NPN-supportsIncomingPhoneCall__table_tll_np4_wr} {#r_NPN-supportsIncomingPhoneCall__table_ull_np4_wr__entry__2}

| Type | Description |
|-|-|
| Boolean | Value that indicates whether the Notify phone number supports incoming phone calls. * true: phone number does support incoming phone calls * false: phone number does not support incoming phone calls {#r_NPN-supportsIncomingPhoneCall__ul_xkc_qmv_bgb} |
[Table 16. Returns]

{#r_NPN-supportsIncomingPhoneCall__table_ull_np4_wr}  
This example shows how to determine if a Notify caller can receive incoming phone
calls.

    var numbers = SNC.Notify.getPhoneNumbers();
     
    // Here numbers is of type List
    if (numbers.size() > 0) {
       var number = numbers.get(0);
     
       // Here number is of type NotifyPhoneNumber
      gs.info(number.supportsIncomingPhoneCall());
    }

### Scoped equivalent {#r_NPN-supportsIncomingPhoneCall__section_x32_ysl_1gb}

To use the supportsIncomingPhoneCall() method in a scoped application,
use the corresponding scoped method: [Scoped NotifyPhoneNumber -
supportsIncomingPhoneCall()](https://servicenow-prod.fluidtopics.net/NdEOh~xDikwAK6FYj~Bz0A#NPNScoped-supportsIncomingPhoneCall "Determines if the Notify phone number supports receiving phone calls.").

## NotifyPhoneNumber - supportsIncomingSMS() {#ariaid-title10}

Determines if the Notify phone number supports receiving SMS messages.
{#r_NPN-supportsIncomingSMS__table_w1k_rp4_wr__entry__3}

| Name | Type | Description |
|-|-|-|
| None |   |   |
[Table 17. Parameters]

{#r_NPN-supportsIncomingSMS__table_w1k_rp4_wr} {#r_NPN-supportsIncomingSMS__table_x1k_rp4_wr__entry__2}

| Type | Description |
|-|-|
| Boolean | Value that indicates whether the Notify phone number supports receiving incoming MMS messages. * true: phone number does support receiving incoming MMS messages * false: phone number does not support receiving incoming MMS messages {#r_NPN-supportsIncomingSMS__ul_xkc_qmv_bgb} |
[Table 18. Returns]

{#r_NPN-supportsIncomingSMS__table_x1k_rp4_wr}  
This example shows how to determine if a Notify caller can receive incoming SMS
messages.

    var numbers = SNC.Notify.getPhoneNumbers();
     
    // Here numbers is of type List
    if (numbers.size() > 0) {
       var number = numbers.get(0);
     
       // Here number is of type NotifyPhoneNumber
      gs.info(number.supportsIncomingSMS());
    }

### Scoped equivalent {#r_NPN-supportsIncomingSMS__section_x32_ysl_1gb}

To use the supportsIncomingSMS() method in a scoped application,
use the corresponding scoped method: [Scoped NotifyPhoneNumber -
supportsIncomingSMS()](https://servicenow-prod.fluidtopics.net/NdEOh~xDikwAK6FYj~Bz0A#NPNScoped-supportsIncomingSMS "Determines if the Notify phone number supports receiving SMS messages.").

## NotifyPhoneNumber - supportsOutgoingPhoneCall() {#ariaid-title11}

Determines if the Notify phone number supports initiating phone calls.
{#r_NPN-supportsOutgoingPhoneCall__table_m5l_4p4_wr__entry__3}

| Name | Type | Description |
|-|-|-|
| None |   |   |
[Table 19. Parameters]

{#r_NPN-supportsOutgoingPhoneCall__table_m5l_4p4_wr} {#r_NPN-supportsOutgoingPhoneCall__table_n5l_4p4_wr__entry__2}

| Type | Description |
|-|-|
| Boolean | Value that indicates whether the Notify phone number supports initiating outgoing phone calls. * true: phone number does support initiating outgoing phone calls * false: phone number does not support initiating outgoing phone calls {#r_NPN-supportsOutgoingPhoneCall__ul_xkc_qmv_bgb} |
[Table 20. Returns]

{#r_NPN-supportsOutgoingPhoneCall__table_n5l_4p4_wr}  
This example shows how to determine if a Notify caller can make outgoing phone calls.

    var numbers = SNC.Notify.getPhoneNumbers();
     
    // Here numbers is of type List
    if (numbers.size() > 0) {
       var number = numbers.get(0);
     
       // Here number is of type NotifyPhoneNumber
      gs.info(number.supportsOutgoingPhoneCall());
    }

### Scoped equivalent {#r_NPN-supportsOutgoingPhoneCall__section_x32_ysl_1gb}

To use the supportsOutgoingPhoneCall() method in a scoped application,
use the corresponding scoped method: [Scoped NotifyPhoneNumber -
supportsOutgoingPhoneCall()](https://servicenow-prod.fluidtopics.net/NdEOh~xDikwAK6FYj~Bz0A#NPNScoped-supportsOutgoingPhoneCall "Determines if the Notify phone number supports initiating phone calls.").

## NotifyPhoneNumber - supportsOutgoingSMS() {#ariaid-title12}

Determines if the Notify phone number supports sending SMS messages.
{#r_NPN-supportsOutgoingSMS__table_gv1_tp4_wr__entry__3}

| Name | Type | Description |
|-|-|-|
| None |   |   |
[Table 21. Parameters]

{#r_NPN-supportsOutgoingSMS__table_gv1_tp4_wr} {#r_NPN-supportsOutgoingSMS__table_hv1_tp4_wr__entry__2}

| Type | Description |
|-|-|
| Boolean | Value that indicates whether the Notify phone number supports sending SMS messages. * true: phone number does support sending SMS messages * false: phone number does not support sending SMS messages {#r_NPN-supportsOutgoingSMS__ul_xkc_qmv_bgb} |
[Table 22. Returns]

{#r_NPN-supportsOutgoingSMS__table_hv1_tp4_wr}  
This example shows how to determine if a Notify caller can initiate outgoing SMS
messages.

    var numbers = SNC.Notify.getPhoneNumbers();
     
    // Here numbers is of type List
    if (numbers.size() > 0) {
       var number = numbers.get(0);
     
       // Here number is of type NotifyPhoneNumber
      gs.info(number.supportsOutgoingSMS());
    }

### Scoped equivalent {#r_NPN-supportsOutgoingSMS__section_x32_ysl_1gb}

To use the supportsOutgoingSMS() method in a scoped application, use the
corresponding scoped method: [Scoped NotifyPhoneNumber -
supportsOutgoingSMS()](https://servicenow-prod.fluidtopics.net/NdEOh~xDikwAK6FYj~Bz0A#NPNScoped-supportsOutgoingSMS "Determines if the Notify phone number supports sending SMS messages.").

## NotifyPhoneNumber - supportsRecording() {#ariaid-title13}

Determines if the Notify phone number supports recording phone calls.
{#r_NPN-supportsRecording__table_fzm_wp4_wr__entry__3}

| Name | Type | Description |
|-|-|-|
| None |   |   |
[Table 23. Parameters]

{#r_NPN-supportsRecording__table_fzm_wp4_wr} {#r_NPN-supportsRecording__table_gzm_wp4_wr__entry__2}

| Type | Description |
|-|-|
| Boolean | Value that indicates whether the Notify phone number supports recording phone calls. * true: phone number does support recording phone calls * false: phone number does not support recording phone calls {#r_NPN-supportsRecording__ul_xkc_qmv_bgb} |
[Table 24. Returns]

{#r_NPN-supportsRecording__table_gzm_wp4_wr}  
This example shows how to determine if a Notify caller can record calls.

    var numbers = SNC.Notify.getPhoneNumbers();
     
    // Here numbers is of type List
    if (numbers.size() > 0) {
       var number = numbers.get(0);
     
       // Here number is of type NotifyPhoneNumber
      gs.info(number.supportsRecording());
    }

### Scoped equivalent {#r_NPN-supportsRecording__section_x32_ysl_1gb}

To use the supportsRecording() method in a scoped application, use the
corresponding scoped method: [Scoped NotifyPhoneNumber -
supportsRecording()](https://servicenow-prod.fluidtopics.net/NdEOh~xDikwAK6FYj~Bz0A#NPNScoped-supportsRecording "Determines if the Notify phone number supports recording phone calls.").

## NotifyPhoneNumber - supportsWebRTC() {#ariaid-title14}

Determines if the Notify phone number supports calls to a browser, such as in a WebRTC
implementation.
{#r_NPN-supportsWebRTC__table_kfq_vp4_wr__entry__3}

| Name | Type | Description |
|-|-|-|
| None |   |   |
[Table 25. Parameters]

{#r_NPN-supportsWebRTC__table_kfq_vp4_wr} {#r_NPN-supportsWebRTC__table_lfq_vp4_wr__entry__2}

| Type | Description |
|-|-|
| Boolean | Value that indicates whether the Notify phone number supports calls to a browser. * true: phone number does support calls to a browser * false: phone number does not support calls to a browser {#r_NPN-supportsWebRTC__ul_xkc_qmv_bgb} |
[Table 26. Returns]

{#r_NPN-supportsWebRTC__table_lfq_vp4_wr}  
This example shows how to determine if a Notify caller can initiate/accept
browser-to-browser calls.

    var numbers = SNC.Notify.getPhoneNumbers();
     
    // Here numbers is of type List
    if (numbers.size() > 0) {
       var number = numbers.get(0);
     
       // Here number is of type NotifyPhoneNumber
      gs.info(number.supportsWebRTC());
    }

### Scoped equivalent {#r_NPN-supportsWebRTC__section_x32_ysl_1gb}

To use the supportsWebRTC() method in a scoped application, use the
corresponding scoped method: [Scoped NotifyPhoneNumber -
supportsWebRTC()](https://servicenow-prod.fluidtopics.net/NdEOh~xDikwAK6FYj~Bz0A#NPNScoped-supportsWebRTC "Determines if the Notify phone number supports calls to a browser, such as in a WebRTC implementation.").

