Why is Revit API not in Python?

This is my 1st day writing code in Python for Revit. I am working in the Dynamo IDE.
Im confused why the Revit API documentation is in C# and Visual Basic, yet Dynamo provides OOB the ability to create Python Scripts?

Where is the Revit API for the Python language?

Sorry for being a Noob, Thanks for the help

Revit has a .NET API. Dynamo uses a .NET version of Python which allows CLR to translate Python code to the actual .NET Revit API when it gets executed, but Revit doesn’t actually support Python natively. That’s why you don’t see it in any documentation.

It’s not difficult, but you have to learn how to translate those other .NET languages into Python appropriate code when using Dynamo. I’d recommend getting familiar with Python itself first. The translation process should be fairly simple for most API calls once you know the basics.

3 Likes

If only Revit was open source, on Github for everybody to improve on, in Python.
:rofl:
(no pun intended)

2 Likes