Object
======

Object can be a pem-agent, a monitored server, or a database object
(that is, a database, schema, table, index, sequence, function, or
view).

get\_\ *server_group*
---------------------

**Code samples**

.. code:: shell


   #  You can also use wget

   curl -X GET https://PEM-SERVER-IP/api/v14/server_group/ \
     -H Accept: application/json \
     -H X-Auth-Token: string

.. code:: python

   import requests
   headers = {
     Accept: application/json,
     X-Auth-Token: string
   }

   r = requests.get(https://PEM-SERVER-IP/api/v14/server_group/, headers = headers)

   print(r.json())

.. code:: javascript


   const headers = {
     Accept:application/json,
     X-Auth-Token:string
   };

   fetch(https://PEM-SERVER-IP/api/v14/server_group/,
   {
     method: GET,

     headers: headers
   })
   .then(function(res) {
       return res.json();
   }).then(function(body) {
       console.log(body);
   });

``GET /server_group/``

- Get list of server group.\*

Returns a list of server group.

Parameters
^^^^^^^^^^

.. csv-table::
  :header: Name,In,Type,Required,Description
  :widths: 11,7,7,7,17
  :align: left
  :class: longtable

  X-Auth-Token,header,string,true,Token for authentication purpose

**Example responses**

.. raw:: html

   <Details summary="200 Response">

.. code:: json

   {
     "id": 0,
     "name": "string",
     "hidden": true,
     "parent_id": 0
   }

.. raw:: html

   </Details>

Responses
^^^^^^^^^

.. csv-table::
  :header: Status,Meaning,Description,Schema
  :widths: 15,12,12,20
  :align: left
  :class: longtable

  200,:ref:`Invoking the server installer from the command line<Invoking the server installer from the command line>` ,Returns a list of server group.,:ref:`ServerGroupBodyGet<ServerGroupBodyGet>` 

..  Note::
   This operation does not require authentication

post\_\ *server_group*
----------------------

**Code samples**

.. code:: shell


   #  You can also use wget

   curl -X POST https://PEM-SERVER-IP/api/v14/server_group/ \
     -H Content-Type: application/json \
     -H X-Auth-Token: string

.. code:: python

   import requests
   headers = {
     Content-Type: application/json,
     X-Auth-Token: string
   }

   r = requests.post(https://PEM-SERVER-IP/api/v14/server_group/, headers = headers)

   print(r.json())

.. code:: javascript

   const inputBody = {
     "name": "string"
   };
   const headers = {
     Content-Type:application/json,
     X-Auth-Token:string
   };

   fetch(https://PEM-SERVER-IP/api/v14/server_group/,
   {
     method: POST,
     body: inputBody,
     headers: headers
   })
   .then(function(res) {
       return res.json();
   }).then(function(body) {
       console.log(body);
   });

``POST /server_group/``

- Add a new server group.\*

**Body parameter**

.. code:: json

   {
     "name": "string"
   }

.. _parameters-1:

Parameters
^^^^^^^^^^

.. csv-table::
  :header: Name,In,Type,Required,Description
  :widths: 11,7,7,7,17
  :align: left
  :class: longtable

  X-Auth-Token,header,string,true,Token of authorization
  body,body,:ref:`ServerGroupBody<ServerGroupBody>` ,true,none

**Example responses**

.. _responses-1:

Responses
^^^^^^^^^

.. csv-table::
  :header: Status,Meaning,Description,Schema
  :widths: 15,12,12,20
  :align: left
  :class: longtable

  200,:ref:`Invoking the server installer from the command line<Invoking the server installer from the command line>` ,Status 200,None

Response Schema
^^^^^^^^^^^^^^^

..  Note::
   This operation does not require authentication

get\_\ *server_group*\ {group_id}
---------------------------------

**Code samples**

.. code:: shell


   #  You can also use wget

   curl -X GET https://PEM-SERVER-IP/api/v14/server_group/{group_id} \
     -H Accept: application/json \
     -H X-Auth-Token: string

.. code:: python

   import requests
   headers = {
     Accept: application/json,
     X-Auth-Token: string
   }

   r = requests.get(https://PEM-SERVER-IP/api/v14/server_group/{group_id}, headers = headers)

   print(r.json())

.. code:: javascript


   const headers = {
     Accept:application/json,
     X-Auth-Token:string
   };

   fetch(https://PEM-SERVER-IP/api/v14/server_group/{group_id},
   {
     method: GET,

     headers: headers
   })
   .then(function(res) {
       return res.json();
   }).then(function(body) {
       console.log(body);
   });

``GET /server_group/{group_id}``

- Get server group by id.\*

Returns a server group.

.. _parameters-2:

Parameters
^^^^^^^^^^

.. csv-table::
  :header: Name,In,Type,Required,Description
  :widths: 11,7,7,7,17
  :align: left
  :class: longtable

  group_id,path,integer,true,none
  X-Auth-Token,header,string,true,Token for authentication purpose

**Example responses**

.. raw:: html

   <Details summary="200 Response">

.. code:: json

   {
     "id": 0,
     "name": "string",
     "hidden": true,
     "parent_id": 0
   }

.. raw:: html

   </Details>

.. _responses-2:

Responses
^^^^^^^^^

.. csv-table::
  :header: Status,Meaning,Description,Schema
  :widths: 15,12,12,20
  :align: left
  :class: longtable

  200,:ref:`Invoking the server installer from the command line<Invoking the server installer from the command line>` ,Successful response,:ref:`ServerGroupBodyGet<ServerGroupBodyGet>` 

..  Note::
   This operation does not require authentication

put\_\ *server_group*\ {group_id}
---------------------------------

**Code samples**

.. code:: shell


   #  You can also use wget

   curl -X PUT https://PEM-SERVER-IP/api/v14/server_group/{group_id} \
     -H Content-Type: application/json \
     -H X-Auth-Token: string

.. code:: python

   import requests
   headers = {
     Content-Type: application/json,
     X-Auth-Token: string
   }

   r = requests.put(https://PEM-SERVER-IP/api/v14/server_group/{group_id}, headers = headers)

   print(r.json())

.. code:: javascript

   const inputBody = {
     "name": "string"
   };
   const headers = {
     Content-Type:application/json,
     X-Auth-Token:string
   };

   fetch(https://PEM-SERVER-IP/api/v14/server_group/{group_id},
   {
     method: PUT,
     body: inputBody,
     headers: headers
   })
   .then(function(res) {
       return res.json();
   }).then(function(body) {
       console.log(body);
   });

``PUT /server_group/{group_id}``

- Update a server group.\*

**Body parameter**

.. code:: json

   {
     "name": "string"
   }

.. _parameters-3:

Parameters
^^^^^^^^^^

.. csv-table::
  :header: Name,In,Type,Required,Description
  :widths: 11,7,7,7,17
  :align: left
  :class: longtable

  group_id,path,integer,true,none
  X-Auth-Token,header,string,true,Token of authorization
  body,body,:ref:`ServerGroupBody<ServerGroupBody>` ,true,Updated successfully

**Example responses**

.. _responses-3:

Responses
^^^^^^^^^

.. csv-table::
  :header: Status,Meaning,Description,Schema
  :widths: 15,12,12,20
  :align: left
  :class: longtable

  200,:ref:`Invoking the server installer from the command line<Invoking the server installer from the command line>` ,Status 200,None

.. _response-schema-1:

Response Schema
^^^^^^^^^^^^^^^

..  Note::
   This operation does not require authentication

delete\_\ *server_group*\ {group_id}
------------------------------------

**Code samples**

.. code:: shell


   #  You can also use wget

   curl -X DELETE https://PEM-SERVER-IP/api/v14/server_group/{group_id} \
     -H X-Auth-Token: string

.. code:: python

   import requests
   headers = {
     X-Auth-Token: string
   }

   r = requests.delete(https://PEM-SERVER-IP/api/v14/server_group/{group_id}, headers = headers)

   print(r.json())

.. code:: javascript


   const headers = {
     X-Auth-Token:string
   };

   fetch(https://PEM-SERVER-IP/api/v14/server_group/{group_id},
   {
     method: DELETE,

     headers: headers
   })
   .then(function(res) {
       return res.json();
   }).then(function(body) {
       console.log(body);
   });

``DELETE /server_group/{group_id}``

- Delete a server group.\*

.. _parameters-4:

Parameters
^^^^^^^^^^

.. csv-table::
  :header: Name,In,Type,Required,Description
  :widths: 11,7,7,7,17
  :align: left
  :class: longtable

  group_id,path,integer,true,none
  X-Auth-Token,header,string,true,Token for authentication purpose

**Example responses**

.. _responses-4:

Responses
^^^^^^^^^

.. csv-table::
  :header: Status,Meaning,Description,Schema
  :widths: 15,12,12,20
  :align: left
  :class: longtable

  200,:ref:`Invoking the server installer from the command line<Invoking the server installer from the command line>` ,Status 200,None

.. _response-schema-2:

Response Schema
^^^^^^^^^^^^^^^

..  Note::
   This operation does not require authentication

get\_\ *agent*
--------------

**Code samples**

.. code:: shell


   #  You can also use wget

   curl -X GET https://PEM-SERVER-IP/api/v14/agent/ \
     -H Accept: application/json \
     -H X-Auth-Token: string

.. code:: python

   import requests
   headers = {
     Accept: application/json,
     X-Auth-Token: string
   }

   r = requests.get(https://PEM-SERVER-IP/api/v14/agent/, headers = headers)

   print(r.json())

.. code:: javascript


   const headers = {
     Accept:application/json,
     X-Auth-Token:string
   };

   fetch(https://PEM-SERVER-IP/api/v14/agent/,
   {
     method: GET,

     headers: headers
   })
   .then(function(res) {
       return res.json();
   }).then(function(body) {
       console.log(body);
   });

``GET /agent/``

- Retrieve the pem-agent information.\*

Returns a list of information and status for the pem-agents visible to
the user (represented by the token).

.. _parameters-5:

Parameters
^^^^^^^^^^

.. csv-table::
  :header: Name,In,Type,Required,Description
  :widths: 11,7,7,7,17
  :align: left
  :class: longtable

  X-Auth-Token,header,string,true,Token for authentication purpose

**Example responses**

.. raw:: html

   <Details summary="200 Response">

.. code:: json

   [
     {
       "id": 0,
       "name": "string",
       "version": "string",
       "active": true,
       "heartbeat_tolerance": 0,
       "alert_blackout": true,
       "owner": "string",
       "team": "string",
       "gid": 0,
       "tags": [
         "string"
       ],
       "ignore_mnt_points": [
         "string"
       ]
     }
   ]

.. raw:: html

   </Details>

.. _responses-5:

Responses
^^^^^^^^^

.. csv-table::
  :header: Status,Meaning,Description,Schema
  :widths: 15,12,12,20
  :align: left
  :class: longtable

  200,:ref:`Invoking the server installer from the command line<Invoking the server installer from the command line>` ,Returns a list of information and status about the pem-agents.,:ref:`Certificates and key files for PEM agents<Certificates and key files for PEM agents>` 

..  Note::
   This operation does not require authentication

get\_\ *agent*\ {agent_id}
--------------------------

**Code samples**

.. code:: shell


   #  You can also use wget

   curl -X GET https://PEM-SERVER-IP/api/v14/agent/{agent_id} \
     -H Accept: application/json \
     -H X-Auth-Token: string

.. code:: python

   import requests
   headers = {
     Accept: application/json,
     X-Auth-Token: string
   }

   r = requests.get(https://PEM-SERVER-IP/api/v14/agent/{agent_id}, headers = headers)

   print(r.json())

.. code:: javascript


   const headers = {
     Accept:application/json,
     X-Auth-Token:string
   };

   fetch(https://PEM-SERVER-IP/api/v14/agent/{agent_id},
   {
     method: GET,

     headers: headers
   })
   .then(function(res) {
       return res.json();
   }).then(function(body) {
       console.log(body);
   });

``GET /agent/{agent_id}``

- Retrieve information for an agent, identified by the agent_id.\*

.. _parameters-6:

Parameters
^^^^^^^^^^

.. csv-table::
  :header: Name,In,Type,Required,Description
  :widths: 11,7,7,7,17
  :align: left
  :class: longtable

  agent_id,path,integer,true,none
  X-Auth-Token,header,string,true,Token of authorization

**Example responses**

.. raw:: html

   <Details summary="200 Response">

.. code:: json

   {
     "id": 0,
     "name": "string",
     "version": "string",
     "active": true,
     "heartbeat_tolerance": 0,
     "alert_blackout": true,
     "owner": "string",
     "team": "string",
     "gid": 0,
     "tags": [
       "string"
     ],
     "ignore_mnt_points": [
       "string"
     ]
   }

.. raw:: html

   </Details>

.. _responses-6:

Responses
^^^^^^^^^

.. csv-table::
  :header: Status,Meaning,Description,Schema
  :widths: 15,12,12,20
  :align: left
  :class: longtable

  200,:ref:`Invoking the server installer from the command line<Invoking the server installer from the command line>` ,Successful response,:ref:`PEM backend database server and agent connection certificates<PEM backend database server and agent connection certificates>` 

..  Note::
   This operation does not require authentication

put\_\ *agent*\ {agent_id}
--------------------------

**Code samples**

.. code:: shell


   #  You can also use wget

   curl -X PUT https://PEM-SERVER-IP/api/v14/agent/{agent_id} \
     -H Content-Type: application/json \
     -H X-Auth-Token: string

.. code:: python

   import requests
   headers = {
     Content-Type: application/json,
     X-Auth-Token: string
   }

   r = requests.put(https://PEM-SERVER-IP/api/v14/agent/{agent_id}, headers = headers)

   print(r.json())

.. code:: javascript

   const inputBody = {
     "name": "string",
     "heartbeat_tolerance": 0,
     "alert_blackout": true,
     "team": "string",
     "gid": 0,
     "tags": {
       "added": [
         {
           "color": "#0C767A",
           "text": "tag4"
         }
       ],
       "deleted": [
         {
           "text": "tag1",
           "color": "#8789AC",
           "old_text": "tag2"
         }
       ],
       "changed": [
         {
           "old_text": "tag",
           "text": "tag3"
         }
       ]
     },
     "ignore_mnt_points": [
       "string"
     ]
   };
   const headers = {
     Content-Type:application/json,
     X-Auth-Token:string
   };

   fetch(https://PEM-SERVER-IP/api/v14/agent/{agent_id},
   {
     method: PUT,
     body: inputBody,
     headers: headers
   })
   .then(function(res) {
       return res.json();
   }).then(function(body) {
       console.log(body);
   });

``PUT /agent/{agent_id}``

- Update agent information.\*

**Body parameter**

.. code:: json

   {
     "name": "string",
     "heartbeat_tolerance": 0,
     "alert_blackout": true,
     "team": "string",
     "gid": 0,
     "tags": {
       "added": [
         {
           "color": "#0C767A",
           "text": "tag4"
         }
       ],
       "deleted": [
         {
           "text": "tag1",
           "color": "#8789AC",
           "old_text": "tag2"
         }
       ],
       "changed": [
         {
           "old_text": "tag",
           "text": "tag3"
         }
       ]
     },
     "ignore_mnt_points": [
       "string"
     ]
   }

.. _parameters-7:

Parameters
^^^^^^^^^^

.. csv-table::
  :header: Name,In,Type,Required,Description
  :widths: 11,7,7,7,17
  :align: left
  :class: longtable

  agent_id,path,integer,true,none
  X-Auth-Token,header,string,true,Token of authorization
  body,body,:ref:`AgentBody<AgentBody>` ,true,none

**Example responses**

.. _responses-7:

Responses
^^^^^^^^^

.. csv-table::
  :header: Status,Meaning,Description,Schema
  :widths: 15,12,12,20
  :align: left
  :class: longtable

  200,:ref:`Invoking the server installer from the command line<Invoking the server installer from the command line>` ,Updated successfully,None

.. _response-schema-3:

Response Schema
^^^^^^^^^^^^^^^

..  Note::
   This operation does not require authentication

delete\_\ *agent*\ {agent_id}
-----------------------------

**Code samples**

.. code:: shell


   #  You can also use wget

   curl -X DELETE https://PEM-SERVER-IP/api/v14/agent/{agent_id} \
     -H X-Auth-Token: string

.. code:: python

   import requests
   headers = {
     X-Auth-Token: string
   }

   r = requests.delete(https://PEM-SERVER-IP/api/v14/agent/{agent_id}, headers = headers)

   print(r.json())

.. code:: javascript


   const headers = {
     X-Auth-Token:string
   };

   fetch(https://PEM-SERVER-IP/api/v14/agent/{agent_id},
   {
     method: DELETE,

     headers: headers
   })
   .then(function(res) {
       return res.json();
   }).then(function(body) {
       console.log(body);
   });

``DELETE /agent/{agent_id}``

- Stop managing the agent by PEM.\*

.. _parameters-8:

Parameters
^^^^^^^^^^

.. csv-table::
  :header: Name,In,Type,Required,Description
  :widths: 11,7,7,7,17
  :align: left
  :class: longtable

  agent_id,path,integer,true,none
  X-Auth-Token,header,string,true,Token of authorization

**Example responses**

.. _responses-8:

Responses
^^^^^^^^^

.. csv-table::
  :header: Status,Meaning,Description,Schema
  :widths: 15,12,12,20
  :align: left
  :class: longtable

  200,:ref:`Invoking the server installer from the command line<Invoking the server installer from the command line>` ,Status 200,None

.. _response-schema-4:

Response Schema
^^^^^^^^^^^^^^^

..  Note::
   This operation does not require authentication

get\_\ *server*
---------------

**Code samples**

.. code:: shell


   #  You can also use wget

   curl -X GET https://PEM-SERVER-IP/api/v14/server/ \
     -H Accept: application/json \
     -H X-Auth-Token: string

.. code:: python

   import requests
   headers = {
     Accept: application/json,
     X-Auth-Token: string
   }

   r = requests.get(https://PEM-SERVER-IP/api/v14/server/, headers = headers)

   print(r.json())

.. code:: javascript


   const headers = {
     Accept:application/json,
     X-Auth-Token:string
   };

   fetch(https://PEM-SERVER-IP/api/v14/server/,
   {
     method: GET,

     headers: headers
   })
   .then(function(res) {
       return res.json();
   }).then(function(body) {
       console.log(body);
   });

``GET /server/``

- Retrieval of the managed server list\*

.. _parameters-9:

Parameters
^^^^^^^^^^

.. csv-table::
  :header: Name,In,Type,Required,Description
  :widths: 11,7,7,7,17
  :align: left
  :class: longtable

  X-Auth-Token,header,string,true,Token of authorization

**Example responses**

.. raw:: html

   <Details summary="200 Response">

.. code:: json

   [
     {
       "id": 0,
       "name": "string",
       "host": "string",
       "port": 0,
       "db": "string",
       "serviceid": "string",
       "connection_params": [
         {
           "name": "string",
           "keyword": "string",
           "value": null
         }
       ],
       "active": true,
       "alert_blackout": true,
       "owner": 0,
       "team": "string",
       "server_owner": "string",
       "is_remote_monitoring": true,
       "tags": [
         "string"
       ],
       "replication_solution": "none",
       "efm_cluster_name": "string",
       "efm_service_name": "string",
       "efm_installation_path": "string",
       "patroni_cluster_name": "string",
       "patroni_installation_path": "string",
       "patroni_config_path": "string",
       "comment": "string",
       "username": "string",
       "gid": 0,
       "server_group_name": "string",
       "db_res": "string",
       "role": "string",
       "is_edb": true,
       "agent_id": 0,
       "asb_host": "string",
       "asb_port": 0,
       "asb_username": "string",
       "asb_database": "string",
       "asb_sslmode": "prefer",
       "agent_allowtakeover": false,
       "agent_capability_list": [
         "string"
       ],
       "agent_description": "string",
       "sslcompression": false,
       "use_ssh_tunnel": false,
       "tunnel_host": "string",
       "tunnel_port": 22,
       "tunnel_username": "string",
       "tunnel_authentication": false,
       "tunnel_identity_file": "string",
       "post_connection_sql": "string"
     }
   ]

.. raw:: html

   </Details>

.. _responses-9:

Responses
^^^^^^^^^

.. csv-table::
  :header: Status,Meaning,Description,Schema
  :widths: 15,12,12,20
  :align: left
  :class: longtable

  200,:ref:`Invoking the server installer from the command line<Invoking the server installer from the command line>` ,Status 200,Inline

.. _response-schema-5:

Response Schema
^^^^^^^^^^^^^^^

Status Code **200**

.. csv-table::
  :header: Name,Type,Required,Restrictions,Description
  :widths: 12,8,8,8,12
  :align: left
  :class: longtable

  *anonymous*,\ :ref:`Query information <Schemas>` ],false,none,none
  » id,integer,false,none,Server ID.NOTE: This property is not applicable for a POST request.
  » name,string,false,none,Server name
  » host,string,false,none,Server host
  » port,integer,false,none,Server port
  » db,string,false,none,Maintenance databse
  » serviceid,string,false,none,Server service ID
  » connection_params,[object],false,none,List of connection parameters for the server.
  »» name,string,false,none,Parameter name
  »» keyword,string,false,none,Parameter keyword
  »» value,any,false,none,Parameter value
  » active,boolean,false,none,Determines whether the server is active.
  » alert_blackout,boolean,false,none,Determines whether the alerts on the server are blacked out.
  » owner,integer,false,none,ID of the owner who registered the server with PEM.
  » team,string,false,none,Defines the role/username who can see server information.
  » server_owner,string,false,none,Name of the user who registered the server on the PEM database server.
  » is_remote_monitoring,boolean,false,none,"Determines whether this server is being monitored remotely (that is, the monitoring pemAgent does not reside on the same host as the monitored server)."
  » tags,[string],false,none,List of tags associated with the server.
  » replication_solution,string,false,none,Replication solution used by the server
  » efm_cluster_name,string,false,none,Cluster name of EFM
  » efm_service_name,string,false,none,Service name of EFM
  » efm_installation_path,string,false,none,Installation path of EFM
  » patroni_cluster_name,string,false,none,Cluster name of Patroni
  » patroni_installation_path,string,false,none,Installation path of Patroni
  » patroni_config_path,string,false,none,Configuration path of Patroni
  » comment,string,false,none,Description of the server
  » username,string,false,none,Username for connecting the database server
  » gid,integer,false,none,ID of the server group
  » server_group_name,string,false,none,Name of the server group
  » db_res,string,false,none,Database restriction SQL clause
  » role,string,false,none,The role the connection will use
  » is_edb,boolean,false,none,Is server an EDB Advanced Server?
  » agent_id,integer,false,none,Agent ID bound to the server
  » asb_host,string,false,none,PEM database host used by agent while creating PEM connection
  » asb_port,integer,false,none,PEM database port used by agent while creating PEM connection
  » asb_username,string,false,none,PEM database user name used by agent while creating PEM connection
  » asb_database,string,false,none,PEM database to which agent will connect
  » asb_sslmode,string,false,none,PEM database SSL mode
  » agent_allowtakeover,boolean,false,none,Specifies whether the server can be taken over by another agent.
  » agent_capability_list,[string],false,none,Array of agent capabilities
  » agent_description,string,false,none,Agent description
  » sslcompression,boolean,false,none,Determines whether data sent over SSL should be compressed.
  » use_ssh_tunnel,boolean,false,none,Determines whether to use ssh tunnel.
  » tunnel_host,string,false,none,Tunnel host name
  » tunnel_port,integer,false,none,Tunnel port number
  » tunnel_username,string,false,none,Tunnel username
  » tunnel_authentication,boolean,false,none,Determines whether to use tunnel authentication.
  » tunnel_identity_file,string,false,none,Tunnel identity file used for authentication.
  » post_connection_sql,string,false,none,SQL to be executed after establishing the connection.

Enumerated Values
'''''''''''''''''

.. csv-table::
  :header: Property,Value
  :widths: 10,30
  :align: left
  :class: longtable

  replication_solution,none
  replication_solution,efm
  replication_solution,patroni
  asb_sslmode,prefer
  asb_sslmode,allow
  asb_sslmode,disable
  asb_sslmode,require
  asb_sslmode,verify-ca
  asb_sslmode,verify-full

..  Note::
   This operation does not require authentication

post\_\ *server*
----------------

**Code samples**

.. code:: shell


   #  You can also use wget

   curl -X POST https://PEM-SERVER-IP/api/v14/server/ \
     -H Content-Type: application/json \
     -H X-Auth-Token: string

.. code:: python

   import requests
   headers = {
     Content-Type: application/json,
     X-Auth-Token: string
   }

   r = requests.post(https://PEM-SERVER-IP/api/v14/server/, headers = headers)

   print(r.json())

.. code:: javascript

   const inputBody = {
     "name": "string",
     "host": "string",
     "port": 0,
     "db": "string",
     "serviceid": "string",
     "connection_params": [
       {
         "name": "sslmode",
         "keyword": "sslmode",
         "value": "prefer"
       },
       {
         "name": "connect_timeout",
         "keyword": "connect_timeout",
         "value": 10
       }
     ],
     "alert_blackout": true,
     "team": "string",
     "is_remote_monitoring": true,
     "tags": [
       {
         "text": "tag1",
         "color": "#8789AC"
       },
       {
         "text": "tag2",
         "color": "#0C767A"
       }
     ],
     "replication_solution": "none",
     "efm_cluster_name": "string",
     "efm_service_name": "string",
     "efm_installation_path": "string",
     "patroni_cluster_name": "string",
     "patroni_installation_path": "string",
     "patroni_config_path": "string",
     "comment": "string",
     "username": "string",
     "gid": 0,
     "hostaddr": "string",
     "db_res": "string",
     "role": "string",
     "agent_id": 0,
     "asb_host": "string",
     "asb_port": 0,
     "asb_username": "string",
     "asb_database": "string",
     "asb_sslmode": "prefer",
     "asb_password": "string",
     "agent_allowtakeover": false,
     "fgcolor": "#000000",
     "bgcolor": "#FFFFFF",
     "sslcompression": false,
     "use_ssh_tunnel": false,
     "tunnel_host": "string",
     "tunnel_port": 22,
     "tunnel_username": "string",
     "tunnel_password": "string",
     "tunnel_authentication": false,
     "tunnel_identity_file": "string",
     "post_connection_sql": "string"
   };
   const headers = {
     Content-Type:application/json,
     X-Auth-Token:string
   };

   fetch(https://PEM-SERVER-IP/api/v14/server/,
   {
     method: POST,
     body: inputBody,
     headers: headers
   })
   .then(function(res) {
       return res.json();
   }).then(function(body) {
       console.log(body);
   });

``POST /server/``

- Add a new managed database server.\*

**Body parameter**

.. code:: json

   {
     "name": "string",
     "host": "string",
     "port": 0,
     "db": "string",
     "serviceid": "string",
     "connection_params": [
       {
         "name": "sslmode",
         "keyword": "sslmode",
         "value": "prefer"
       },
       {
         "name": "connect_timeout",
         "keyword": "connect_timeout",
         "value": 10
       }
     ],
     "alert_blackout": true,
     "team": "string",
     "is_remote_monitoring": true,
     "tags": [
       {
         "text": "tag1",
         "color": "#8789AC"
       },
       {
         "text": "tag2",
         "color": "#0C767A"
       }
     ],
     "replication_solution": "none",
     "efm_cluster_name": "string",
     "efm_service_name": "string",
     "efm_installation_path": "string",
     "patroni_cluster_name": "string",
     "patroni_installation_path": "string",
     "patroni_config_path": "string",
     "comment": "string",
     "username": "string",
     "gid": 0,
     "hostaddr": "string",
     "db_res": "string",
     "role": "string",
     "agent_id": 0,
     "asb_host": "string",
     "asb_port": 0,
     "asb_username": "string",
     "asb_database": "string",
     "asb_sslmode": "prefer",
     "asb_password": "string",
     "agent_allowtakeover": false,
     "fgcolor": "#000000",
     "bgcolor": "#FFFFFF",
     "sslcompression": false,
     "use_ssh_tunnel": false,
     "tunnel_host": "string",
     "tunnel_port": 22,
     "tunnel_username": "string",
     "tunnel_password": "string",
     "tunnel_authentication": false,
     "tunnel_identity_file": "string",
     "post_connection_sql": "string"
   }

.. _parameters-10:

Parameters
^^^^^^^^^^

.. csv-table::
  :header: Name,In,Type,Required,Description
  :widths: 11,7,7,7,17
  :align: left
  :class: longtable

  X-Auth-Token,header,string,true,Token of authorization
  body,body,:ref:`ServerBody<ServerBody>` ,true,none

**Example responses**

.. _responses-10:

Responses
^^^^^^^^^

.. csv-table::
  :header: Status,Meaning,Description,Schema
  :widths: 15,12,12,20
  :align: left
  :class: longtable

  200,:ref:`Invoking the server installer from the command line<Invoking the server installer from the command line>` ,Status 200,None

.. _response-schema-6:

Response Schema
^^^^^^^^^^^^^^^

..  Note::
   This operation does not require authentication

get\_\ *server*\ {server_id}
----------------------------

**Code samples**

.. code:: shell


   #  You can also use wget

   curl -X GET https://PEM-SERVER-IP/api/v14/server/{server_id} \
     -H Accept: application/json \
     -H X-Auth-Token: string

.. code:: python

   import requests
   headers = {
     Accept: application/json,
     X-Auth-Token: string
   }

   r = requests.get(https://PEM-SERVER-IP/api/v14/server/{server_id}, headers = headers)

   print(r.json())

.. code:: javascript


   const headers = {
     Accept:application/json,
     X-Auth-Token:string
   };

   fetch(https://PEM-SERVER-IP/api/v14/server/{server_id},
   {
     method: GET,

     headers: headers
   })
   .then(function(res) {
       return res.json();
   }).then(function(body) {
       console.log(body);
   });

``GET /server/{server_id}``

- Retrieve the information for the server, identified by the
  server_id.\*

.. _parameters-11:

Parameters
^^^^^^^^^^

.. csv-table::
  :header: Name,In,Type,Required,Description
  :widths: 11,7,7,7,17
  :align: left
  :class: longtable

  server_id,path,string,true,none
  X-Auth-Token,header,string,true,Token of authorization

**Example responses**

.. raw:: html

   <Details summary="200 Response">

.. code:: json

   {
     "id": 0,
     "name": "string",
     "host": "string",
     "port": 0,
     "db": "string",
     "serviceid": "string",
     "connection_params": [
       {
         "name": "string",
         "keyword": "string",
         "value": null
       }
     ],
     "active": true,
     "alert_blackout": true,
     "owner": 0,
     "team": "string",
     "server_owner": "string",
     "is_remote_monitoring": true,
     "tags": [
       "string"
     ],
     "replication_solution": "none",
     "efm_cluster_name": "string",
     "efm_service_name": "string",
     "efm_installation_path": "string",
     "patroni_cluster_name": "string",
     "patroni_installation_path": "string",
     "patroni_config_path": "string",
     "comment": "string",
     "username": "string",
     "gid": 0,
     "server_group_name": "string",
     "db_res": "string",
     "role": "string",
     "is_edb": true,
     "agent_id": 0,
     "asb_host": "string",
     "asb_port": 0,
     "asb_username": "string",
     "asb_database": "string",
     "asb_sslmode": "prefer",
     "agent_allowtakeover": false,
     "agent_capability_list": [
       "string"
     ],
     "agent_description": "string",
     "sslcompression": false,
     "use_ssh_tunnel": false,
     "tunnel_host": "string",
     "tunnel_port": 22,
     "tunnel_username": "string",
     "tunnel_authentication": false,
     "tunnel_identity_file": "string",
     "post_connection_sql": "string"
   }

.. raw:: html

   </Details>

.. _responses-11:

Responses
^^^^^^^^^

.. csv-table::
  :header: Status,Meaning,Description,Schema
  :widths: 15,12,12,20
  :align: left
  :class: longtable

  200,:ref:`Invoking the server installer from the command line<Invoking the server installer from the command line>` ,Created successfully,:ref:`Web server certificates<Web server certificates>` 

..  Note::
   This operation does not require authentication

put\_\ *server*\ {server_id}
----------------------------

**Code samples**

.. code:: shell


   #  You can also use wget

   curl -X PUT https://PEM-SERVER-IP/api/v14/server/{server_id} \
     -H Content-Type: application/json \
     -H X-Auth-Token: string

.. code:: python

   import requests
   headers = {
     Content-Type: application/json,
     X-Auth-Token: string
   }

   r = requests.put(https://PEM-SERVER-IP/api/v14/server/{server_id}, headers = headers)

   print(r.json())

.. code:: javascript

   const inputBody = {
     "name": "string",
     "host": "string",
     "port": 0,
     "db": "string",
     "serviceid": "string",
     "connection_params": {
       "added": [
         {
           "keyword": "hostaddr",
           "name": "hostaddr",
           "value": "qwde"
         }
       ],
       "changed": [
         {
           "keyword": "connect_timeout",
           "name": "connect_timeout",
           "value": "20"
         }
       ],
       "deleted": [
         {
           "keyword": "sslmode",
           "name": "sslmode",
           "value": "prefer"
         }
       ]
     },
     "alert_blackout": true,
     "team": "string",
     "is_remote_monitoring": true,
     "tags": {
       "added": [
         {
           "color": "#0C767A",
           "text": "tag4"
         }
       ],
       "deleted": [
         {
           "text": "tag1",
           "color": "#8789AC",
           "old_text": "tag2"
         }
       ],
       "changed": [
         {
           "old_text": "tag",
           "text": "tag3"
         }
       ]
     },
     "replication_solution": "none",
     "efm_cluster_name": "string",
     "efm_service_name": "string",
     "efm_installation_path": "string",
     "patroni_cluster_name": "string",
     "patroni_installation_path": "string",
     "patroni_config_path": "string",
     "comment": "string",
     "username": "string",
     "gid": 0,
     "hostaddr": "string",
     "db_res": "string",
     "role": "string",
     "agent_id": 0,
     "asb_host": "string",
     "asb_port": 0,
     "asb_username": "string",
     "asb_database": "string",
     "asb_sslmode": "prefer",
     "asb_password": "string",
     "agent_allowtakeover": false,
     "fgcolor": "#000000",
     "bgcolor": "#FFFFFF",
     "sslcompression": false,
     "use_ssh_tunnel": false,
     "tunnel_host": "string",
     "tunnel_port": 22,
     "tunnel_username": "string",
     "tunnel_password": "string",
     "tunnel_authentication": false,
     "tunnel_identity_file": "string",
     "post_connection_sql": "string"
   };
   const headers = {
     Content-Type:application/json,
     X-Auth-Token:string
   };

   fetch(https://PEM-SERVER-IP/api/v14/server/{server_id},
   {
     method: PUT,
     body: inputBody,
     headers: headers
   })
   .then(function(res) {
       return res.json();
   }).then(function(body) {
       console.log(body);
   });

``PUT /server/{server_id}``

- Update the server information.\*

**Body parameter**

.. code:: json

   {
     "name": "string",
     "host": "string",
     "port": 0,
     "db": "string",
     "serviceid": "string",
     "connection_params": {
       "added": [
         {
           "keyword": "hostaddr",
           "name": "hostaddr",
           "value": "qwde"
         }
       ],
       "changed": [
         {
           "keyword": "connect_timeout",
           "name": "connect_timeout",
           "value": "20"
         }
       ],
       "deleted": [
         {
           "keyword": "sslmode",
           "name": "sslmode",
           "value": "prefer"
         }
       ]
     },
     "alert_blackout": true,
     "team": "string",
     "is_remote_monitoring": true,
     "tags": {
       "added": [
         {
           "color": "#0C767A",
           "text": "tag4"
         }
       ],
       "deleted": [
         {
           "text": "tag1",
           "color": "#8789AC",
           "old_text": "tag2"
         }
       ],
       "changed": [
         {
           "old_text": "tag",
           "text": "tag3"
         }
       ]
     },
     "replication_solution": "none",
     "efm_cluster_name": "string",
     "efm_service_name": "string",
     "efm_installation_path": "string",
     "patroni_cluster_name": "string",
     "patroni_installation_path": "string",
     "patroni_config_path": "string",
     "comment": "string",
     "username": "string",
     "gid": 0,
     "hostaddr": "string",
     "db_res": "string",
     "role": "string",
     "agent_id": 0,
     "asb_host": "string",
     "asb_port": 0,
     "asb_username": "string",
     "asb_database": "string",
     "asb_sslmode": "prefer",
     "asb_password": "string",
     "agent_allowtakeover": false,
     "fgcolor": "#000000",
     "bgcolor": "#FFFFFF",
     "sslcompression": false,
     "use_ssh_tunnel": false,
     "tunnel_host": "string",
     "tunnel_port": 22,
     "tunnel_username": "string",
     "tunnel_password": "string",
     "tunnel_authentication": false,
     "tunnel_identity_file": "string",
     "post_connection_sql": "string"
   }

.. _parameters-12:

Parameters
^^^^^^^^^^

.. csv-table::
  :header: Name,In,Type,Required,Description
  :widths: 11,7,7,7,17
  :align: left
  :class: longtable

  server_id,path,string,true,none
  X-Auth-Token,header,string,true,Token of authorization
  body,body,:ref:`ServerBodyUpdate<ServerBodyUpdate>` ,true,none

**Example responses**

.. _responses-12:

Responses
^^^^^^^^^

.. csv-table::
  :header: Status,Meaning,Description,Schema
  :widths: 15,12,12,20
  :align: left
  :class: longtable

  200,:ref:`Invoking the server installer from the command line<Invoking the server installer from the command line>` ,Updated successfully.,None

.. _response-schema-7:

Response Schema
^^^^^^^^^^^^^^^

..  Note::
   This operation does not require authentication

delete\_\ *server*\ {server_id}
-------------------------------

**Code samples**

.. code:: shell


   #  You can also use wget

   curl -X DELETE https://PEM-SERVER-IP/api/v14/server/{server_id} \
     -H X-Auth-Token: string

.. code:: python

   import requests
   headers = {
     X-Auth-Token: string
   }

   r = requests.delete(https://PEM-SERVER-IP/api/v14/server/{server_id}, headers = headers)

   print(r.json())

.. code:: javascript


   const headers = {
     X-Auth-Token:string
   };

   fetch(https://PEM-SERVER-IP/api/v14/server/{server_id},
   {
     method: DELETE,

     headers: headers
   })
   .then(function(res) {
       return res.json();
   }).then(function(body) {
       console.log(body);
   });

``DELETE /server/{server_id}``

- Stop managing the server by PEM.\*

.. _parameters-13:

Parameters
^^^^^^^^^^

.. csv-table::
  :header: Name,In,Type,Required,Description
  :widths: 11,7,7,7,17
  :align: left
  :class: longtable

  server_id,path,string,true,none
  X-Auth-Token,header,string,true,Token of authorization

**Example responses**

.. _responses-13:

Responses
^^^^^^^^^

.. csv-table::
  :header: Status,Meaning,Description,Schema
  :widths: 15,12,12,20
  :align: left
  :class: longtable

  200,:ref:`Invoking the server installer from the command line<Invoking the server installer from the command line>` ,Status 200,None

.. _response-schema-8:

Response Schema
^^^^^^^^^^^^^^^

..  Note::
   This operation does not require authentication

get\_\ *server*\ {sid}\ *database*
----------------------------------

**Code samples**

.. code:: shell


   #  You can also use wget

   curl -X GET https://PEM-SERVER-IP/api/v14/server/{sid}/database/ \
     -H Accept: application/json \
     -H X-Auth-Token: string

.. code:: python

   import requests
   headers = {
     Accept: application/json,
     X-Auth-Token: string
   }

   r = requests.get(https://PEM-SERVER-IP/api/v14/server/{sid}/database/, headers = headers)

   print(r.json())

.. code:: javascript


   const headers = {
     Accept:application/json,
     X-Auth-Token:string
   };

   fetch(https://PEM-SERVER-IP/api/v14/server/{sid}/database/,
   {
     method: GET,

     headers: headers
   })
   .then(function(res) {
       return res.json();
   }).then(function(body) {
       console.log(body);
   });

``GET /server/{sid}/database/``

- Retrieve the list of properties of database(s) for a managed server.\*

.. _parameters-14:

Parameters
^^^^^^^^^^

.. csv-table::
  :header: Name,In,Type,Required,Description
  :widths: 11,7,7,7,17
  :align: left
  :class: longtable

  X-Auth-Token,header,string,true,Token of authorization
  sid,path,integer,true,Server ID

**Example responses**

.. raw:: html

   <Details summary="200 Response">

.. code:: json

   [
     {
       "database_name": "string",
       "connections_allowed": true,
       "system_database": true,
       "recorded_time": "2019-08-24T14:15:22Z",
       "encoding": "string",
       "server_id": 0
     }
   ]

.. raw:: html

   </Details>

.. _responses-14:

Responses
^^^^^^^^^

.. csv-table::
  :header: Status,Meaning,Description,Schema
  :widths: 15,12,12,20
  :align: left
  :class: longtable

  200,:ref:`Invoking the server installer from the command line<Invoking the server installer from the command line>` ,Status 200,Inline

.. _response-schema-9:

Response Schema
^^^^^^^^^^^^^^^

Status Code **200**

.. csv-table::
  :header: Name,Type,Required,Restrictions,Description
  :widths: 12,8,8,8,12
  :align: left
  :class: longtable

  *anonymous*,\ :ref:`Query information <Schemas>` ],false,none,none
  » database_name,string,false,none,Database name
  » connections_allowed,boolean,false,none,Determines whether a connection to the database is allowed.
  » system_database,boolean,false,none,Determines whether the database is a system database.
  » recorded_time,string(date-time),false,none,Specifies when the database was first detected by the PEM agent.
  » encoding,string,false,none,Database encoding
  » server_id,integer,false,none,Server ID of database

..  Note::
   This operation does not require authentication

get\_\ *server*\ {sid}\ *database*\ {db_name}
---------------------------------------------

**Code samples**

.. code:: shell


   #  You can also use wget

   curl -X GET https://PEM-SERVER-IP/api/v14/server/{sid}/database/{db_name} \
     -H Accept: application/json \
     -H X-Auth-Token: string

.. code:: python

   import requests
   headers = {
     Accept: application/json,
     X-Auth-Token: string
   }

   r = requests.get(https://PEM-SERVER-IP/api/v14/server/{sid}/database/{db_name}, headers = headers)

   print(r.json())

.. code:: javascript


   const headers = {
     Accept:application/json,
     X-Auth-Token:string
   };

   fetch(https://PEM-SERVER-IP/api/v14/server/{sid}/database/{db_name},
   {
     method: GET,

     headers: headers
   })
   .then(function(res) {
       return res.json();
   }).then(function(body) {
       console.log(body);
   });

``GET /server/{sid}/database/{db_name}``

- Retrieve the properties of a particular database of a managed
  server.\*

.. _parameters-15:

Parameters
^^^^^^^^^^

.. csv-table::
  :header: Name,In,Type,Required,Description
  :widths: 11,7,7,7,17
  :align: left
  :class: longtable

  sid,path,integer,true,Server ID
  db_name,path,string,true,none
  X-Auth-Token,header,string,true,Token of authorization

**Example responses**

.. raw:: html

   <Details summary="200 Response">

.. code:: json

   {
     "database_name": "string",
     "connections_allowed": true,
     "system_database": true,
     "recorded_time": "2019-08-24T14:15:22Z",
     "encoding": "string",
     "server_id": 0
   }

.. raw:: html

   </Details>

.. _responses-15:

Responses
^^^^^^^^^

.. csv-table::
  :header: Status,Meaning,Description,Schema
  :widths: 15,12,12,20
  :align: left
  :class: longtable

  200,:ref:`Invoking the server installer from the command line<Invoking the server installer from the command line>` ,Status 200,:ref:`PEM backend database server and agent connection certificates<PEM backend database server and agent connection certificates>` 

..  Note::
   This operation does not require authentication

get\_\ *server*\ {sid}\ *database*\ {db_name}\ *schema*
-------------------------------------------------------

**Code samples**

.. code:: shell


   #  You can also use wget

   curl -X GET https://PEM-SERVER-IP/api/v14/server/{sid}/database/{db_name}/schema/ \
     -H Accept: application/json \
     -H X-Auth-Token: string

.. code:: python

   import requests
   headers = {
     Accept: application/json,
     X-Auth-Token: string
   }

   r = requests.get(https://PEM-SERVER-IP/api/v14/server/{sid}/database/{db_name}/schema/, headers = headers)

   print(r.json())

.. code:: javascript


   const headers = {
     Accept:application/json,
     X-Auth-Token:string
   };

   fetch(https://PEM-SERVER-IP/api/v14/server/{sid}/database/{db_name}/schema/,
   {
     method: GET,

     headers: headers
   })
   .then(function(res) {
       return res.json();
   }).then(function(body) {
       console.log(body);
   });

``GET /server/{sid}/database/{db_name}/schema/``

- Retrieve the list of properties of schema(s) for a particular database
  of a managed server.\*

.. _parameters-16:

Parameters
^^^^^^^^^^

.. csv-table::
  :header: Name,In,Type,Required,Description
  :widths: 11,7,7,7,17
  :align: left
  :class: longtable

  sid,path,integer,true,Server ID
  db_name,path,string,true,Database name
  X-Auth-Token,header,string,true,Token of authorization

**Example responses**

.. raw:: html

   <Details summary="200 Response">

.. code:: json

   [
     {
       "schema_name": "string",
       "database_name": "string",
       "server_id": 0,
       "recorded_time": "2019-08-24T14:15:22Z"
     }
   ]

.. raw:: html

   </Details>

.. _responses-16:

Responses
^^^^^^^^^

.. csv-table::
  :header: Status,Meaning,Description,Schema
  :widths: 15,12,12,20
  :align: left
  :class: longtable

  200,:ref:`Invoking the server installer from the command line<Invoking the server installer from the command line>` ,Status 200,Inline

.. _response-schema-10:

Response Schema
^^^^^^^^^^^^^^^

Status Code **200**

.. csv-table::
  :header: Name,Type,Required,Restrictions,Description
  :widths: 12,8,8,8,12
  :align: left
  :class: longtable

  *anonymous*,\ :ref:`Query information <Schemas>` ],false,none,none
  » schema_name,string,false,none,Schema name
  » database_name,string,false,none,Database name of schema
  » server_id,integer,false,none,Server ID schema
  » recorded_time,string(date-time),false,none,Specifies when schema was first detected by PEM agent.

..  Note::
   This operation does not require authentication

get\_\ *server*\ {sid}\ *database*\ {db_name}\ *schema*\ {schema_name}
----------------------------------------------------------------------

**Code samples**

.. code:: shell


   #  You can also use wget

   curl -X GET https://PEM-SERVER-IP/api/v14/server/{sid}/database/{db_name}/schema/{schema_name} \
     -H Accept: application/json \
     -H X-Auth-Token: string

.. code:: python

   import requests
   headers = {
     Accept: application/json,
     X-Auth-Token: string
   }

   r = requests.get(https://PEM-SERVER-IP/api/v14/server/{sid}/database/{db_name}/schema/{schema_name}, headers = headers)

   print(r.json())

.. code:: javascript


   const headers = {
     Accept:application/json,
     X-Auth-Token:string
   };

   fetch(https://PEM-SERVER-IP/api/v14/server/{sid}/database/{db_name}/schema/{schema_name},
   {
     method: GET,

     headers: headers
   })
   .then(function(res) {
       return res.json();
   }).then(function(body) {
       console.log(body);
   });

``GET /server/{sid}/database/{db_name}/schema/{schema_name}``

- Retrieve the properties of schema(s) for a particular database of a
  managed server.\*

.. _parameters-17:

Parameters
^^^^^^^^^^

.. csv-table::
  :header: Name,In,Type,Required,Description
  :widths: 11,7,7,7,17
  :align: left
  :class: longtable

  sid,path,integer,true,Server ID
  db_name,path,string,true,Database name
  schema_name,path,string,true,Schema name
  X-Auth-Token,header,string,true,Token of authorization

**Example responses**

.. raw:: html

   <Details summary="200 Response">

.. code:: json

   {
     "schema_name": "string",
     "database_name": "string",
     "server_id": 0,
     "recorded_time": "2019-08-24T14:15:22Z"
   }

.. raw:: html

   </Details>

.. _responses-17:

Responses
^^^^^^^^^

.. csv-table::
  :header: Status,Meaning,Description,Schema
  :widths: 15,12,12,20
  :align: left
  :class: longtable

  200,:ref:`Invoking the server installer from the command line<Invoking the server installer from the command line>` ,Status 200,:ref:`Using the Schema Diff tool<Using the Schema Diff tool>` 

..  Note::
   This operation does not require authentication

get\_\ *server*\ {sid}\ *database*\ {db_name}\ *schema*\ {schema_name}\ *table*
-------------------------------------------------------------------------------

**Code samples**

.. code:: shell


   #  You can also use wget

   curl -X GET https://PEM-SERVER-IP/api/v14/server/{sid}/database/{db_name}/schema/{schema_name}/table/ \
     -H Accept: application/json \
     -H X-Auth-Token: string

.. code:: python

   import requests
   headers = {
     Accept: application/json,
     X-Auth-Token: string
   }

   r = requests.get(https://PEM-SERVER-IP/api/v14/server/{sid}/database/{db_name}/schema/{schema_name}/table/, headers = headers)

   print(r.json())

.. code:: javascript


   const headers = {
     Accept:application/json,
     X-Auth-Token:string
   };

   fetch(https://PEM-SERVER-IP/api/v14/server/{sid}/database/{db_name}/schema/{schema_name}/table/,
   {
     method: GET,

     headers: headers
   })
   .then(function(res) {
       return res.json();
   }).then(function(body) {
       console.log(body);
   });

``GET /server/{sid}/database/{db_name}/schema/{schema_name}/table/``

- Retrieve the list of properties of tables residing in a schema for a
  particular database of a managed server.\*

.. _parameters-18:

Parameters
^^^^^^^^^^

.. csv-table::
  :header: Name,In,Type,Required,Description
  :widths: 11,7,7,7,17
  :align: left
  :class: longtable

  sid,path,integer,true,Server ID
  db_name,path,string,true,Database name
  schema_name,path,string,true,Schema name
  X-Auth-Token,header,string,true,Token of authorization

**Example responses**

.. raw:: html

   <Details summary="200 Response">

.. code:: json

   [
     {
       "table_name": "string",
       "schema_name": "string",
       "database_name": "string",
       "server_id": 0,
       "has_primary_key": true,
       "recorded_time": "string"
     }
   ]

.. raw:: html

   </Details>

.. _responses-18:

Responses
^^^^^^^^^

.. csv-table::
  :header: Status,Meaning,Description,Schema
  :widths: 15,12,12,20
  :align: left
  :class: longtable

  200,:ref:`Invoking the server installer from the command line<Invoking the server installer from the command line>` ,Status 200,Inline

.. _response-schema-11:

Response Schema
^^^^^^^^^^^^^^^

Status Code **200**

.. csv-table::
  :header: Name,Type,Required,Restrictions,Description
  :widths: 12,8,8,8,12
  :align: left
  :class: longtable

  *anonymous*,\ :ref:`Query information <Schemas>` ],false,none,none
  » table_name,string,false,none,Table name
  » schema_name,string,false,none,Schema name
  » database_name,string,false,none,Database name
  » server_id,integer,false,none,Server ID
  » has_primary_key,boolean,false,none,Determines whether table has a primary key.
  » recorded_time,string,false,none,Specifies when table was first detected by the PEM agent.

..  Note::
   This operation does not require authentication

get\_\ *server*\ {sid}\ *database*\ {db_name}\ *schema*\ {schema_name}\ *table*\ {table_name}
---------------------------------------------------------------------------------------------

**Code samples**

.. code:: shell


   #  You can also use wget

   curl -X GET https://PEM-SERVER-IP/api/v14/server/{sid}/database/{db_name}/schema/{schema_name}/table/{table_name} \
     -H Accept: application/json \
     -H X-Auth-Token: string

.. code:: python

   import requests
   headers = {
     Accept: application/json,
     X-Auth-Token: string
   }

   r = requests.get(https://PEM-SERVER-IP/api/v14/server/{sid}/database/{db_name}/schema/{schema_name}/table/{table_name}, headers = headers)

   print(r.json())

.. code:: javascript


   const headers = {
     Accept:application/json,
     X-Auth-Token:string
   };

   fetch(https://PEM-SERVER-IP/api/v14/server/{sid}/database/{db_name}/schema/{schema_name}/table/{table_name},
   {
     method: GET,

     headers: headers
   })
   .then(function(res) {
       return res.json();
   }).then(function(body) {
       console.log(body);
   });

``GET /server/{sid}/database/{db_name}/schema/{schema_name}/table/{table_name}``

- Retrieve the properties of tables residing in a schema for a
  particular database of a managed server.\*

.. _parameters-19:

Parameters
^^^^^^^^^^

.. csv-table::
  :header: Name,In,Type,Required,Description
  :widths: 11,7,7,7,17
  :align: left
  :class: longtable

  sid,path,integer,true,Server ID
  db_name,path,string,true,Database name
  schema_name,path,string,true,Schema name
  table_name,path,string,true,none
  X-Auth-Token,header,string,true,Token of authorization

**Example responses**

.. raw:: html

   <Details summary="200 Response">

.. code:: json

   {
     "table_name": "string",
     "schema_name": "string",
     "database_name": "string",
     "server_id": 0,
     "has_primary_key": true,
     "recorded_time": "string"
   }

.. raw:: html

   </Details>

.. _responses-19:

Responses
^^^^^^^^^

.. csv-table::
  :header: Status,Meaning,Description,Schema
  :widths: 15,12,12,20
  :align: left
  :class: longtable

  200,:ref:`Invoking the server installer from the command line<Invoking the server installer from the command line>` ,Status 200,:ref:`Table relationship options<Table relationship options>` 

..  Note::
   This operation does not require authentication

get\_\ *server*\ {sid}\ *database*\ {db_name}\ *schema*\ {schema_name}\ *index*
-------------------------------------------------------------------------------

**Code samples**

.. code:: shell


   #  You can also use wget

   curl -X GET https://PEM-SERVER-IP/api/v14/server/{sid}/database/{db_name}/schema/{schema_name}/index/ \
     -H Accept: application/json \
     -H X-Auth-Token: string

.. code:: python

   import requests
   headers = {
     Accept: application/json,
     X-Auth-Token: string
   }

   r = requests.get(https://PEM-SERVER-IP/api/v14/server/{sid}/database/{db_name}/schema/{schema_name}/index/, headers = headers)

   print(r.json())

.. code:: javascript


   const headers = {
     Accept:application/json,
     X-Auth-Token:string
   };

   fetch(https://PEM-SERVER-IP/api/v14/server/{sid}/database/{db_name}/schema/{schema_name}/index/,
   {
     method: GET,

     headers: headers
   })
   .then(function(res) {
       return res.json();
   }).then(function(body) {
       console.log(body);
   });

``GET /server/{sid}/database/{db_name}/schema/{schema_name}/index/``

- Retrieve the list of properties of indexes residing in a schema for a
  particular database of a managed server.\*

.. _parameters-20:

Parameters
^^^^^^^^^^

.. csv-table::
  :header: Name,In,Type,Required,Description
  :widths: 11,7,7,7,17
  :align: left
  :class: longtable

  sid,path,integer,true,Server ID
  db_name,path,string,true,Database name
  schema_name,path,string,true,Schema name
  X-Auth-Token,header,string,true,Token of authorization

**Example responses**

.. raw:: html

   <Details summary="200 Response">

.. code:: json

   [
     {
       "index_name": "string",
       "ind_keys": [
         0
       ],
       "table_name": "string",
       "schema_name": "string",
       "database_name": "string",
       "server_id": 0,
       "recorded_time": "string"
     }
   ]

.. raw:: html

   </Details>

.. _responses-20:

Responses
^^^^^^^^^

.. csv-table::
  :header: Status,Meaning,Description,Schema
  :widths: 15,12,12,20
  :align: left
  :class: longtable

  200,:ref:`Invoking the server installer from the command line<Invoking the server installer from the command line>` ,Status 200,Inline

.. _response-schema-12:

Response Schema
^^^^^^^^^^^^^^^

Status Code **200**

.. csv-table::
  :header: Name,Type,Required,Restrictions,Description
  :widths: 12,8,8,8,12
  :align: left
  :class: longtable

  *anonymous*,\ :ref:`Query information <Managing SSL certificates>` ],false,none,none
  » index_name,string,false,none,Index name
  » ind_keys,[integer],false,none,Indexed column positions in table
  » table_name,string,false,none,Table name
  » schema_name,string,false,none,Schema
  » database_name,string,false,none,Database name
  » server_id,integer,false,none,Server ID
  » recorded_time,string,false,none,Specifies when index was first detected by PEM agent.

..  Note::
   This operation does not require authentication

get\_\ *server*\ {sid}\ *database*\ {db_name}\ *schema*\ {schema_name}\ *index*\ {index_name}
---------------------------------------------------------------------------------------------

**Code samples**

.. code:: shell


   #  You can also use wget

   curl -X GET https://PEM-SERVER-IP/api/v14/server/{sid}/database/{db_name}/schema/{schema_name}/index/{index_name} \
     -H Accept: application/json \
     -H X-Auth-Token: string

.. code:: python

   import requests
   headers = {
     Accept: application/json,
     X-Auth-Token: string
   }

   r = requests.get(https://PEM-SERVER-IP/api/v14/server/{sid}/database/{db_name}/schema/{schema_name}/index/{index_name}, headers = headers)

   print(r.json())

.. code:: javascript


   const headers = {
     Accept:application/json,
     X-Auth-Token:string
   };

   fetch(https://PEM-SERVER-IP/api/v14/server/{sid}/database/{db_name}/schema/{schema_name}/index/{index_name},
   {
     method: GET,

     headers: headers
   })
   .then(function(res) {
       return res.json();
   }).then(function(body) {
       console.log(body);
   });

``GET /server/{sid}/database/{db_name}/schema/{schema_name}/index/{index_name}``

- Retrieve the properties of indexes residing in a schema for a
  particular database of a managed server.\*

.. _parameters-21:

Parameters
^^^^^^^^^^

.. csv-table::
  :header: Name,In,Type,Required,Description
  :widths: 11,7,7,7,17
  :align: left
  :class: longtable

  sid,path,integer,true,Server ID
  db_name,path,string,true,Database name
  schema_name,path,string,true,Schema name
  index_name,path,string,true,none
  X-Auth-Token,header,string,true,Token of authorization

**Example responses**

.. raw:: html

   <Details summary="200 Response">

.. code:: json

   {
     "index_name": "string",
     "ind_keys": [
       0
     ],
     "table_name": "string",
     "schema_name": "string",
     "database_name": "string",
     "server_id": 0,
     "recorded_time": "string"
   }

.. raw:: html

   </Details>

.. _responses-21:

Responses
^^^^^^^^^

.. csv-table::
  :header: Status,Meaning,Description,Schema
  :widths: 15,12,12,20
  :align: left
  :class: longtable

  200,:ref:`Invoking the server installer from the command line<Invoking the server installer from the command line>` ,Status 200,:ref:`get__alert_config_server_{server_id}_database_{database_name}_schema_{schema_name}_index_{index_name}<get__alert_config_server_{server_id}_database_{database_name}_schema_{schema_name}_index_{index_name}>` 

..  Note::
   This operation does not require authentication

get\_\ *server*\ {sid}\ *database*\ {db_name}\ *schema*\ {schema_name}\ *sequence*
----------------------------------------------------------------------------------

**Code samples**

.. code:: shell


   #  You can also use wget

   curl -X GET https://PEM-SERVER-IP/api/v14/server/{sid}/database/{db_name}/schema/{schema_name}/sequence/ \
     -H Accept: application/json \
     -H X-Auth-Token: string

.. code:: python

   import requests
   headers = {
     Accept: application/json,
     X-Auth-Token: string
   }

   r = requests.get(https://PEM-SERVER-IP/api/v14/server/{sid}/database/{db_name}/schema/{schema_name}/sequence/, headers = headers)

   print(r.json())

.. code:: javascript


   const headers = {
     Accept:application/json,
     X-Auth-Token:string
   };

   fetch(https://PEM-SERVER-IP/api/v14/server/{sid}/database/{db_name}/schema/{schema_name}/sequence/,
   {
     method: GET,

     headers: headers
   })
   .then(function(res) {
       return res.json();
   }).then(function(body) {
       console.log(body);
   });

``GET /server/{sid}/database/{db_name}/schema/{schema_name}/sequence/``

- Retrieve the list of properties of sequences residing in a schema for
  a particular database of a managed server.\*

.. _parameters-22:

Parameters
^^^^^^^^^^

.. csv-table::
  :header: Name,In,Type,Required,Description
  :widths: 11,7,7,7,17
  :align: left
  :class: longtable

  sid,path,integer,true,Server ID
  db_name,path,string,true,Database name
  schema_name,path,string,true,Schema name
  X-Auth-Token,header,string,true,Token of authorization

**Example responses**

.. raw:: html

   <Details summary="200 Response">

.. code:: json

   [
     {
       "sequence_name": "string",
       "schema_name": "string",
       "database_name": "string",
       "server_id": 0,
       "recorded_time": "2019-08-24T14:15:22Z"
     }
   ]

.. raw:: html

   </Details>

.. _responses-22:

Responses
^^^^^^^^^

.. csv-table::
  :header: Status,Meaning,Description,Schema
  :widths: 15,12,12,20
  :align: left
  :class: longtable

  200,:ref:`Invoking the server installer from the command line<Invoking the server installer from the command line>` ,Status 200,Inline

.. _response-schema-13:

Response Schema
^^^^^^^^^^^^^^^

Status Code **200**

.. csv-table::
  :header: Name,Type,Required,Restrictions,Description
  :widths: 12,8,8,8,12
  :align: left
  :class: longtable

  *anonymous*,\ :ref:`Query information <Schemas>` ],false,none,none
  » sequence_name,string,false,none,Sequence name
  » schema_name,string,false,none,Schema name
  » database_name,string,false,none,Database name
  » server_id,integer,false,none,Server ID
  » recorded_time,string(date-time),false,none,Specifies when sequence was first detected by PEM agent.

..  Note::
   This operation does not require authentication

get\_\ *server*\ {sid}\ *database*\ {db_name}\ *schema*\ {schema_name}\ *sequence*\ {sequence_name}
---------------------------------------------------------------------------------------------------

**Code samples**

.. code:: shell


   #  You can also use wget

   curl -X GET https://PEM-SERVER-IP/api/v14/server/{sid}/database/{db_name}/schema/{schema_name}/sequence/{sequence_name} \
     -H Accept: application/json \
     -H X-Auth-Token: string

.. code:: python

   import requests
   headers = {
     Accept: application/json,
     X-Auth-Token: string
   }

   r = requests.get(https://PEM-SERVER-IP/api/v14/server/{sid}/database/{db_name}/schema/{schema_name}/sequence/{sequence_name}, headers = headers)

   print(r.json())

.. code:: javascript


   const headers = {
     Accept:application/json,
     X-Auth-Token:string
   };

   fetch(https://PEM-SERVER-IP/api/v14/server/{sid}/database/{db_name}/schema/{schema_name}/sequence/{sequence_name},
   {
     method: GET,

     headers: headers
   })
   .then(function(res) {
       return res.json();
   }).then(function(body) {
       console.log(body);
   });

``GET /server/{sid}/database/{db_name}/schema/{schema_name}/sequence/{sequence_name}``

- Retrieve the properties of sequences residing in a schema for a
  particular database of a managed server.\*

.. _parameters-23:

Parameters
^^^^^^^^^^

.. csv-table::
  :header: Name,In,Type,Required,Description
  :widths: 11,7,7,7,17
  :align: left
  :class: longtable

  sid,path,integer,true,Server ID
  db_name,path,string,true,Database name
  schema_name,path,string,true,Schema name
  sequence_name,path,string,true,none
  X-Auth-Token,header,string,true,Token of authorization

**Example responses**

.. raw:: html

   <Details summary="200 Response">

.. code:: json

   {
     "sequence_name": "string",
     "schema_name": "string",
     "database_name": "string",
     "server_id": 0,
     "recorded_time": "2019-08-24T14:15:22Z"
   }

.. raw:: html

   </Details>

.. _responses-23:

Responses
^^^^^^^^^

.. csv-table::
  :header: Status,Meaning,Description,Schema
  :widths: 15,12,12,20
  :align: left
  :class: longtable

  200,:ref:`Invoking the server installer from the command line<Invoking the server installer from the command line>` ,Status 200,:ref:`get__alert_config_server_{server_id}_database_{database_name}_schema_{schema_name}_sequence_{sequence_name}<get__alert_config_server_{server_id}_database_{database_name}_schema_{schema_name}_sequence_{sequence_name}>` 

..  Note::
   This operation does not require authentication

get\_\ *server*\ {sid}\ *database*\ {db_name}\ *schema*\ {schema_name}\ *view*
------------------------------------------------------------------------------

**Code samples**

.. code:: shell


   #  You can also use wget

   curl -X GET https://PEM-SERVER-IP/api/v14/server/{sid}/database/{db_name}/schema/{schema_name}/view/ \
     -H Accept: application/json \
     -H X-Auth-Token: string

.. code:: python

   import requests
   headers = {
     Accept: application/json,
     X-Auth-Token: string
   }

   r = requests.get(https://PEM-SERVER-IP/api/v14/server/{sid}/database/{db_name}/schema/{schema_name}/view/, headers = headers)

   print(r.json())

.. code:: javascript


   const headers = {
     Accept:application/json,
     X-Auth-Token:string
   };

   fetch(https://PEM-SERVER-IP/api/v14/server/{sid}/database/{db_name}/schema/{schema_name}/view/,
   {
     method: GET,

     headers: headers
   })
   .then(function(res) {
       return res.json();
   }).then(function(body) {
       console.log(body);
   });

``GET /server/{sid}/database/{db_name}/schema/{schema_name}/view/``

- Retrieve the list of properties of views residing in a schema for a
  particular database of a managed server.\*

.. _parameters-24:

Parameters
^^^^^^^^^^

.. csv-table::
  :header: Name,In,Type,Required,Description
  :widths: 11,7,7,7,17
  :align: left
  :class: longtable

  sid,path,integer,true,Server ID
  db_name,path,string,true,Database name
  schema_name,path,string,true,Schema name
  X-Auth-Token,header,string,true,Token of authorization

**Example responses**

.. raw:: html

   <Details summary="200 Response">

.. code:: json

   [
     {
       "view_name": "string",
       "view_type": "string",
       "ispopulated": true,
       "view_owner": "string",
       "definition": "string",
       "tablespace_name": "string",
       "schema_name": "string",
       "database_name": "string",
       "server_id": 0,
       "recorded_time": "string"
     }
   ]

.. raw:: html

   </Details>

.. _responses-24:

Responses
^^^^^^^^^

.. csv-table::
  :header: Status,Meaning,Description,Schema
  :widths: 15,12,12,20
  :align: left
  :class: longtable

  200,:ref:`Invoking the server installer from the command line<Invoking the server installer from the command line>` ,Status 200,Inline

.. _response-schema-14:

Response Schema
^^^^^^^^^^^^^^^

Status Code **200**

.. csv-table::
  :header: Name,Type,Required,Restrictions,Description
  :widths: 12,8,8,8,12
  :align: left
  :class: longtable

  *anonymous*,\ :ref:`Query information <Schemas>` ],false,none,none
  » view_name,string,false,none,View name
  » view_type,string,false,none,View type
  » ispopulated,boolean,false,none,Determines whether the view is populated.
  » view_owner,string,false,none,View owner
  » definition,string,false,none,View definition
  » tablespace_name,string,false,none,View tablespace
  » schema_name,string,false,none,View schema
  » database_name,string,false,none,View database
  » server_id,integer,false,none,View server ID
  » recorded_time,string,false,none,Specifies when view was first detected by PEM agent.

..  Note::
   This operation does not require authentication

get\_\ *server*\ {sid}\ *database*\ {db_name}\ *schema*\ {schema_name}\ *view*\ {view_name}
-------------------------------------------------------------------------------------------

**Code samples**

.. code:: shell


   #  You can also use wget

   curl -X GET https://PEM-SERVER-IP/api/v14/server/{sid}/database/{db_name}/schema/{schema_name}/view/{view_name} \
     -H Accept: application/json \
     -H X-Auth-Token: string

.. code:: python

   import requests
   headers = {
     Accept: application/json,
     X-Auth-Token: string
   }

   r = requests.get(https://PEM-SERVER-IP/api/v14/server/{sid}/database/{db_name}/schema/{schema_name}/view/{view_name}, headers = headers)

   print(r.json())

.. code:: javascript


   const headers = {
     Accept:application/json,
     X-Auth-Token:string
   };

   fetch(https://PEM-SERVER-IP/api/v14/server/{sid}/database/{db_name}/schema/{schema_name}/view/{view_name},
   {
     method: GET,

     headers: headers
   })
   .then(function(res) {
       return res.json();
   }).then(function(body) {
       console.log(body);
   });

``GET /server/{sid}/database/{db_name}/schema/{schema_name}/view/{view_name}``

- Retrieve the properties of views residing in a schema for a particular
  database of a managed server.\*

.. _parameters-25:

Parameters
^^^^^^^^^^

.. csv-table::
  :header: Name,In,Type,Required,Description
  :widths: 11,7,7,7,17
  :align: left
  :class: longtable

  sid,path,integer,true,Server ID
  db_name,path,string,true,Database name
  schema_name,path,string,true,Schema name
  view_name,path,string,true,none
  X-Auth-Token,header,string,true,Token of authorization

**Example responses**

.. raw:: html

   <Details summary="200 Response">

.. code:: json

   {
     "view_name": "string",
     "view_type": "string",
     "ispopulated": true,
     "view_owner": "string",
     "definition": "string",
     "tablespace_name": "string",
     "schema_name": "string",
     "database_name": "string",
     "server_id": 0,
     "recorded_time": "string"
   }

.. raw:: html

   </Details>

.. _responses-25:

Responses
^^^^^^^^^

.. csv-table::
  :header: Status,Meaning,Description,Schema
  :widths: 15,12,12,20
  :align: left
  :class: longtable

  200,:ref:`Invoking the server installer from the command line<Invoking the server installer from the command line>` ,Status 200,:ref:`Reviewing or modifying agent properties<Reviewing or modifying agent properties>` 

..  Note::
   This operation does not require authentication

get\_\ *server*\ {sid}\ *database*\ {db_name}\ *schema*\ {schema_name}\ *function*
----------------------------------------------------------------------------------

**Code samples**

.. code:: shell


   #  You can also use wget

   curl -X GET https://PEM-SERVER-IP/api/v14/server/{sid}/database/{db_name}/schema/{schema_name}/function/ \
     -H Accept: application/json \
     -H X-Auth-Token: string

.. code:: python

   import requests
   headers = {
     Accept: application/json,
     X-Auth-Token: string
   }

   r = requests.get(https://PEM-SERVER-IP/api/v14/server/{sid}/database/{db_name}/schema/{schema_name}/function/, headers = headers)

   print(r.json())

.. code:: javascript


   const headers = {
     Accept:application/json,
     X-Auth-Token:string
   };

   fetch(https://PEM-SERVER-IP/api/v14/server/{sid}/database/{db_name}/schema/{schema_name}/function/,
   {
     method: GET,

     headers: headers
   })
   .then(function(res) {
       return res.json();
   }).then(function(body) {
       console.log(body);
   });

``GET /server/{sid}/database/{db_name}/schema/{schema_name}/function/``

- Retrieve the list of properties of functions residing in a schema for
  a particular database of a managed server.\*

.. _parameters-26:

Parameters
^^^^^^^^^^

.. csv-table::
  :header: Name,In,Type,Required,Description
  :widths: 11,7,7,7,17
  :align: left
  :class: longtable

  sid,path,integer,true,Server ID
  db_name,path,string,true,Database name
  schema_name,path,string,true,Schema name
  X-Auth-Token,header,string,true,Token of authorization

**Example responses**

.. raw:: html

   <Details summary="200 Response">

.. code:: json

   [
     {
       "function_name": "string",
       "function_type": "string",
       "return_type": "string",
       "arg_types": [
         "string"
       ],
       "function_binary": "string",
       "extension_name": "string",
       "package_name": "string",
       "schema_name": "string",
       "database_name": "string",
       "server_id": 0,
       "recorded_time": "2019-08-24T14:15:22Z"
     }
   ]

.. raw:: html

   </Details>

.. _responses-26:

Responses
^^^^^^^^^

.. csv-table::
  :header: Status,Meaning,Description,Schema
  :widths: 15,12,12,20
  :align: left
  :class: longtable

  200,:ref:`Invoking the server installer from the command line<Invoking the server installer from the command line>` ,Status 200,Inline

.. _response-schema-15:

Response Schema
^^^^^^^^^^^^^^^

Status Code **200**

.. csv-table::
  :header: Name,Type,Required,Restrictions,Description
  :widths: 12,8,8,8,12
  :align: left
  :class: longtable

  *anonymous*,\ :ref:`Query information <Schemas>` ],false,none,none
  » function_name,string,false,none,Function name
  » function_type,string,false,none,Function type
  » return_type,string,false,none,Function return type
  » arg_types,[string],false,none,Function argument types
  » function_binary,string,false,none,none
  » extension_name,string,false,none,none
  » package_name,string,false,none,Function package name
  » schema_name,string,false,none,Function schema
  » database_name,string,false,none,Function database name
  » server_id,integer,false,none,Function server id
  » recorded_time,string(date-time),false,none,Specifies when function was first detected by PEM agent.

..  Note::
   This operation does not require authentication

get\_\ *server*\ {sid}\ *database*\ {db_name}\ *schema*\ {schema_name}\ *function*\ {function_name}
---------------------------------------------------------------------------------------------------

**Code samples**

.. code:: shell


   #  You can also use wget

   curl -X GET https://PEM-SERVER-IP/api/v14/server/{sid}/database/{db_name}/schema/{schema_name}/function/{function_name} \
     -H Accept: application/json \
     -H X-Auth-Token: string

.. code:: python

   import requests
   headers = {
     Accept: application/json,
     X-Auth-Token: string
   }

   r = requests.get(https://PEM-SERVER-IP/api/v14/server/{sid}/database/{db_name}/schema/{schema_name}/function/{function_name}, headers = headers)

   print(r.json())

.. code:: javascript


   const headers = {
     Accept:application/json,
     X-Auth-Token:string
   };

   fetch(https://PEM-SERVER-IP/api/v14/server/{sid}/database/{db_name}/schema/{schema_name}/function/{function_name},
   {
     method: GET,

     headers: headers
   })
   .then(function(res) {
       return res.json();
   }).then(function(body) {
       console.log(body);
   });

``GET /server/{sid}/database/{db_name}/schema/{schema_name}/function/{function_name}``

- Retrieve the properties of functions residing in a schema for a
  particular database of a managed server.\*

.. _parameters-27:

Parameters
^^^^^^^^^^

.. csv-table::
  :header: Name,In,Type,Required,Description
  :widths: 11,7,7,7,17
  :align: left
  :class: longtable

  sid,path,integer,true,Server ID
  db_name,path,string,true,Database name
  schema_name,path,string,true,Schema name
  function_name,path,string,true,none
  X-Auth-Token,header,string,true,Token of authorization

**Example responses**

.. raw:: html

   <Details summary="200 Response">

.. code:: json

   {
     "function_name": "string",
     "function_type": "string",
     "return_type": "string",
     "arg_types": [
       "string"
     ],
     "function_binary": "string",
     "extension_name": "string",
     "package_name": "string",
     "schema_name": "string",
     "database_name": "string",
     "server_id": 0,
     "recorded_time": "2019-08-24T14:15:22Z"
   }

.. raw:: html

   </Details>

.. _responses-27:

Responses
^^^^^^^^^

.. csv-table::
  :header: Status,Meaning,Description,Schema
  :widths: 15,12,12,20
  :align: left
  :class: longtable

  200,:ref:`Invoking the server installer from the command line<Invoking the server installer from the command line>` ,Status 200,:ref:`Functionality affected by limiting operating system privileges<Functionality affected by limiting operating system privileges>` 

..  Note::
   This operation does not require authentication
