from django_eveonline_connector.models import EveClient, EveToken
import logging

logger = logging.getLogger(__name__)


def resolve_ids(ids):
    resolved_ids = EveClient.call('post_universe_names', token=None, ids=ids)
    response = {}
    for resolved_id in resolved_ids:
        external_id = resolved_id['id']
        external_name = resolved_id['name']
        if external_id not in response:
            response[external_id] = external_name
    return response

def resolve_names(names):
    resolved_ids = EveClient.call('post_universe_ids', token=None, names=names)
    return resolved_ids


def resolve_ids_with_types(ids):
    resolved_ids = EveClient.call('post_universe_names', token=None, ids=ids)
    response = {}
    for resolved_id in resolved_ids:
        external_id = resolved_id['id']
        external_name = resolved_id['name']
        external_type = resolved_id['category']
        if external_id not in response:
            response[external_id] = {
                "name": external_name,
                "type": external_type
            }
    return response


def get_type_id(type_id):
    return EveClient.call('get_universe_types_type_id', token=None, type_id=type_id)


def get_station_id(station_id):
    return EveClient.call('get_universe_stations_station_id', token=None, station_id=station_id)


def get_group_id(group_id):
    return EveClient.call('get_universe_groups_group_id', token=None, group_id=group_id)

de0acd3f8986bce42570337cc482da7b8dc51ab8
<mask token>


def resolve_ids(ids):
    resolved_ids = EveClient.call('post_universe_names', token=None, ids=ids)
    response = {}
    for resolved_id in resolved_ids:
        external_id = resolved_id['id']
        external_name = resolved_id['name']
        if external_id not in response:
            response[external_id] = external_name
    return response


<mask token>


def resolve_ids_with_types(ids):
    resolved_ids = EveClient.call('post_universe_names', token=None, ids=ids)
    response = {}
    for resolved_id in resolved_ids:
        external_id = resolved_id['id']
        external_name = resolved_id['name']
        external_type = resolved_id['category']
        if external_id not in response:
            response[external_id] = {'name': external_name, 'type':
                external_type}
    return response


<mask token>

<mask token>


def resolve_ids(ids):
    resolved_ids = EveClient.call('post_universe_names', token=None, ids=ids)
    response = {}
    for resolved_id in resolved_ids:
        external_id = resolved_id['id']
        external_name = resolved_id['name']
        if external_id not in response:
            response[external_id] = external_name
    return response


def resolve_names(names):
    resolved_ids = EveClient.call('post_universe_ids', token=None, names=names)
    return resolved_ids


def resolve_ids_with_types(ids):
    resolved_ids = EveClient.call('post_universe_names', token=None, ids=ids)
    response = {}
    for resolved_id in resolved_ids:
        external_id = resolved_id['id']
        external_name = resolved_id['name']
        external_type = resolved_id['category']
        if external_id not in response:
            response[external_id] = {'name': external_name, 'type':
                external_type}
    return response


<mask token>


def get_station_id(station_id):
    return EveClient.call('get_universe_stations_station_id', token=None,
        station_id=station_id)


def get_group_id(group_id):
    return EveClient.call('get_universe_groups_group_id', token=None,
        group_id=group_id)

<mask token>
logger = logging.getLogger(__name__)


def resolve_ids(ids):
    resolved_ids = EveClient.call('post_universe_names', token=None, ids=ids)
    response = {}
    for resolved_id in resolved_ids:
        external_id = resolved_id['id']
        external_name = resolved_id['name']
        if external_id not in response:
            response[external_id] = external_name
    return response


def resolve_names(names):
    resolved_ids = EveClient.call('post_universe_ids', token=None, names=names)
    return resolved_ids


def resolve_ids_with_types(ids):
    resolved_ids = EveClient.call('post_universe_names', token=None, ids=ids)
    response = {}
    for resolved_id in resolved_ids:
        external_id = resolved_id['id']
        external_name = resolved_id['name']
        external_type = resolved_id['category']
        if external_id not in response:
            response[external_id] = {'name': external_name, 'type':
                external_type}
    return response


def get_type_id(type_id):
    return EveClient.call('get_universe_types_type_id', token=None, type_id
        =type_id)


def get_station_id(station_id):
    return EveClient.call('get_universe_stations_station_id', token=None,
        station_id=station_id)


def get_group_id(group_id):
    return EveClient.call('get_universe_groups_group_id', token=None,
        group_id=group_id)

from django_eveonline_connector.models import EveClient, EveToken
import logging
logger = logging.getLogger(__name__)


def resolve_ids(ids):
    resolved_ids = EveClient.call('post_universe_names', token=None, ids=ids)
    response = {}
    for resolved_id in resolved_ids:
        external_id = resolved_id['id']
        external_name = resolved_id['name']
        if external_id not in response:
            response[external_id] = external_name
    return response


def resolve_names(names):
    resolved_ids = EveClient.call('post_universe_ids', token=None, names=names)
    return resolved_ids


def resolve_ids_with_types(ids):
    resolved_ids = EveClient.call('post_universe_names', token=None, ids=ids)
    response = {}
    for resolved_id in resolved_ids:
        external_id = resolved_id['id']
        external_name = resolved_id['name']
        external_type = resolved_id['category']
        if external_id not in response:
            response[external_id] = {'name': external_name, 'type':
                external_type}
    return response


def get_type_id(type_id):
    return EveClient.call('get_universe_types_type_id', token=None, type_id
        =type_id)


def get_station_id(station_id):
    return EveClient.call('get_universe_stations_station_id', token=None,
        station_id=station_id)


def get_group_id(group_id):
    return EveClient.call('get_universe_groups_group_id', token=None,
        group_id=group_id)

from django_eveonline_connector.models import EveClient, EveToken
import logging

logger = logging.getLogger(__name__)


def resolve_ids(ids):
    resolved_ids = EveClient.call('post_universe_names', token=None, ids=ids)
    response = {}
    for resolved_id in resolved_ids:
        external_id = resolved_id['id']
        external_name = resolved_id['name']
        if external_id not in response:
            response[external_id] = external_name
    return response

def resolve_names(names):
    resolved_ids = EveClient.call('post_universe_ids', token=None, names=names)
    return resolved_ids


def resolve_ids_with_types(ids):
    resolved_ids = EveClient.call('post_universe_names', token=None, ids=ids)
    response = {}
    for resolved_id in resolved_ids:
        external_id = resolved_id['id']
        external_name = resolved_id['name']
        external_type = resolved_id['category']
        if external_id not in response:
            response[external_id] = {
                "name": external_name,
                "type": external_type
            }
    return response


def get_type_id(type_id):
    return EveClient.call('get_universe_types_type_id', token=None, type_id=type_id)


def get_station_id(station_id):
    return EveClient.call('get_universe_stations_station_id', token=None, station_id=station_id)


def get_group_id(group_id):
    return EveClient.call('get_universe_groups_group_id', token=None, group_id=group_id)
