Finished C API