For the last few years, on and off, I have been developing a C++ wrapper for the SketchUp C API. I developed it for my own use, but I share freely for anyone to make use of it.
The point of the project is to make the SketchUp C API “feel” like a native C++ API. That means that you don’t have to manage memory allocations, and can write fewer lines of code for each API function you might otherwise use. I have also made sure it throws exceptions for some silent failures that one can fall into with the C API.
It is current to the 2025 API.
With the help of an AI assistant, I recently managed to complete the wrapper to include all C API calls (I think - to be verified). More testing is required through use - please feel free to fix any problems for this Open Source project.
I personally use this for making my Ruby C Extension (I guess “Ruby C++ Extension” with the wrapper). I hope you find it useful. Feel free to ask questions here or raise an issue at the GitHub project.