Documentation forSolarWinds Service Desk

Mobile Devices:

Getting a list of all mobile devices:

curl -H "X-Samanage-Authorization: Bearer TOKEN" -H 'Accept: application/vnd.samanage.v2.1+xml' -X GET

https://api.samanage.com/mobiles.xml

Getting mobile device details (using mobile device ID number):

curl -H "X-Samanage-Authorization: Bearer TOKEN" -H 'Accept: application/vnd.samanage.v2.1+xml' -X GET https://api.samanage.com/mobiles/MOBILE_ID.xml

Create a new mobile device:

curl -H "X-Samanage-Authorization: Bearer TOKEN" -d 'INPUT_XML' -H 'Accept: application/xml' -H 'Content-Type:text/xml' -X POST https://api.samanage.com/mobiles.xml

Required fields:

<status>,<model>,<manufacturer>,<serial_number>

XML Example:

<mobile>

  <status>

    <name>Status</name>

  </status>

  <device_type>Tablet</device_type>

  <manufacturer>manufacturer</manufacturer>

  <model>Model</model>

  <company_issued>true/false</company_issued>

  <serial_number>serial_number</serial_number>

  <imei>imei</imei>

  <description>Description</description>

  <user>

    <email>email</email>

  </user> 

  <technical_contact>    

    <email>email</email>

  </technical_contact> 

  <site>

   <name>Site Name</name>

  </site>

  <department>

    <name>Department Name</name>

  </department>
  <custom_fields_values>

    <custom_fields_value>

      <name>FIELD_NAME</name>

      <value>CONTENT</value>

    </custom_fields_value>

  </custom_fields_values>

</mobile>

 

JSON Example:

{

  "mobile":{

    "status":[{"name":"Status"}],

    "device_type":"Tablet",

    "manufacturer":"manufacturer",

    "model":"model",

    "company_issued":true/false,

    "serial_number":"serial_number",

    "imei":"imei",

    "description":"description",

    "user": {"email":"demo@samanage.com"},

    "technical_contact":{"email":"demo@samanage.com"},

    "site":{"name":"site name"},

    "department":{"name":"department name"}

    }

}

Updating an existing mobile device:

curl -H "X-Samanage-Authorization: Bearer TOKEN" -d 'INPUT_XML' -H 'Accept: application/xml' -H 'Content-Type:text/xml' -X PUT https://api.samanage.com/mobiles/MOBILE_ID.xml

XML Example:

<mobile>

  <field_to_update>content</field_to_update>

</mobile>

JSON Example:

{

  "mobile":{

    "status": "content",

    }

}

Deleting a mobile device:

curl -H "X-Samanage-Authorization: Bearer TOKEN" -H 'Accept: application/vnd.samanage.v2.1+xml' -X DELETE https://api.samanage.com/mobiles/MOBILE_ID.xml