I found the solution to read and modify the opacity expression for any item of the Layout in the following way:
items = QgsProject.instance().layoutManager().layouts()[0].items()
for item in items:
# Visualize the current expression
expression = item.dataDefinedProperties().property(QgsLayoutObject.Opacity).asExpression()
print(expression)
# Modify the previous expression of Opacity
item.dataDefinedProperties().property(QgsLayoutObject.Opacity).setExpressionString('if(@atlas_pagename = 6, 100, 0)')
# Visualize the modified expression
print(item.dataDefinedProperties().property(QgsLayoutObject.Opacity).asExpression())