You only return a dictionary from Pyramid views and based on the request, you can choose a renderer like JSON.
Look at this example[1] Steps 3, line 16-19. Basically you can develop a Rest API with template rendering side-by-side and you don't even need a framework for it like DRF!
[1]: http://static.agendaless.com/pycon2014/json.html