Move playing API includes 'i' coordinate

Although it’s quite standard for go board coordinates to skip the “i” coordinate, it seems that the API doesn’t follow this convention. For instance, if you send { “move” : “dq” }, one would reasonably expect it to land on the point marked “D4” on the board. Instead, it lands on D3. Is this by design?

1 Like

It’s worth noting that if one ignores the documentation and plays “d4” for instance, that works as expected. This behavior is also not exhibited on horizontal coordinates.

Additionally, the API endpoint in the documentation is incorrect. It is listed as ‘http://online-go.com/v1/games/id/move/’, whereas the correct URI is ‘http://online-go.com/api/v1/games/id/move/

I haven’t looked at that part of the API, so this is purely conjecture.

The format for storing moves, SGF, uses two letters for the coordinates of the move. It is possible that the same code is being used to convert the internal representation to text. Since this isn’t usually seen by the user, this helps with consistency in internal handling.

There may also be code that matches what it receives and parses differently if a number is present. The protocol the bots use matches what a humans sees and would understand ‘D4’.

2 Likes

I just checked, and you’re correct, SGF uses this notation as well. Good call on how that’s working.