IS there any method to set the options property of a html custom field in a custom doctype but on server side, in python?

I have a custom doctype with an html field that I would like to fetch its options property from server side,
Is there any standard method to set the options property of a html custom field in a custom doctype in python?

As a workaround you can set a docfield of type ‘read-only’ instead of type ‘html’ and fill its value with an html code, i.e

def before_save(doc):
doc.kk = ‘GitHub Pibico