esi-issues icon indicating copy to clipboard operation
esi-issues copied to clipboard

Endpoint to award corporation medals/decorations

Open aebe opened this issue 6 years ago • 1 comments

Feature Request

Corporation medals are a nice way to recognize pilots who have contributed to the corporation or participated in campaigns or major battles. In large corporations, however, it becomes impractical to manually award hundreds of medals. An ESI endpoint to automate this would be lovely.

Currently we bulk-award medals by having everyone log in, selecting all pilots in the corporation chat, and awarding a medal to all of them. This is imprecise and screws over people who aren't able to log in at the specified time. It also doesn't work for awarding medals based on out-of-game information (for example, a corporation might want to award a medal to pilots who get N kills while in corp).

Use case

Corporations (especially large ones) looking to recognize their pilots' contributions can use this endpoint to avoid lots of manual clicking in game.

Authentication

This endpoint requires authentication and a new scope (as well as the appropriate in-game roles).

Parameters

The endpoint needs to accept three parameters: a character_id (or perhaps a list of character_ids--bulk awarding medals to many pilots at once is a major use case for this endpoint), a medal_id, and a reason (string).

Note that this endpoint would not allow creation of new medals, only awarding medals that already have been created in game.

Example return

The return should indicate the pilot(s) who have successfully been awarded the medal:

{
  "character_id": 123456789,
  "medal_id": 987654321
}

(or a list of character_ids)

Checklist

Check all boxes that apply to this issue:

  • [x] Feature request description is provided
  • [x] Use case exists
  • [x] Feature requires a new route
  • [ ] Feature adds data to existing route
  • [x] Feature requires new auth scope
  • [ ] Feature can reuse existing scope
  • [ ] Feature does not require auth
  • [ ] Meta feature, applies to all routes

aebe avatar Nov 04 '19 04:11 aebe

I have been reminded that awarding medals costs isk (5m per award), which is a concern for ESI. However, I don't think it's an insurmountable obstacle. It is more analogous to the CSPA charge for sending mails than to transferring isk. It might be reasonable to heavily rate-limit medal awarding in a way similar to mails are rate-limited by the monolith (I know, ESI usually doesn't impose rate limits).

aebe avatar Nov 04 '19 17:11 aebe