def composeWord(key, value):
    """
    Create a attribute word from key, value pair.
    Values are casted to api equivalents.
    """
    mapping = {True: 'yes', False: 'no'}
    # this is necesary because 1 == True, 0 == False
    if type(value) == int:
        value = str(value)
    else:
        value = mapping.get(value, str(value))
    return '={}={}'.format(key, value)
def composeWord ( key , value ) : mapping = { True : 'yes' , False : 'no' } if type ( value ) == int : value = str ( value ) else : value = mapping . get ( value , str ( value ) ) return '={}={}' . format ( key , value )
Create a attribute word from key, value pair.
    Values are casted to api equivalents.