Alright, so re-reading this I have an idea as to what has to happen. Also, I'll stay in this thread because what @RMo wrote still applies.
The Kwikset code probably won't help much in this case I'm afraid, as that lock talks directly to SmartThings through Z-Wave, so it's not a matter of adapting it- you'll have to write new code for this.
Using the Lockitron API, you'll need to write something for SmartThings that handles three purposes:
- Check the state of the lock
- Toggle lock state
- Alternatively, call a direct Lock/Unlock request
I don't use SmartThings at all, but to do the above, you're going to want to read up on using HTTP Methods with SmartThings. I also don't know how to add this as an item/object in SmartThings so you would have a button or similar to carry out the task.
To check the status of the lock, Retrieve A Lock is going to be the part you'll use. You'll be able to use an HTTP GET to find out the current information about the Lock, and it's filtered down by your Lock ID (find that here in Retrieve All Locks). When your SmartApp calls for the status of the Lock, you'll need to have it filter out and store the information under:
In this case here, the lock is unlocked, so you can have SmartThings can show you that it's open.
After the state check is complete, you can set a Toggle using Locking/Unlocking in the API. You can use an HTTP PUT to have your Lockitron either Lock/Unlock/Toggle. Toggle will obviously put the lock into the opposite of whatever state it's in, so this will be best for general usage.
To recap, you'll HTTP GET the state of the lock, and HTTP PUT a command to toggle it.
The third item in the list is purely optional, you can use the same HTTP PUT to lock the unit. This could be useful in a "Leaving Home" or "Going to sleep" type of scene/function, or whatever SmartThings calls it.