ccpgames / sso-issues

Please file issues with the CCP SSO (login.eveonline.com) here.
17 stars 1 forks source link

Providing scope name instead scope key in scopes error response #37

Open warlof opened 6 years ago

warlof commented 6 years ago

Feature / Modification Request

Description

Actually, if you're making a refresh request with an invalid scopes in scopes list; the following response is returned :

{
    "scopes.60" : [
        "The selected scopes.60 is invalid."
    ]
}

This is anoying since the provided reference is based on the scopes array key (starting at 0; but depending on language, that may differ).

Furthermore, it implying that the scopes array isn't sorted differently based on the provided one in the request (which seems to be the case actually).

Could you, instead, provided the scope name ?

The resulting response become

{
    "scopes.60" : [
        "The selected scope esi-corporations.read_outposts.v1 is invalid."
    ]
}

PS : the provided sample is based on the following scopes list :

["esi-calendar.read_calendar_events.v1", "esi-location.read_location.v1", "esi-location.read_ship_type.v1", "esi-mail.read_mail.v1", "esi-skills.read_skills.v1", "esi-skills.read_skillqueue.v1", "esi-wallet.read_character_wallet.v1", "esi-search.search_structures.v1", "esi-clones.read_clones.v1", "esi-characters.read_contacts.v1", "esi-universe.read_structures.v1", "esi-bookmarks.read_character_bookmarks.v1", "esi-killmails.read_killmails.v1", "esi-corporations.read_corporation_membership.v1", "esi-assets.read_assets.v1", "esi-planets.manage_planets.v1", "esi-fleets.read_fleet.v1", "esi-ui.open_window.v1", "esi-fittings.read_fittings.v1", "esi-markets.structure_markets.v1", "esi-corporations.read_structures.v1", "esi-characters.read_loyalty.v1", "esi-characters.read_opportunities.v1", "esi-characters.read_chat_channels.v1", "esi-characters.read_medals.v1", "esi-characters.read_standings.v1", "esi-characters.read_agents_research.v1", "esi-industry.read_character_jobs.v1", "esi-markets.read_character_orders.v1", "esi-characters.read_blueprints.v1", "esi-characters.read_corporation_roles.v1", "esi-location.read_online.v1", "esi-contracts.read_character_contracts.v1", "esi-clones.read_implants.v1", "esi-characters.read_fatigue.v1", "esi-killmails.read_corporation_killmails.v1", "esi-corporations.track_members.v1", "esi-wallet.read_corporation_wallets.v1", "esi-characters.read_notifications.v1", "esi-corporations.read_divisions.v1", "esi-corporations.read_contacts.v1", "esi-assets.read_corporation_assets.v1", "esi-corporations.read_titles.v1", "esi-corporations.read_blueprints.v1", "esi-bookmarks.read_corporation_bookmarks.v1", "esi-contracts.read_corporation_contracts.v1", "esi-corporations.read_standings.v1", "esi-corporations.read_starbases.v1", "esi-industry.read_corporation_jobs.v1", "esi-markets.read_corporation_orders.v1", "esi-corporations.read_container_logs.v1", "esi-industry.read_character_mining.v1", "esi-industry.read_corporation_mining.v1", "esi-planets.read_customs_offices.v1", "esi-corporations.read_facilities.v1", "esi-corporations.read_medals.v1", "esi-characters.read_titles.v1", "esi-alliances.read_contacts.v1", "esi-characters.read_fw_stats.v1", "esi-corporations.read_fw_stats.v1", "esi-corporations.read_outposts.v1", "esi-characterstats.read.v1"]