#!/usr/bin/env python
from __future__ import print_function
import sys

from  eTraveler.clientAPI.connection import Connection

myConn = Connection('jrb', 'Raw', prodServer=True)
newId = ''
try: 
    newId=myConn.defineHardwareType(name='still_more_sprinkles', 
                                    description='type defined via eT API',
                                    subsystem='Legacy',
                                    batchedFlag=1,
                                    sequenceWidth='2')
    print('New hardware type defined.  Returned id is ', newId)
    sys.exit(0)
except Exception as msg:
    print('Hardware type definition failed with exception ',msg)
    sys.exit(1)

