[FastAPI] Refactor comaintainers POST route
We should move the helper functions we created in this module over to somewhere that isn't intrusive on the body of the module (another module for helper functions). Currently, it's a bit messy because we wrote two functions that we used in there, but we didn't decouple them into their own modules.
Additionally: #117 (closed) (required for this task)