Code can implement an API, but an API is not code. Not using any reasonable definition of code. Code is something you are theoretically able to execute, in one way or another.
Is MOOPH module copyright protected?
Most likely yes. Because you gave it a specific implementation that is not required to make it work. The functionality - and any elements of the module that spring directly from that functionality - is not copyrightable.
If you gave a programmer pseudo code for your module and they created near enough the same module from it then the creative elements don't lie in the aesthetic art and so the copyright in it is very weak.