Wayland clients don't have to. For OpenGL, OpenGL ES there's EGL, for Vulkan, it's the other way and Vulkan provides extensions for WSI (window system integration).
Are you asking if it is technically possible? Yes, because libraries are just code + data, and you can trivially just duplicate the library functionality in your own library.
Are you trying to eliminate library dependencies for some kind of demoscene competition? You could just use the framebuffer.
Are you trying to write portable code that doesn’t depend on particular libraries being installed? That’s possible too, in various ways, such as dynamic linking.
Are you doing a homework assignment and want to render graphics, but the rules for the homework state “no libraries”? Also possible, but I would recommend talking to the teacher to clarify things.
Do you just need to display something simple to the user? You can use ASCII art and set colors by writing ANSI escape sequences, and you can also use emoji. Some people use this to make command-line applications with some simple graphics.
Finally, when you say “without any libraries” do you mean to include the standard library, or is that library OK?
In general I find the “without using libraries” questions that people ask a bit vague and difficult to answer.