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

 Release :

    - xanadu

ft:locale :

    - de-DE

ft:publication_title :

    - Xanadu-API-Referenz

ft:clusterId :

    - crapiref

bundleId :

    - crapiref

workflow :

    - Creator


---

# MIDServer : Global

# MIDServer : Global {#ariaid-title1}

* Freigeben Version: Xanadu
* 
* Aktualisiert 1. August 2024
* 
* ![](https://www.servicenow.com/docs/portal-asset/ico-clock) 19 Minuten Lesedauer

Die MIDServer-Skripteinbindung stellt Methoden bereit, um das Konzept eines MID-Serverzu kapseln.

Verwenden Sie diese Methoden in Serverskripts, um ein MID-Server mit Ajax zu verwalten.

## MIDServer -- getByName(String name) {#ariaid-title2}

Gibt den angegebenen MID-Server zurück.
{#r_MSVR-getByName_S__table_j3v_5tf_zt__entry__3}

| Name | Typ | Beschreibung |
|-|-|-|
| Name | Zeichenfolge | Der Name des MID-Servers |
[Tabelle : 1. Parameter]

{#r_MSVR-getByName_S__table_j3v_5tf_zt} {#r_MSVR-getByName_S__table_k3v_5tf_zt__entry__2}

| Typ | Beschreibung |
|-|-|
| GlideRecord | Der Datensatz des angeforderten MID-Servers. |
[Tabelle : 2. Ergebnisse]

{#r_MSVR-getByName_S__table_k3v_5tf_zt}  
Das folgende Beispiel zeigt, wie Sie auf MID-Server-Details zugreifen und sie anzeigen können.

    // Get a mid server object by name
    var ms = MIDServer.getByName("windows_mid");

    // Stringify the object for display purposes
    gs.info(JSON.stringify(ms, null, 2));

    // Show the value of each API property 
    gs.info('hostmane ' + ms.hostname);
    gs.info('hostOS ' + ms.hostOS);
    gs.info('ip ' + ms.ip);
    gs.info('name ' + ms.name);
    gs.info('routerIP ' + ms.routerIP);
    gs.info('status ' + ms.status);
    gs.info('sysID ' + ms.sysID);
    gs.info('url ' + ms.url);
    gs.info('version ' + ms.version);
    gs.info('windowsDomain ' + ms.windowsDomain);

Ausgabe:

    *** Script: {
      "valid": true,
      "sysID": "3cb25f0f874b3410c3a99999cebb35ba",
      "name": "windows_mid",
      "url": null,
      "hostname": "myHostname.service-now.com",
      "hostOS": "Windows",
      "version": "fixed",
      "ip": "10.11.128.184",
      "routerIP": "10.11.128.1",
      "network": "10.11.128.0/22",
      "windowsDomain": null,
      "status": "Up",
      "validated": "true",
      "userName": "MID_Profile"
    }
    *** Script: hostname myHostname.service-now.com
    *** Script: hostOS Windows
    *** Script: ip 10.11.128.184
    *** Script: name windows_mid
    *** Script: routerIP 10.11.128.1
    *** Script: status Up
    *** Script: sysID 3cb25f0f874b3410c3a99999cebb35ba
    *** Script: url null
    *** Script: version fixed
    *** Script: windowsDomain null

## MIDServer -- getDefault(DiscoverySchedule schedule) {#ariaid-title3}

Gibt den MID-Server zurück, der dem angegebenen Zeitplan zugeordnet ist (der MID-Server mit demselben Namen). Wenn kein MID-Server zugeordnet ist, wird der nächste MID-Server in der Tabelle „ecc_agent" abgerufen.
{#r_MSVR-getDefault_S__table_jpd_gvf_zt__entry__3}

| Name | Typ | Beschreibung |
|-|-|-|
| schedule | DiscoverySchedule | Der Discovery-Zeitplan |
[Tabelle : 3. Parameter]

{#r_MSVR-getDefault_S__table_jpd_gvf_zt} {#r_MSVR-getDefault_S__table_kpd_gvf_zt__entry__2}

| Typ | Beschreibung |
|-|-|
| GlideRecord | Der MID-Server |
[Tabelle : 4. Ergebnisse]

{#r_MSVR-getDefault_S__table_kpd_gvf_zt}

## MIDServer -- getForPing(DiscoverySchedule schedule, DiscoveryRange range) {#ariaid-title4}

Gibt den MID-Server mit dem angegebenen Zeitplan und Bereichssatz zurück.
{#r_MSVR-getForPing_S_S__table_vp1_t5f_zt__entry__3}

| Name | Typ | Beschreibung |
|-|-|-|
| schedule | DiscoverySchedule | Der Discovery-Zeitplan |
| range | DiscoveryRange | Der Discovery-Bereichssatz |
[Tabelle : 5. Parameter]

{#r_MSVR-getForPing_S_S__table_vp1_t5f_zt} {#r_MSVR-getForPing_S_S__table_wp1_t5f_zt__entry__2}

| Typ | Beschreibung |
|-|-|
| GlideRecord | Der MID-Server |
[Tabelle : 6. Ergebnisse]

{#r_MSVR-getForPing_S_S__table_wp1_t5f_zt}

## MIDServer -- hostname {#ariaid-title5}

Der Name des Hosts des MID-Servers.
{#r_MSVR-hostname__table_yrz_mk1_t5__entry__3}

| Name | Typ | Beschreibung |
|-|-|-|
| hostname | Zeichenfolge | Der Name des Hosts des MID-Servers. |
[Tabelle : 7. Feld]

{#r_MSVR-hostname__table_yrz_mk1_t5}  
Das folgende Beispiel zeigt, wie alle Parameter eines verfügbaren MID-Servers ausgeführt und zurückgegeben werden.

    var getMIDServerAttributes = new MIDServer(<mid_sys_id>); //Pass the sys id of the MID server record
    var midServerHostname = getMIDServerAttributes.hostname; //would return the Host name of the MID Server Record
    var midServerHostOS = getMIDServerAttributes.hostOS; // would return the Host OS of the MID Server Record
    var midServerIP = getMIDServerAttributes.ip; //would return the IP of the MID Server Record
    var midServerName = getMIDServerAttributes.name; //would return the Name of the MID Server Record
    var midServerRouterIP = getMIDServerAttributes.routerIP; //would return the router IP of the MID Server Record
    var midServerStatus = getMIDServerAttributes.status; //would return the status of the MID Server Record (UP or Down)
    var midServerSysID = getMIDServerAttributes.sysID; // Would return the Sys ID of the MID server record
    var midServerURL = getMIDServerAttributes.url; // Would return the URL of the MID server record
    var midServerVersion = getMIDServerAttributes.version; // Would return ServiceNow release version of the MID server record
    var midServerwindowsDomain = getMIDServerAttributes.windowsDomain; // Would return windows domain of the MID server record

    gs.info("\nMID Server Host Name - "+ midServerHostname +"\nMid Server Host OS - " + midServerHostOS + "\nMID Server IP - "+ midServerIP + "
    \nMID Server Name - " + midServerName + "\nMID Server Router IP - " + midServerRouterIP + "\nMID Server Status - " +  midServerStatus  + 
    "\nMID Server SYS ID - " + midServerSysID  + "\nMID Server URL - " + midServerURL  + "\nMID Server Version - " + midServerVersion + 
    "\nMID Server Windows Domain - " + midServerwindowsDomain);

{#r_MSVR-hostname__midserverAPI_example1_cb}

Ausgabe:

    MID Server Host Name - midSvrName.service-now.com
    Mid Server Host OS - Windows
    MID Server IP - 10.11.999.999
    MID Server Name - Windows MID
    MID Server Router IP - 10.11.111.1
    MID Server Status - Up
    MID Server SYS ID - <mid_sys_id>
    MID Server URL - null
    MID Server Version - fixed
    MID Server Windows Domain - null

q

## MIDServer -- hostOS {#ariaid-title6}

Das Betriebssystem des Hosts des MID-Servers.
{#r_MSVR-hostOS__table_bky_vk1_t5__entry__3}

| Name | Typ | Beschreibung |
|-|-|-|
| hostOS | Zeichenfolge | Das Betriebssystem des Hosts des MID-Servers. |
[Tabelle : 8. Feld]

{#r_MSVR-hostOS__table_bky_vk1_t5}  
Das folgende Beispiel zeigt, wie alle Parameter eines verfügbaren MID-Servers ausgeführt und zurückgegeben werden.

    var getMIDServerAttributes = new MIDServer(<mid_sys_id>); //Pass the sys id of the MID server record
    var midServerHostname = getMIDServerAttributes.hostname; //would return the Host name of the MID Server Record
    var midServerHostOS = getMIDServerAttributes.hostOS; // would return the Host OS of the MID Server Record
    var midServerIP = getMIDServerAttributes.ip; //would return the IP of the MID Server Record
    var midServerName = getMIDServerAttributes.name; //would return the Name of the MID Server Record
    var midServerRouterIP = getMIDServerAttributes.routerIP; //would return the router IP of the MID Server Record
    var midServerStatus = getMIDServerAttributes.status; //would return the status of the MID Server Record (UP or Down)
    var midServerSysID = getMIDServerAttributes.sysID; // Would return the Sys ID of the MID server record
    var midServerURL = getMIDServerAttributes.url; // Would return the URL of the MID server record
    var midServerVersion = getMIDServerAttributes.version; // Would return ServiceNow release version of the MID server record
    var midServerwindowsDomain = getMIDServerAttributes.windowsDomain; // Would return windows domain of the MID server record

    gs.info("\nMID Server Host Name - "+ midServerHostname +"\nMid Server Host OS - " + midServerHostOS + "\nMID Server IP - "+ midServerIP + "
    \nMID Server Name - " + midServerName + "\nMID Server Router IP - " + midServerRouterIP + "\nMID Server Status - " +  midServerStatus  + 
    "\nMID Server SYS ID - " + midServerSysID  + "\nMID Server URL - " + midServerURL  + "\nMID Server Version - " + midServerVersion + 
    "\nMID Server Windows Domain - " + midServerwindowsDomain);

{#r_MSVR-hostOS__midserverAPI_example1_cb}

Ausgabe:

    MID Server Host Name - midSvrName.service-now.com
    Mid Server Host OS - Windows
    MID Server IP - 10.11.999.999
    MID Server Name - Windows MID
    MID Server Router IP - 10.11.111.1
    MID Server Status - Up
    MID Server SYS ID - <mid_sys_id>
    MID Server URL - null
    MID Server Version - fixed
    MID Server Windows Domain - null

## MIDServer -- ip {#ariaid-title7}

Die IP-Adresse des Hosts des MID-Servers.
{#r_MSVR-ip__table_brg_nl1_t5__entry__3}

| Name | Typ | Beschreibung |
|-|-|-|
| ip | Zeichenfolge | Die IP-Adresse des Hosts des MID-Servers. |
[Tabelle : 9. Feld]

{#r_MSVR-ip__table_brg_nl1_t5}  
Das folgende Beispiel zeigt, wie alle Parameter eines verfügbaren MID-Servers ausgeführt und zurückgegeben werden.

    var getMIDServerAttributes = new MIDServer(<mid_sys_id>); //Pass the sys id of the MID server record
    var midServerHostname = getMIDServerAttributes.hostname; //would return the Host name of the MID Server Record
    var midServerHostOS = getMIDServerAttributes.hostOS; // would return the Host OS of the MID Server Record
    var midServerIP = getMIDServerAttributes.ip; //would return the IP of the MID Server Record
    var midServerName = getMIDServerAttributes.name; //would return the Name of the MID Server Record
    var midServerRouterIP = getMIDServerAttributes.routerIP; //would return the router IP of the MID Server Record
    var midServerStatus = getMIDServerAttributes.status; //would return the status of the MID Server Record (UP or Down)
    var midServerSysID = getMIDServerAttributes.sysID; // Would return the Sys ID of the MID server record
    var midServerURL = getMIDServerAttributes.url; // Would return the URL of the MID server record
    var midServerVersion = getMIDServerAttributes.version; // Would return ServiceNow release version of the MID server record
    var midServerwindowsDomain = getMIDServerAttributes.windowsDomain; // Would return windows domain of the MID server record

    gs.info("\nMID Server Host Name - "+ midServerHostname +"\nMid Server Host OS - " + midServerHostOS + "\nMID Server IP - "+ midServerIP + "
    \nMID Server Name - " + midServerName + "\nMID Server Router IP - " + midServerRouterIP + "\nMID Server Status - " +  midServerStatus  + 
    "\nMID Server SYS ID - " + midServerSysID  + "\nMID Server URL - " + midServerURL  + "\nMID Server Version - " + midServerVersion + 
    "\nMID Server Windows Domain - " + midServerwindowsDomain);

{#r_MSVR-ip__midserverAPI_example1_cb}

Ausgabe:

    MID Server Host Name - midSvrName.service-now.com
    Mid Server Host OS - Windows
    MID Server IP - 10.11.999.999
    MID Server Name - Windows MID
    MID Server Router IP - 10.11.111.1
    MID Server Status - Up
    MID Server SYS ID - <mid_sys_id>
    MID Server URL - null
    MID Server Version - fixed
    MID Server Windows Domain - null

## MIDServer -- name {#ariaid-title8}

Der Name des MID-Servers.
{#r_MSVR-name__table_evt_yj1_t5__entry__3}

| Name | Typ | Beschreibung |
|-|-|-|
| Name | Zeichenfolge | Name des MID-Servers |
[Tabelle : 10. Feld]

{#r_MSVR-name__table_evt_yj1_t5}  
Das folgende Beispiel zeigt, wie alle Parameter eines verfügbaren MID-Servers ausgeführt und zurückgegeben werden.

    var getMIDServerAttributes = new MIDServer(<mid_sys_id>); //Pass the sys id of the MID server record
    var midServerHostname = getMIDServerAttributes.hostname; //would return the Host name of the MID Server Record
    var midServerHostOS = getMIDServerAttributes.hostOS; // would return the Host OS of the MID Server Record
    var midServerIP = getMIDServerAttributes.ip; //would return the IP of the MID Server Record
    var midServerName = getMIDServerAttributes.name; //would return the Name of the MID Server Record
    var midServerRouterIP = getMIDServerAttributes.routerIP; //would return the router IP of the MID Server Record
    var midServerStatus = getMIDServerAttributes.status; //would return the status of the MID Server Record (UP or Down)
    var midServerSysID = getMIDServerAttributes.sysID; // Would return the Sys ID of the MID server record
    var midServerURL = getMIDServerAttributes.url; // Would return the URL of the MID server record
    var midServerVersion = getMIDServerAttributes.version; // Would return ServiceNow release version of the MID server record
    var midServerwindowsDomain = getMIDServerAttributes.windowsDomain; // Would return windows domain of the MID server record

    gs.info("\nMID Server Host Name - "+ midServerHostname +"\nMid Server Host OS - " + midServerHostOS + "\nMID Server IP - "+ midServerIP + "
    \nMID Server Name - " + midServerName + "\nMID Server Router IP - " + midServerRouterIP + "\nMID Server Status - " +  midServerStatus  + 
    "\nMID Server SYS ID - " + midServerSysID  + "\nMID Server URL - " + midServerURL  + "\nMID Server Version - " + midServerVersion + 
    "\nMID Server Windows Domain - " + midServerwindowsDomain);

{#r_MSVR-name__midserverAPI_example1_cb}

Ausgabe:

    MID Server Host Name - midSvrName.service-now.com
    Mid Server Host OS - Windows
    MID Server IP - 10.11.999.999
    MID Server Name - Windows MID
    MID Server Router IP - 10.11.111.1
    MID Server Status - Up
    MID Server SYS ID - <mid_sys_id>
    MID Server URL - null
    MID Server Version - fixed
    MID Server Windows Domain - null

## MIDServer -- network {#ariaid-title9}

Das Netzwerk, das den Host des MID-Servers enthält.
{#r_MSVR-network__table_d3s_dm1_t5__entry__3}

| Name | Typ | Beschreibung |
|-|-|-|
| network | Zeichenfolge | Das Netzwerk, das den Host des MID-Servers enthält. Zum Beispiel „10.10.10.0/24" oder „10.10.10.0/255.255.255.0". |
[Tabelle : 11. Feld]

{#r_MSVR-network__table_d3s_dm1_t5}  
Das folgende Beispiel zeigt, wie alle Parameter eines verfügbaren MID-Servers ausgeführt und zurückgegeben werden.

    var getMIDServerAttributes = new MIDServer(<mid_sys_id>); //Pass the sys id of the MID server record
    var midServerHostname = getMIDServerAttributes.hostname; //would return the Host name of the MID Server Record
    var midServerHostOS = getMIDServerAttributes.hostOS; // would return the Host OS of the MID Server Record
    var midServerIP = getMIDServerAttributes.ip; //would return the IP of the MID Server Record
    var midServerName = getMIDServerAttributes.name; //would return the Name of the MID Server Record
    var midServerRouterIP = getMIDServerAttributes.routerIP; //would return the router IP of the MID Server Record
    var midServerStatus = getMIDServerAttributes.status; //would return the status of the MID Server Record (UP or Down)
    var midServerSysID = getMIDServerAttributes.sysID; // Would return the Sys ID of the MID server record
    var midServerURL = getMIDServerAttributes.url; // Would return the URL of the MID server record
    var midServerVersion = getMIDServerAttributes.version; // Would return ServiceNow release version of the MID server record
    var midServerwindowsDomain = getMIDServerAttributes.windowsDomain; // Would return windows domain of the MID server record

    gs.info("\nMID Server Host Name - "+ midServerHostname +"\nMid Server Host OS - " + midServerHostOS + "\nMID Server IP - "+ midServerIP + "
    \nMID Server Name - " + midServerName + "\nMID Server Router IP - " + midServerRouterIP + "\nMID Server Status - " +  midServerStatus  + 
    "\nMID Server SYS ID - " + midServerSysID  + "\nMID Server URL - " + midServerURL  + "\nMID Server Version - " + midServerVersion + 
    "\nMID Server Windows Domain - " + midServerwindowsDomain);

{#r_MSVR-network__midserverAPI_example1_cb}

Ausgabe:

    MID Server Host Name - midSvrName.service-now.com
    Mid Server Host OS - Windows
    MID Server IP - 10.11.999.999
    MID Server Name - Windows MID
    MID Server Router IP - 10.11.111.1
    MID Server Status - Up
    MID Server SYS ID - <mid_sys_id>
    MID Server URL - null
    MID Server Version - fixed
    MID Server Windows Domain - null

## MIDServer -- routerIP {#ariaid-title10}

Die IP-Adresse des Standardrouters des MID-Server-Hosts.
{#r_MSVR-routerIP__table_tgy_5l1_t5__entry__3}

| Name | Typ | Beschreibung |
|-|-|-|
| routerIP | Zeichenfolge | Die IP-Adresse des Standardrouters des MID-Server-Hosts. |
[Tabelle : 12. Feld]

{#r_MSVR-routerIP__table_tgy_5l1_t5}  
Das folgende Beispiel zeigt, wie alle Parameter eines verfügbaren MID-Servers ausgeführt und zurückgegeben werden.

    var getMIDServerAttributes = new MIDServer(<mid_sys_id>); //Pass the sys id of the MID server record
    var midServerHostname = getMIDServerAttributes.hostname; //would return the Host name of the MID Server Record
    var midServerHostOS = getMIDServerAttributes.hostOS; // would return the Host OS of the MID Server Record
    var midServerIP = getMIDServerAttributes.ip; //would return the IP of the MID Server Record
    var midServerName = getMIDServerAttributes.name; //would return the Name of the MID Server Record
    var midServerRouterIP = getMIDServerAttributes.routerIP; //would return the router IP of the MID Server Record
    var midServerStatus = getMIDServerAttributes.status; //would return the status of the MID Server Record (UP or Down)
    var midServerSysID = getMIDServerAttributes.sysID; // Would return the Sys ID of the MID server record
    var midServerURL = getMIDServerAttributes.url; // Would return the URL of the MID server record
    var midServerVersion = getMIDServerAttributes.version; // Would return ServiceNow release version of the MID server record
    var midServerwindowsDomain = getMIDServerAttributes.windowsDomain; // Would return windows domain of the MID server record

    gs.info("\nMID Server Host Name - "+ midServerHostname +"\nMid Server Host OS - " + midServerHostOS + "\nMID Server IP - "+ midServerIP + "
    \nMID Server Name - " + midServerName + "\nMID Server Router IP - " + midServerRouterIP + "\nMID Server Status - " +  midServerStatus  + 
    "\nMID Server SYS ID - " + midServerSysID  + "\nMID Server URL - " + midServerURL  + "\nMID Server Version - " + midServerVersion + 
    "\nMID Server Windows Domain - " + midServerwindowsDomain);

{#r_MSVR-routerIP__midserverAPI_example1_cb}

Ausgabe:

    MID Server Host Name - midSvrName.service-now.com
    Mid Server Host OS - Windows
    MID Server IP - 10.11.999.999
    MID Server Name - Windows MID
    MID Server Router IP - 10.11.111.1
    MID Server Status - Up
    MID Server SYS ID - <mid_sys_id>
    MID Server URL - null
    MID Server Version - fixed
    MID Server Windows Domain - null

## MIDServer -- status {#ariaid-title11}

Der Status des MID-Servers („Up" oder „Down").
{#r_MSVR-status__table_qtc_1n1_t5__entry__3}

| Name | Typ | Beschreibung |
|-|-|-|
| Status | Zeichenfolge | Der Status des MID-Servers („Up" oder „Down"). |
[Tabelle : 13. Feld]

{#r_MSVR-status__table_qtc_1n1_t5}  
Das folgende Beispiel zeigt, wie alle Parameter eines verfügbaren MID-Servers ausgeführt und zurückgegeben werden.

    var getMIDServerAttributes = new MIDServer(<mid_sys_id>); //Pass the sys id of the MID server record
    var midServerHostname = getMIDServerAttributes.hostname; //would return the Host name of the MID Server Record
    var midServerHostOS = getMIDServerAttributes.hostOS; // would return the Host OS of the MID Server Record
    var midServerIP = getMIDServerAttributes.ip; //would return the IP of the MID Server Record
    var midServerName = getMIDServerAttributes.name; //would return the Name of the MID Server Record
    var midServerRouterIP = getMIDServerAttributes.routerIP; //would return the router IP of the MID Server Record
    var midServerStatus = getMIDServerAttributes.status; //would return the status of the MID Server Record (UP or Down)
    var midServerSysID = getMIDServerAttributes.sysID; // Would return the Sys ID of the MID server record
    var midServerURL = getMIDServerAttributes.url; // Would return the URL of the MID server record
    var midServerVersion = getMIDServerAttributes.version; // Would return ServiceNow release version of the MID server record
    var midServerwindowsDomain = getMIDServerAttributes.windowsDomain; // Would return windows domain of the MID server record

    gs.info("\nMID Server Host Name - "+ midServerHostname +"\nMid Server Host OS - " + midServerHostOS + "\nMID Server IP - "+ midServerIP + "
    \nMID Server Name - " + midServerName + "\nMID Server Router IP - " + midServerRouterIP + "\nMID Server Status - " +  midServerStatus  + 
    "\nMID Server SYS ID - " + midServerSysID  + "\nMID Server URL - " + midServerURL  + "\nMID Server Version - " + midServerVersion + 
    "\nMID Server Windows Domain - " + midServerwindowsDomain);

{#r_MSVR-status__midserverAPI_example1_cb}

Ausgabe:

    MID Server Host Name - midSvrName.service-now.com
    Mid Server Host OS - Windows
    MID Server IP - 10.11.999.999
    MID Server Name - Windows MID
    MID Server Router IP - 10.11.111.1
    MID Server Status - Up
    MID Server SYS ID - <mid_sys_id>
    MID Server URL - null
    MID Server Version - fixed
    MID Server Windows Domain - null

## MIDServer -- sysID {#ariaid-title12}

Die sys_id des MID-Server-Datensatzes.
{#r_MSVR-sysID__table_ojq_qj1_t5__entry__3}

| Name | Typ | Beschreibung |
|-|-|-|
| sysID | Zeichenfolge | Die sys_id des MID-Server-Datensatzes. |
[Tabelle : 14. Feld]

{#r_MSVR-sysID__table_ojq_qj1_t5}  
Das folgende Beispiel zeigt, wie alle Parameter eines verfügbaren MID-Servers ausgeführt und zurückgegeben werden.

    var getMIDServerAttributes = new MIDServer(<mid_sys_id>); //Pass the sys id of the MID server record
    var midServerHostname = getMIDServerAttributes.hostname; //would return the Host name of the MID Server Record
    var midServerHostOS = getMIDServerAttributes.hostOS; // would return the Host OS of the MID Server Record
    var midServerIP = getMIDServerAttributes.ip; //would return the IP of the MID Server Record
    var midServerName = getMIDServerAttributes.name; //would return the Name of the MID Server Record
    var midServerRouterIP = getMIDServerAttributes.routerIP; //would return the router IP of the MID Server Record
    var midServerStatus = getMIDServerAttributes.status; //would return the status of the MID Server Record (UP or Down)
    var midServerSysID = getMIDServerAttributes.sysID; // Would return the Sys ID of the MID server record
    var midServerURL = getMIDServerAttributes.url; // Would return the URL of the MID server record
    var midServerVersion = getMIDServerAttributes.version; // Would return ServiceNow release version of the MID server record
    var midServerwindowsDomain = getMIDServerAttributes.windowsDomain; // Would return windows domain of the MID server record

    gs.info("\nMID Server Host Name - "+ midServerHostname +"\nMid Server Host OS - " + midServerHostOS + "\nMID Server IP - "+ midServerIP + "
    \nMID Server Name - " + midServerName + "\nMID Server Router IP - " + midServerRouterIP + "\nMID Server Status - " +  midServerStatus  + 
    "\nMID Server SYS ID - " + midServerSysID  + "\nMID Server URL - " + midServerURL  + "\nMID Server Version - " + midServerVersion + 
    "\nMID Server Windows Domain - " + midServerwindowsDomain);

{#r_MSVR-sysID__midserverAPI_example1_cb}

Ausgabe:

    MID Server Host Name - midSvrName.service-now.com
    Mid Server Host OS - Windows
    MID Server IP - 10.11.999.999
    MID Server Name - Windows MID
    MID Server Router IP - 10.11.111.1
    MID Server Status - Up
    MID Server SYS ID - <mid_sys_id>
    MID Server URL - null
    MID Server Version - fixed
    MID Server Windows Domain - null

## MIDServer -- url {#ariaid-title13}

Die URL, mit der der MID-Server die Instanz kontaktiert.
{#r_MSVR-url__table_z5r_fk1_t5__entry__3}

| Name | Typ | Beschreibung |
|-|-|-|
| URL | Zeichenfolge | Die URL, mit der der MID-Server die Instanz kontaktiert. |
[Tabelle : 15. Feld]

{#r_MSVR-url__table_z5r_fk1_t5}  
Das folgende Beispiel zeigt, wie alle Parameter eines verfügbaren MID-Servers ausgeführt und zurückgegeben werden.

    var getMIDServerAttributes = new MIDServer(<mid_sys_id>); //Pass the sys id of the MID server record
    var midServerHostname = getMIDServerAttributes.hostname; //would return the Host name of the MID Server Record
    var midServerHostOS = getMIDServerAttributes.hostOS; // would return the Host OS of the MID Server Record
    var midServerIP = getMIDServerAttributes.ip; //would return the IP of the MID Server Record
    var midServerName = getMIDServerAttributes.name; //would return the Name of the MID Server Record
    var midServerRouterIP = getMIDServerAttributes.routerIP; //would return the router IP of the MID Server Record
    var midServerStatus = getMIDServerAttributes.status; //would return the status of the MID Server Record (UP or Down)
    var midServerSysID = getMIDServerAttributes.sysID; // Would return the Sys ID of the MID server record
    var midServerURL = getMIDServerAttributes.url; // Would return the URL of the MID server record
    var midServerVersion = getMIDServerAttributes.version; // Would return ServiceNow release version of the MID server record
    var midServerwindowsDomain = getMIDServerAttributes.windowsDomain; // Would return windows domain of the MID server record

    gs.info("\nMID Server Host Name - "+ midServerHostname +"\nMid Server Host OS - " + midServerHostOS + "\nMID Server IP - "+ midServerIP + "
    \nMID Server Name - " + midServerName + "\nMID Server Router IP - " + midServerRouterIP + "\nMID Server Status - " +  midServerStatus  + 
    "\nMID Server SYS ID - " + midServerSysID  + "\nMID Server URL - " + midServerURL  + "\nMID Server Version - " + midServerVersion + 
    "\nMID Server Windows Domain - " + midServerwindowsDomain);

{#r_MSVR-url__midserverAPI_example1_cb}

Ausgabe:

    MID Server Host Name - midSvrName.service-now.com
    Mid Server Host OS - Windows
    MID Server IP - 10.11.999.999
    MID Server Name - Windows MID
    MID Server Router IP - 10.11.111.1
    MID Server Status - Up
    MID Server SYS ID - <mid_sys_id>
    MID Server URL - null
    MID Server Version - fixed
    MID Server Windows Domain - null

## MIDServer -- version {#ariaid-title14}

Version des MID-Servers (WAR-Name).
{#r_MSVR-version__table_czl_fl1_t5__entry__3}

| Name | Typ | Beschreibung |
|-|-|-|
| Version | Zeichenfolge | Version des MID-Servers (WAR-Name). |
[Tabelle : 16. Feld]

{#r_MSVR-version__table_czl_fl1_t5}  
Das folgende Beispiel zeigt, wie alle Parameter eines verfügbaren MID-Servers ausgeführt und zurückgegeben werden.

    var getMIDServerAttributes = new MIDServer(<mid_sys_id>); //Pass the sys id of the MID server record
    var midServerHostname = getMIDServerAttributes.hostname; //would return the Host name of the MID Server Record
    var midServerHostOS = getMIDServerAttributes.hostOS; // would return the Host OS of the MID Server Record
    var midServerIP = getMIDServerAttributes.ip; //would return the IP of the MID Server Record
    var midServerName = getMIDServerAttributes.name; //would return the Name of the MID Server Record
    var midServerRouterIP = getMIDServerAttributes.routerIP; //would return the router IP of the MID Server Record
    var midServerStatus = getMIDServerAttributes.status; //would return the status of the MID Server Record (UP or Down)
    var midServerSysID = getMIDServerAttributes.sysID; // Would return the Sys ID of the MID server record
    var midServerURL = getMIDServerAttributes.url; // Would return the URL of the MID server record
    var midServerVersion = getMIDServerAttributes.version; // Would return ServiceNow release version of the MID server record
    var midServerwindowsDomain = getMIDServerAttributes.windowsDomain; // Would return windows domain of the MID server record

    gs.info("\nMID Server Host Name - "+ midServerHostname +"\nMid Server Host OS - " + midServerHostOS + "\nMID Server IP - "+ midServerIP + "
    \nMID Server Name - " + midServerName + "\nMID Server Router IP - " + midServerRouterIP + "\nMID Server Status - " +  midServerStatus  + 
    "\nMID Server SYS ID - " + midServerSysID  + "\nMID Server URL - " + midServerURL  + "\nMID Server Version - " + midServerVersion + 
    "\nMID Server Windows Domain - " + midServerwindowsDomain);

{#r_MSVR-version__midserverAPI_example1_cb}

Ausgabe:

    MID Server Host Name - midSvrName.service-now.com
    Mid Server Host OS - Windows
    MID Server IP - 10.11.999.999
    MID Server Name - Windows MID
    MID Server Router IP - 10.11.111.1
    MID Server Status - Up
    MID Server SYS ID - <mid_sys_id>
    MID Server URL - null
    MID Server Version - fixed
    MID Server Windows Domain - null

## MIDServer -- windowsDomain {#ariaid-title15}

Windows-Domäne des MID-Server-Hosts (wenn es sich um einen Windows-Computer handelt).
{#r_MSVR-windowsDomain__table_rnk_pm1_t5__entry__3}

| Name | Typ | Beschreibung |
|-|-|-|
| windowsDomain | Zeichenfolge | Die Windows-Domäne des MID-Server-Hosts. |
[Tabelle : 17. Feld]

{#r_MSVR-windowsDomain__table_rnk_pm1_t5}  
Das folgende Beispiel zeigt, wie alle Parameter eines verfügbaren MID-Servers ausgeführt und zurückgegeben werden.

    var getMIDServerAttributes = new MIDServer(<mid_sys_id>); //Pass the sys id of the MID server record
    var midServerHostname = getMIDServerAttributes.hostname; //would return the Host name of the MID Server Record
    var midServerHostOS = getMIDServerAttributes.hostOS; // would return the Host OS of the MID Server Record
    var midServerIP = getMIDServerAttributes.ip; //would return the IP of the MID Server Record
    var midServerName = getMIDServerAttributes.name; //would return the Name of the MID Server Record
    var midServerRouterIP = getMIDServerAttributes.routerIP; //would return the router IP of the MID Server Record
    var midServerStatus = getMIDServerAttributes.status; //would return the status of the MID Server Record (UP or Down)
    var midServerSysID = getMIDServerAttributes.sysID; // Would return the Sys ID of the MID server record
    var midServerURL = getMIDServerAttributes.url; // Would return the URL of the MID server record
    var midServerVersion = getMIDServerAttributes.version; // Would return ServiceNow release version of the MID server record
    var midServerwindowsDomain = getMIDServerAttributes.windowsDomain; // Would return windows domain of the MID server record

    gs.info("\nMID Server Host Name - "+ midServerHostname +"\nMid Server Host OS - " + midServerHostOS + "\nMID Server IP - "+ midServerIP + "
    \nMID Server Name - " + midServerName + "\nMID Server Router IP - " + midServerRouterIP + "\nMID Server Status - " +  midServerStatus  + 
    "\nMID Server SYS ID - " + midServerSysID  + "\nMID Server URL - " + midServerURL  + "\nMID Server Version - " + midServerVersion + 
    "\nMID Server Windows Domain - " + midServerwindowsDomain);

{#r_MSVR-windowsDomain__midserverAPI_example1_cb}

Ausgabe:

    MID Server Host Name - midSvrName.service-now.com
    Mid Server Host OS - Windows
    MID Server IP - 10.11.999.999
    MID Server Name - Windows MID
    MID Server Router IP - 10.11.111.1
    MID Server Status - Up
    MID Server SYS ID - <mid_sys_id>
    MID Server URL - null
    MID Server Version - fixed
    MID Server Windows Domain - null


