Criteo Labs is proud to be sponsor of EuroPython 2016. The event will take place from 17th till the 24th of July at the Euskalduna Conference Center in Bilbao.
EuroPython was started as an initiative by the EuroPython Conference Team to bring together Python and Zope users and developers. This is also an opportunity for those who are interested in these technologies to learn more about them.
Leveraging Documentation Power for Better Web APIs
‘Rich’ web APIs that are easier to understand, develop, test and use, is a popular subject. There are a lot of new specification languages (e.g. swagger, apiblueprint …) and libraries (django-rest-framework, drf …) that provide features in this direction. Following the old proverb “An API is only as good as its documentation”, we decided to play with these ideas and focus on leveraging the power of documentation. We propose to use the code documentation and the type system to provide: – browsable APIs, that are easy to interact with and visualize, reducing the need to provide custom UIs – verification of inputs/outputs along with precise error message if needed – automatic [de]-serialization of inputs/ouputs outside of the domain code – smart exception handling, e.g. exceptions that are not documented are automatically converted into internal errors – automatic testing, e.g. input, output and result including exceptions are tested ensuring the code works and the documentation is up-to-date.
This use case is one of the rare situation where introspection is desirable and unavoidable. And Python is a good language to explore/exploit code and documentation dynamically. The perfect excuse to spend some time on meta coding a first implementation while being at work. We’ll demonstrate what we came up to, the advantages and limitations compared to other approaches. And we’ll share the lessons we learned from this experiment.
Join us at our booth
There will be about eight of our engineers and recruitment team at our booth throughout this conference so please feel free to stop by for a chat with us, try out some of our quizes and take home some rare & fun swag.
We look forward to meeting you.
Our lovely Community Manager / Event Manager is updating you about what's happening at Criteo Labs.See DevOps Engineer roles