MAPI Manual

NAME

GET_ROUTER

FUNCTION

Get a router

SYNOPSIS

router_name, mcp_channeltype_id

DESCRIPTION

This function allows admins to get the details of a router.

Required Parameters

* action: GET_ROUTER.
* router_name: name of the router.

* mcp_channeltype_id: channel type. Available channel types are:

  • voice,
  • email,
  • sms,
  • CHANNELTYPE_LINKACTION,
  • CHANNELTYPE_TEXT2SPEECH.

RETURN DATA

The response contains the following attributes:
* mcp_org_id: ID of the organisation using the router.
* mcp_router_id: router ID.
* mcp_channeltype_id: channel type of the router.
* router_name: router name.
* router_title: title of the router.
* router_workmode: work mode.
* router_type: type of the router.
* gateway_assign_type: type of how the router is associated with a gateway.
* destlock_seconds: specifies how long the router will be locked.
* mcp_channeltype_funclass_id:

* isactive: specifies whether the router is active or not. Available values are given below:

  • 1: active,
  • 0: inactive.

* priority: priority of the router.

* mcp_router_rule: contains number patterns that the router accepts, and the gateway ID that is associated with the router.

* mcp_router_var:

ROLE PERMITTED

Admin

EXAMPLES

The following example shows a successful HTTP GET request and response.

Request:

http://app02.yvntech.com/MapIHttpS/MapIS?action=GET_ROUTER&router_name=voice_default_allowall&mcp_channeltype_id=voice&login_name=admin@example.com&login_passwd=2222

Response:

<result tftype='1' infotype='0'>
    <resultset name="mcp_router">
        <row>
            <field name="mcp_org_id">9000</field>
            <field name="mcp_router_id">1</field>
            <field name="mcp_channeltype_id">voice</field>
            <field name="router_name">voice_default_allowall</field>
            <field name="router_title">voice_default_allowall</field>
            <field name="router_workmode">WORKMODE_NORMAL</field>
            <field name="router_type">MCPTYPE_UNIQUEID</field>
            <field name="gateway_assign_type">MCPTYPE_ASSIGN_BYSYS</field>
            <field name="destlock_seconds">7200</field>
            <field name="mcp_channeltype_funclass_id">0</field>
            <field name="isactive">1</field>
            <field name="priority">1</field>
            <resultset name="mcp_router_rule">
                <row>
                    <field name="router_flag">%</field>
                    <field name="mcp_gateway_id">1</field>
                </row>
            </resultset>
            <resultset name="mcp_router_var" />
        </row>
    </resultset>
</result>

TIPS

ENVIRONMENT

AUTHOR

YVN Tech

SEE ALSO

Mweb v2.0 YVNTECH 2014