ObjectIds for sms devices

Version 1
    This document was generated from CDN thread

    Created by: vimod shankar on 28-09-2010 07:40:45 AM
        I wanted to know whether the objectIds for updating the sms notification device would be same or not. According to the 7.1.3-CUPI-WADL document if i need to update the details of the sms notification device i would have to use the PUT method following web service call... users/{objectid}/notificationdevices/smsdevices/{ObjectId}. Can you please tell me whether both the objectIds are same. and if they are not same how can we retrieve the 2nd "objectId", provided we have the objectId of the user( the first objectId). Please do correct me in case my understanding is incorrect.
    Thanks in advance,

    Subject: RE: ObjectIds for sms devices
    Replied by: David Wanagel on 29-09-2010 02:34:29 PM
    The URI reflects a resource hierarchy, so the two obejct ID's are different.  The first object ID is the object ID for the user that owns the notification devices, the second object ID identifies a specific instance of an SMS device.  There are a couple ways to get the SMS device object id:
    When the SMS device is created, the response to the POST will be a URI identifying the SMS device, example:

    POST: https://cuc-install-67.cisco.com/vmrest/users/2a4f35b2-7a94-425d-b179-12cc5265e506/notificationdevices/smsdevices
    POST result URI: /vmrest/users/2a4f35b2-7a94-425d-b179-12cc5265e506/notificationdevices/smsdevices/22a64487-8b27-4847-8d39-cc73ebc3e8cf

    The following will return a list of SMS devices for a user, each of which has a URI field that has the complete URi for a specific SMS device.
    GET http://<server>/vmrest/users/<user object ID>/notificationdevices/smsdevices