ip-tools/python-epo-ops-client ? reverse-engineered prompt

Reverse engineered prompt

Build me a Python client library for the European Patent Office OPS API that makes it easy to fetch patent data without having to deal with all the request details myself.

I want a simple client where I can pass my API key and secret, then call methods to get published data, search results, register data, family info, images, number lookup, and legal data. It should handle authentication and token renewal automatically, raise normal HTTP errors when something goes wrong, and surface quota issues clearly. Please also add support for optional middleware so requests can be throttled correctly and responses can be cached if I turn that on.

The library should feel easy to use from a normal Python app, with good tests and clear docs or examples showing how to request bibliography, claims, description, and search data. If anything about the current EPO OPS behavior is unclear, look up the current docs online and follow those rules.