Beispiel #1
0
def get_info():
    zeroconf_vars = get_zeroconf_vars()

    return jsonify({
        'status':
        101,
        'spotifyError':
        0,
        'activeUser':
        zeroconf_vars['activeUser'],
        'brandDisplayName':
        ffi.string(connect_app.config['brandName']),
        'accountReq':
        zeroconf_vars['accountReq'],
        #Doesn't have any specific format (I think)
        'deviceID':
        zeroconf_vars['deviceId'],
        #Generated from SpZeroConfGetVars()
        #Used to encrypt the blob used for login
        'publicKey':
        zeroconf_vars['publicKey'],
        'version':
        '2.0.1',
        #Valid types are UNKNOWN, COMPUTER, TABLET, SMARTPHONE, SPEAKER, TV, AVR, STB and AUDIODONGLE
        'deviceType':
        zeroconf_vars['deviceType'],
        'modelDisplayName':
        ffi.string(connect_app.config['modelName']),
        #Status codes are ERROR-OK (not actually an error), ERROR-MISSING-ACTION, ERROR-INVALID-ACTION, ERROR-SPOTIFY-ERROR, ERROR-INVALID-ARGUMENTS, ERROR-UNKNOWN, and ERROR_LOG_FILE
        'statusString':
        'ERROR-OK',
        #Name that shows up in the Spotify client
        'remoteName':
        zeroconf_vars['remoteName']
    })
Beispiel #2
0
def get_info():
    zeroconf_vars = get_zeroconf_vars()

    return jsonify({
        'status': 101,
        'spotifyError': 0,
        'activeUser': zeroconf_vars['activeUser'],
        'brandDisplayName': ffi.string(connect_app.config['brandName']),
        'accountReq': zeroconf_vars['accountReq'],
        #Doesn't have any specific format (I think)
        'deviceID': zeroconf_vars['deviceId'],
        #Generated from SpZeroConfGetVars()
        #Used to encrypt the blob used for login
        'publicKey': zeroconf_vars['publicKey'],
        'version': '2.0.1',
        #Valid types are UNKNOWN, COMPUTER, TABLET, SMARTPHONE, SPEAKER, TV, AVR, STB and AUDIODONGLE
        'deviceType': zeroconf_vars['deviceType'],
        'modelDisplayName': ffi.string(connect_app.config['modelName']),
        #Status codes are ERROR-OK (not actually an error), ERROR-MISSING-ACTION, ERROR-INVALID-ACTION, ERROR-SPOTIFY-ERROR, ERROR-INVALID-ARGUMENTS, ERROR-UNKNOWN, and ERROR_LOG_FILE
        'statusString': 'ERROR-OK',
        #Name that shows up in the Spotify client
        'remoteName': zeroconf_vars['remoteName']
    })
Beispiel #3
0
def info_display_name():
    return jsonify({'remoteName': get_zeroconf_vars()['remoteName']})
Beispiel #4
0
def info_display_name():
    return jsonify({
        'remoteName': get_zeroconf_vars()['remoteName']
    })