def get_output_values(track):
    """
    Given a track object, return a dictionary containing only the desired
    output information to send to front end.
    """
    name = track["name"]
    uri = track["uri"]
    artist = track['artists'][0]['name']
    album = track['album']['name']
    spotify_id = track['id']
    popularity = track['popularity']
    preview_url = track['preview_url']
    image = track['album']['images']

    output = {"name": name, "uri": uri, "artist": artist, "album": album,
              "spotify_id": spotify_id, "popularity": popularity,
              "preview_url": preview_url, "image": image}

    return output