![background image](http://html1.mh-extra.com/html/amx/dtv-vision2-integration-diagram/dtv-vision2-integration-diagram_operation-reference-manual_2938670007.webp)
Using the API
1
Vision
2
API Guide
Using the API
The control API for Vision
2
enables external control of the system. The control API is accessible from the
Master server in the Vision
2
system, and the Vision
2
system manages sending subsequent requests to other
servers in the system. A programmer using the API should not have to know which server to send an API
request to, as all requests go to the Master server.
Controlling the Amino Set-Top Box
The following sections detail how to use the Vision
2
control API with the Amino set-top box.
Forcing a Set-Top Box to Play a Specific Live Channel
Before using the API, you must first obtain a list of available set-top boxes using the
v2Master_STB_Amino_GetSTBs
command. This command is used by accessing a Vision
2
server from a web
browser. For example, the command can be used in the following URL:
http://<server>/v2services/v2_API/v2_APIAdminService.asmx/v2Master_STB_Amino_GetSTBs
where <server> is the name of the Master server. This command returns XML code similar to the following:
<?xml version="1.0" encoding="utf-8" ?>
<v2>
<result>OK</result>
<stbs localip="43.192.168.100">
<stb
name="Main Reception"
status="playing video on demand"
playing="Welcome to AMX"
playingraw="rtsp://43.192.168.100:8554/
H:\vcContent\Archive1\1500\68\ts\high\Video.ts"
ip="43.192.168.110"
pending="nothing"
pendingparams="-1"
screensaver="0"
arc="true" />
<stb
name="Board Room"
status="idle"
playing=" "
playingraw=" "
ip="43.192.168.111"
pending="nothing"
pendingparams="-1"
screensaver="0"
arc="true" />
</stbs>
</v2>
From this XML code, all you need to extract is the name and IP attributes to provide a means of selecting the
desired STB:
"Main Reception" = "43.192.168.110"
"Board Room" = "43.192.168.111"