DishonoredRighteous's blog

By DishonoredRighteous, history, 2 years ago, translation, In English

Hello, CodeForces!

Recently I was working on a Java library that implements interaction with Polygon API. It is very useful for some my tasks and it's cool that Polygon provides an API. But I discovered that is's kinda outdated. There are some new features in Polygon for which theres is no access through the API. There are also some use cases that can't be counted as new features but it's impossible to to them using API too.

In this post I created a shortlist of some methods and enhancements that can be useful in Polygon API in my opinion. May be it's hard to implement some of them but I hope that someone from Codeforces and Polygon team will see it and may be implement some of this API methods.

  1. Statement object doesn't store any field for interaction protocol in interactive problems. It's strange because some API methods can be used to work with interactive problems (for example, problem.interactor) but we cannot get interaction protocol from problem statements.

  2. Linux and Windows packages downloading. There is an API method problem.package that allows to download a Standard zip package. In some cases it seems to be useful to download Linux or Windows package because they include generated tests.

  3. Test object contains test input data but doesn't contain test output data. It seems that it should be easy to add this field and it can be useful too (you won't have to run generator script locally to get test output data).

  4. There is no methods that allow to work with Contest Groups. I suppose that Contest Group is a relatively new feature and that's why there is no methods for it.

  5. We cannot commit problem changes using API (may be it's done in this way for some security reasons).

  6. We cannot build packages using API.

  7. We cannot manage access to problems, contests and contest groups via API (may be it's done in this way for some security reasons).

  8. We cannot create problems and contests, and add problems to contests using API.

  9. To be continued...

May be this list is incomplete, so I will be glad if someone add some points into it in the comments. I hope that someone from Codeforces team (MikeMirzayanov? geranazavr555?) will see this post and comment it.

»
2 years ago, # |
Rev. 2   Vote: I like it +40 Vote: I do not like it

Just for the information, there is an issue tracker for polygon: https://github.com/Codeforces/polygon-issue-tracking/issues.

I believe that if you create the tickets with your enhancement proposals, it will be easier for the developers to look into it when they have time and ability to improve API, plus it won't be lost as some text here.

For instance, there is already a similar proposal to your number 2: https://github.com/Codeforces/polygon-issue-tracking/issues/410