It should actually be no problem for a fully abled square, a bit trickier for a disabled square.
While someone like Stephen Hawkins, RIP, was indeed 3-dimensional, his physical ability to use a computer with standard inputs was limited to say the least. Luckily, we have designed various systems and devices to allow those with physical disabilities to use computers.
The first step is the output, because you can't interact with a system if you have no feedback.
I would presume, perhaps wrongly, that a 2D screen to a 2D character is the same than one of those fancy sci-fi 3D displays to a human, it might be overkill and unnecessarily complicated but should be comprehensible still.
In case your 2D pal cannot make visual sense of the screen, there are accessibility options on Windows (and I would assume other systems) to describe what's on the screen. I've never used them, so I can't really vouch for them, but they are designed for people with visual impairment and I assume they work well enough.
Now we'll assume your square has a good idea of what's on the screen. If he doesn't, chances are even turning him into a 3-dimensional being won't help.
If your square can move, that movement can be detected (with a camera for instance, or something like a DDR mat), you effectively have a mouse pointer. If your square can speak on top of that, you need to set up a command for left click, right click, double click, etc. then setup a commercially available speech-to-text software for typing. That would be the easiest, most straightforward way to interact with a computer screen.
In the case, your square can't move or speak, you'll have to tailor something around his specific abilities. Basic controls you'll need to map are selection (e.g. click), changing selection (e.g. moving the cursor, alt+tabbing), typing (which implies a vocabulary of commands for each letter plus some special characters, alternatively sounds or syllables instead of individual characters), and that should be enough to navigate the web.
Remember that people with disabilities still would like to use computers, and that we have come up with solutions for them. Some of them may be native to your system, some might be commercially available, some might be more DYI, but it should still be doable.
Obviously, someone who uses these should have more insight on their strengths and limitations than me.
14
What does "API" mean in this question? It most certainly does not mean Application Programming Interface.
– AlexP – 2018-05-24T17:42:42.3933are you trying to set up a flatland 2.0? – L.Dutch - Reinstate Monica – 2018-05-24T18:21:42.043
2Rather a (G)UI than an API? The latter define inter-process communication, you want a user interface, I guess. – Karl – 2018-05-24T18:39:26.023
1Can't he just crawl over a touchscreen, engaging visible controls when needed? – Alexander – 2018-05-24T19:16:59.980
@Alexander "He" lives in 2D so there is no "over" for him. – StephenG – 2018-05-24T20:18:06.960
So there's no interaction with environment throughout his body, only on perimeter? Can he feel the color of an image at his edge, at least? – Alexander – 2018-05-24T20:30:26.967
3
"Engage in forums", so we can explain everything to him? https://xkcd.com/1897/
– Karl – 2018-05-24T20:33:37.033I think you've overthought this. This is a solved problem. https://en.wikipedia.org/wiki/Computer_accessibility
– Mooing Duck – 2018-05-24T22:08:56.507@Alexander He can "see" a one-dimensional line including color. If he crashes into something he can feel it, and can also feel the sharpness/smoothness of whatever he touched. – danxinnoble – 2018-05-25T01:33:53.683
The solution is already out there, no need to build much. Your square has proper hearing but effectively useless vision. Sounds like a blind person to me. Off the shelf screen-reading software. All you need is for some way for your square to press some keys. – Loren Pechtel – 2018-05-26T00:01:21.397