what could be the way for creating an environment from within a custom command. For example, something like this :
\NewDocumentCommand\mynewblock{m m m}{% pseudo code : % custom environment here with #1 corresponding to the name, #2 to the code "before" and #3 to the code after. } At first look, it may seem clumsy to do so, because a \NewDocumentEnvironment command allows to do this stuff ; but, for me, it may be useful indeed to hide the environment command to users... Thanks a lot.
\NewDocumentCommand\mynewblock{m m m}{\NewDocumentEnvironment{#1}{}{#2}{#3}}.\NewDocumentCommand\mynewblock{m}{\NewDocumentEnvironment{#1}{}}?\NewDocumentCommandand friends currying is discouraged (also I expect OP to actually put more code inside that definition).